aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/e1000
diff options
context:
space:
mode:
authorJeff Garzik <jgarzik@pobox.com>2005-12-03 21:08:17 -0500
committerJeff Garzik <jgarzik@pobox.com>2005-12-03 21:08:17 -0500
commitfd8a882b612de93b351996ed42a9557afc1f8c34 (patch)
treebaadcaa7217cc40f41f04eb40c0d1236cf462716 /drivers/net/e1000
parentc8a4f06e4b27dba425ed49fa603d9257e4cd9ece (diff)
parent3b6efee9231e12fce09c94930bfc59f66f18d662 (diff)
Merge branch 'master'
Diffstat (limited to 'drivers/net/e1000')
-rw-r--r--drivers/net/e1000/e1000_main.c14
1 files changed, 1 insertions, 13 deletions
diff --git a/drivers/net/e1000/e1000_main.c b/drivers/net/e1000/e1000_main.c
index 8b207f0e139e..e0ae248b4313 100644
--- a/drivers/net/e1000/e1000_main.c
+++ b/drivers/net/e1000/e1000_main.c
@@ -2621,19 +2621,7 @@ e1000_transfer_dhcp_info(struct e1000_adapter *adapter, struct sk_buff *skb)
2621 E1000_MNG_DHCP_COOKIE_STATUS_VLAN_SUPPORT)) ) 2621 E1000_MNG_DHCP_COOKIE_STATUS_VLAN_SUPPORT)) )
2622 return 0; 2622 return 0;
2623 } 2623 }
2624 if(htons(ETH_P_IP) == skb->protocol) { 2624 if ((skb->len > MINIMUM_DHCP_PACKET_SIZE) && (!skb->protocol)) {
2625 const struct iphdr *ip = skb->nh.iph;
2626 if(IPPROTO_UDP == ip->protocol) {
2627 struct udphdr *udp = (struct udphdr *)(skb->h.uh);
2628 if(ntohs(udp->dest) == 67) {
2629 offset = (uint8_t *)udp + 8 - skb->data;
2630 length = skb->len - offset;
2631
2632 return e1000_mng_write_dhcp_info(hw,
2633 (uint8_t *)udp + 8, length);
2634 }
2635 }
2636 } else if((skb->len > MINIMUM_DHCP_PACKET_SIZE) && (!skb->protocol)) {
2637 struct ethhdr *eth = (struct ethhdr *) skb->data; 2625 struct ethhdr *eth = (struct ethhdr *) skb->data;
2638 if((htons(ETH_P_IP) == eth->h_proto)) { 2626 if((htons(ETH_P_IP) == eth->h_proto)) {
2639 const struct iphdr *ip = 2627 const struct iphdr *ip =