[efi] Match behaviour of SnpDxe for truncated received packets
authorMichael Brown <mcb30@ipxe.org>
Wed, 6 Sep 2017 22:56:22 +0000 (23:56 +0100)
committerMichael Brown <mcb30@ipxe.org>
Wed, 6 Sep 2017 22:56:22 +0000 (23:56 +0100)
commite8f30571a375777fc83c14602f9ed32ac26eedb4
treecca0a26dedd34c2414f4d43bfaa7e5bc417bf7bf
parent3f429bdcfe0c3698f886e93a1f603656ccaa0f28
[efi] Match behaviour of SnpDxe for truncated received packets

The UEFI specification does not state whether or not a return value of
EFI_BUFFER_TOO_SMALL from the SNP Receive() method should follow the
usual EFI API behaviour of allowing the caller to retry the request
with an increased buffer size.

Examination of the SnpDxe driver in EDK2 suggests that Receive() will
just return the truncated packet (complete with any requested
link-layer header fields), so match this behaviour.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
src/interface/efi/efi_snp.c