diff options
author | Michael Brown <mcb30@ipxe.org> | 2016-05-29 13:04:26 +0100 |
---|---|---|
committer | Michael Brown <mcb30@ipxe.org> | 2016-05-29 13:10:14 +0100 |
commit | aa4b038c70ca3e23c3126fda4318e9bbe77f3ea2 (patch) | |
tree | b36ef7fe452af987a423785c729cf25c9ca42ce7 /src/include/ipxe/efi/Protocol | |
parent | af9afd0a86aeac1eed28b5028c3de669515fc7fc (diff) | |
download | ipxe-aa4b038c70ca3e23c3126fda4318e9bbe77f3ea2.tar.gz |
[efi] Expose DHCP packets via the Apple NetBoot protocol
Mac OS X uses non-standard EFI protocols to obtain the DHCP packets
from the UEFI firmware.
Originally-implemented-by: Michael Kuron <m.kuron@gmx.de>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/include/ipxe/efi/Protocol')
-rw-r--r-- | src/include/ipxe/efi/Protocol/AppleNetBoot.h | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/src/include/ipxe/efi/Protocol/AppleNetBoot.h b/src/include/ipxe/efi/Protocol/AppleNetBoot.h new file mode 100644 index 000000000..144beff1c --- /dev/null +++ b/src/include/ipxe/efi/Protocol/AppleNetBoot.h @@ -0,0 +1,46 @@ +#ifndef __EFI_APPLE_NET_BOOT_PROTOCOL_H__ +#define __EFI_APPLE_NET_BOOT_PROTOCOL_H__ + +/** @file + * + * Apple Net Boot Protocol + * + */ + +FILE_LICENCE ( BSD3 ); + +#define EFI_APPLE_NET_BOOT_PROTOCOL_GUID \ + { 0x78ee99fb, 0x6a5e, 0x4186, \ + { 0x97, 0xde, 0xcd, 0x0a, 0xba, 0x34, 0x5a, 0x74 } } + +typedef struct _EFI_APPLE_NET_BOOT_PROTOCOL EFI_APPLE_NET_BOOT_PROTOCOL; + +/** + Get a DHCP packet obtained by the firmware during NetBoot. + + @param This A pointer to the APPLE_NET_BOOT_PROTOCOL instance. + @param BufferSize A pointer to the size of the buffer in bytes. + @param DataBuffer The memory buffer to copy the packet to. If it is + NULL, then the size of the packet is returned + in BufferSize. + @retval EFI_SUCCESS The packet was copied. + @retval EFI_BUFFER_TOO_SMALL The BufferSize is too small to read the + current packet. BufferSize has been + updated with the size needed to + complete the request. +**/ +typedef +EFI_STATUS +(EFIAPI *GET_DHCP_RESPONSE) ( + IN EFI_APPLE_NET_BOOT_PROTOCOL *This, + IN OUT UINTN *BufferSize, + OUT VOID *DataBuffer + ); + +struct _EFI_APPLE_NET_BOOT_PROTOCOL +{ + GET_DHCP_RESPONSE GetDhcpResponse; + GET_DHCP_RESPONSE GetBsdpResponse; +}; + +#endif /*__EFI_APPLE_NET_BOOT_PROTOCOL_H__ */ |