Changeset 15193 in vbox for trunk/src/VBox/HostDrivers/VBoxNetFlt
- Timestamp:
- Dec 9, 2008 4:51:30 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/HostDrivers/VBoxNetFlt/linux/VBoxNetFlt-linux.c
r14968 r15193 48 48 49 49 #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 22) 50 # define VBOX_SKB_TRANSPORT_HDR(skb) skb->transport_header 51 # define VBOX_SKB_NETWORK_HDR(skb) skb->network_header 52 # define VBOX_SKB_MAC_HDR(skb) skb->mac_header 50 # define VBOX_SKB_RESET_NETWORK_HDR(skb) skb_reset_network_header(skb) 51 # define VBOX_SKB_RESET_MAC_HDR(skb) skb_reset_mac_header(skb) 53 52 #else /* LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 22) */ 54 # define VBOX_SKB_TRANSPORT_HDR(skb) skb->h.raw 55 # define VBOX_SKB_NETWORK_HDR(skb) skb->nh.raw 56 # define VBOX_SKB_MAC_HDR(skb) skb->mac.raw 53 # define VBOX_SKB_RESET_NETWORK_HDR(skb) skb->nh.raw = skb->data 54 # define VBOX_SKB_RESET_MAC_HDR(skb) skb->mac.raw = skb->data 57 55 #endif /* LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 22) */ 58 56 … … 313 311 if (fDstWire) 314 312 { 315 VBOX_SKB_ NETWORK_HDR(pPkt) = pPkt->data;313 VBOX_SKB_RESET_NETWORK_HDR(pPkt); 316 314 /* Restore ethernet header back. */ 317 315 skb_push(pPkt, ETH_HLEN); 318 316 } 317 VBOX_SKB_RESET_MAC_HDR(pPkt); 319 318 VBOXNETFLT_SKB_CB(pPkt) = VBOXNETFLT_CB_TAG; 320 319 … … 714 713 715 714 { 716 int rc ;715 int rc = NOTIFY_OK; 717 716 #ifdef DEBUG 718 717 char *pszEvent = "<unknown>"; … … 884 883 if (fActive) 885 884 { 886 int err = 0;887 885 Assert(!pThis->u.s.fPromiscuousSet); 888 886 … … 895 893 { 896 894 rtnl_lock(); 897 err = dev_change_flags(pDev, fIf | IFF_UP);895 int err = dev_change_flags(pDev, fIf | IFF_UP); 898 896 rtnl_unlock(); 899 897 fIf = dev_get_flags(pDev);
Note:
See TracChangeset
for help on using the changeset viewer.