diff --minimal --unified -r newgrub/grub/netboot/main.c grub/netboot/main.c
--- newgrub/grub/netboot/main.c 2004-05-20 17:17:27.000000000 -0500
+++ grub/netboot/main.c 2006-02-02 13:22:09.000000000 -0500
@@ -82,8 +82,17 @@
   RFC2132_MSG_TYPE, 1, DHCPDISCOVER,
   RFC2132_MAX_SIZE,2,  /* request as much as we can */
   ETH_MAX_MTU / 256, ETH_MAX_MTU % 256,
-  RFC2132_PARAM_LIST, 4, RFC1533_NETMASK, RFC1533_GATEWAY,
+  RFC2132_PARAM_LIST,
+#ifdef INCLUDE_DHCPVSI
+  5,
+#else
+  4,
+#endif
+  RFC1533_NETMASK, RFC1533_GATEWAY,
   RFC1533_HOSTNAME, RFC1533_EXTENSIONPATH
+#ifdef INCLUDE_DHCPVSI
+  , RFC1533_VENDOR, RFC2132_VENDOR_CLASS_ID,7,'p','x','e','g','r','u','b'
+#endif /*INCLUDE_DHCPVSI*/
 };

 static const unsigned char dhcprequest[] =
@@ -95,14 +104,25 @@
   ETH_MAX_MTU / 256, ETH_MAX_MTU % 256,
   /* request parameters */
   RFC2132_PARAM_LIST,
+#ifdef INCLUDE_DHCPVSI
+  /* 4 standard + 2 vendortags + 1 VSI tag*/
+  4 + 2 + 1,
+#else
   /* 4 standard + 2 vendortags */
   4 + 2,
+#endif
   /* Standard parameters */
   RFC1533_NETMASK, RFC1533_GATEWAY,
   RFC1533_HOSTNAME, RFC1533_EXTENSIONPATH,
+#ifdef INCLUDE_DHCPVSI
+  RFC1533_VENDOR,
+#endif
   /* Etherboot vendortags */
   RFC1533_VENDOR_MAGIC,
   RFC1533_VENDOR_CONFIGFILE,
+#ifdef INCLUDE_DHCPVSI
+  RFC2132_VENDOR_CLASS_ID,7,'p','x','e','g','r','u','b'
+#endif
 };

 #endif /* ! NO_DHCP_SUPPORT */
@@ -738,6 +758,11 @@
 int
 await_reply (int type, int ival, void *ptr, int timeout)
 {
+#ifdef INCLUDE_DHCPVSI
+  unsigned int vendi,count;
+  char grubvendorID[] = {0x70,0x78,0x65,0x67,0x72,0x75,0x62,0xFF};
+  unsigned int gvIDsize = (sizeof(grubvendorID)/sizeof(char));
+#endif
   unsigned long time;
   struct iphdr *ip;
   struct udphdr *udp;
@@ -900,6 +925,21 @@
              arptable[ARP_CLIENT].ipaddr.s_addr
                = bootpreply->bp_yiaddr.s_addr;
 #ifndef        NO_DHCP_SUPPORT
+#ifdef INCLUDE_DHCPVSI
+          /**Check that DHCP option 43 for magic grubvendorID*/
+          for(vendi=count=0; vendi<(BOOTP_VENDOR_LEN+2-gvIDsize);vendi++) {
+            while(bootpreply->bp_vend[vendi+count]==grubvendorID[count]
+            && count < gvIDsize)
+                     count++;
+            if (count==gvIDsize)
+              break;
+            count=0;
+          }
+                 if (count==0) {
+            etherboot_printf("DHCP did not provide VSI\n");
+            continue;
+          }
+#endif
              dhcp_addr.s_addr = bootpreply->bp_yiaddr.s_addr;
 #ifdef DEBUG
              etherboot_printf ("dhcp_addr = %@\n", dhcp_addr.s_addr);

diff --minimal --unified -r newgrub/grub/netboot/README.netboot grub/netboot/README.netboot
--- newgrub/grub/netboot/README.netboot 2002-01-02 16:56:40.000000000 -0500
+++ grub/netboot/README.netboot 2006-02-02 00:18:13.000000000 -0500
@@ -22,6 +22,10 @@
   the latter is the ``Preboot Execution Environment" format, which is
   used by a PXE ROM. You may buy a PXE ROM from some companies.

+--enable-dhcpvsi
+  Forces pxegrub to send a vendor specific DHCP option for all outgoing
+  traffic, and forces it to check all incoming traffic for a VS option.
+
 Here is the information about the device drivers. They are all disabled
 by default, so you must specify configure options to enable drivers you
 want to use. Some drivers have extra per-driver options, so the extra

diff --minimal --unified -r newgrub/grub/configure grub/configure
--- newgrub/grub/configure      2005-05-07 21:51:51.000000000 -0500
+++ grub/configure      2006-02-02 12:43:50.000000000 -0500
@@ -5571,6 +5571,15 @@
   NET_EXTRAFLAGS="$NET_EXTRAFLAGS -DCONFIG_PCI_DIRECT=1"
 fi

+# Check whether --enable-dhcpvsi or --disable-dhcpvsi was given.
+if test "${enable_dhcpvsi+set}" = set; then
+  enableval="$enable_dhcpvsi"
+
+fi;
+if test "x$enable_dhcpvsi" = xyes; then
+  NET_EXTRAFLAGS="$NET_EXTRAFLAGS -DINCLUDE_DHCPVSI=1"
+fi
+
 # Check whether --enable-3c509 or --disable-3c509 was given.
 if test "${enable_3c509+set}" = set; then
   enableval="$enable_3c509"

diff --minimal --unified -r newgrub/grub/configure.ac grub/configure.ac
--- newgrub/grub/configure.ac   2005-05-07 21:51:51.000000000 -0500
+++ grub/configure.ac   2006-02-02 12:34:17.000000000 -0500
@@ -326,6 +326,12 @@
   NET_EXTRAFLAGS="$NET_EXTRAFLAGS -DCONFIG_PCI_DIRECT=1"
 fi

+AC_ARG_ENABLE(dhcpvsi,
+  [  --enable-dhcpvsi        enable VSI option for DHCP])
+if test "x$enable_dhcpvsi" = xyes; then
+  NET_EXTRAFLAGS="$NET_EXTRAFLAGS -DINCLUDE_DHCPVSI=1"
+fi
+
 dnl Device drivers.
 AC_ARG_ENABLE(3c509,
   [  --enable-3c509          enable 3Com509 driver])
