]> git.proxmox.com Git - mirror_edk2.git/blobdiff - NetworkPkg/UefiPxeBcDxe/PxeBcDhcp4.h
Fix bugs in PXE driver when using option 43 for boot server list and boot menu prompt.
[mirror_edk2.git] / NetworkPkg / UefiPxeBcDxe / PxeBcDhcp4.h
index bc21b212a26e501bdf292095d3ee414fc9921f93..37747ac74f44726eb09a816e7830a6e8528e7b3a 100644 (file)
@@ -1,7 +1,7 @@
 /** @file\r
   Functions declaration related with DHCPv4 for UefiPxeBc Driver.\r
 \r
 /** @file\r
   Functions declaration related with DHCPv4 for UefiPxeBc Driver.\r
 \r
-  Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.<BR>\r
+  Copyright (c) 2009 - 2012, Intel Corporation. All rights reserved.<BR>\r
 \r
   This program and the accompanying materials\r
   are licensed and made available under the terms and conditions of the BSD License\r
 \r
   This program and the accompanying materials\r
   are licensed and made available under the terms and conditions of the BSD License\r
@@ -146,6 +146,10 @@ typedef enum {
    BIT (PXEBC_VENDOR_TAG_BOOT_MENU) | \\r
    BIT (PXEBC_VENDOR_TAG_MENU_PROMPT))\r
 \r
    BIT (PXEBC_VENDOR_TAG_BOOT_MENU) | \\r
    BIT (PXEBC_VENDOR_TAG_MENU_PROMPT))\r
 \r
+#define IS_VALID_BOOT_SERVERS(x) \\r
+  ((((x)[0]) & BIT (PXEBC_VENDOR_TAG_BOOT_SERVERS)) \\r
+   == BIT (PXEBC_VENDOR_TAG_BOOT_SERVERS))  \r
+\r
 #define IS_VALID_BOOT_PROMPT(x) \\r
   ((((x)[0]) & BIT (PXEBC_VENDOR_TAG_MENU_PROMPT)) \\r
    == BIT (PXEBC_VENDOR_TAG_MENU_PROMPT))\r
 #define IS_VALID_BOOT_PROMPT(x) \\r
   ((((x)[0]) & BIT (PXEBC_VENDOR_TAG_MENU_PROMPT)) \\r
    == BIT (PXEBC_VENDOR_TAG_MENU_PROMPT))\r
@@ -256,6 +260,7 @@ typedef union {
   PXEBC_DHCP4_OPTION_MAX_MESG_SIZE  *MaxMesgSize;\r
 } PXEBC_DHCP4_OPTION_ENTRY;\r
 \r
   PXEBC_DHCP4_OPTION_MAX_MESG_SIZE  *MaxMesgSize;\r
 } PXEBC_DHCP4_OPTION_ENTRY;\r
 \r
+#pragma pack(1)\r
 typedef struct {\r
   UINT16            Type;\r
   UINT8             IpCnt;\r
 typedef struct {\r
   UINT16            Type;\r
   UINT8             IpCnt;\r
@@ -272,6 +277,7 @@ typedef struct {
   UINT8             Timeout;\r
   UINT8             Prompt[1];\r
 } PXEBC_MENU_PROMPT;\r
   UINT8             Timeout;\r
   UINT8             Prompt[1];\r
 } PXEBC_MENU_PROMPT;\r
+#pragma pack()\r
 \r
 typedef struct {\r
   UINT32                BitMap[8];\r
 \r
 typedef struct {\r
   UINT32                BitMap[8];\r