TianoCore EDK2 master
|
#include <Library/BaseLib.h>
#include <Library/BaseMemoryLib.h>
#include <Library/UefiBootServicesTableLib.h>
#include "VirtioNet.h"
Go to the source code of this file.
Functions | |
EFI_STATUS EFIAPI | VirtioNetReceive (IN EFI_SIMPLE_NETWORK_PROTOCOL *This, OUT UINTN *HeaderSize OPTIONAL, IN OUT UINTN *BufferSize, OUT VOID *Buffer, OUT EFI_MAC_ADDRESS *SrcAddr OPTIONAL, OUT EFI_MAC_ADDRESS *DestAddr OPTIONAL, OUT UINT16 *Protocol OPTIONAL) |
Implementation of the SNP.Receive() function and its private helpers if any.
Copyright (C) 2013, Red Hat, Inc. Copyright (c) 2006 - 2013, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent
Definition in file SnpReceive.c.
EFI_STATUS EFIAPI VirtioNetReceive | ( | IN EFI_SIMPLE_NETWORK_PROTOCOL * | This, |
OUT UINTN *HeaderSize | OPTIONAL, | ||
IN OUT UINTN * | BufferSize, | ||
OUT VOID * | Buffer, | ||
OUT EFI_MAC_ADDRESS *SrcAddr | OPTIONAL, | ||
OUT EFI_MAC_ADDRESS *DestAddr | OPTIONAL, | ||
OUT UINT16 *Protocol | OPTIONAL | ||
) |
Receives a packet from a network interface.
This | The protocol instance pointer. |
HeaderSize | The size, in bytes, of the media header received on the network interface. If this parameter is NULL, then the media header size will not be returned. |
BufferSize | On entry, the size, in bytes, of Buffer. On exit, the size, in bytes, of the packet that was received on the network interface. |
Buffer | A pointer to the data buffer to receive both the media header and the data. |
SrcAddr | The source HW MAC address. If this parameter is NULL, the HW MAC source address will not be extracted from the media header. |
DestAddr | The destination HW MAC address. If this parameter is NULL, the HW MAC destination address will not be extracted from the media header. |
Protocol | The media header type. If this parameter is NULL, then the protocol will not be extracted from the media header. See RFC 1700 section "Ether Types" for examples. |
EFI_SUCCESS | The received data was stored in Buffer, and BufferSize has been updated to the number of bytes received. |
EFI_NOT_STARTED | The network interface has not been started. |
EFI_NOT_READY | The network interface is too busy to accept this transmit request. |
EFI_BUFFER_TOO_SMALL | The BufferSize parameter is too small. |
EFI_INVALID_PARAMETER | One or more of the parameters has an unsupported value. |
EFI_DEVICE_ERROR | The command could not be sent to the network interface. |
EFI_UNSUPPORTED | This function is not supported by the network interface. |
Definition at line 57 of file SnpReceive.c.