VirtualBox

Ignore:
Timestamp:
May 6, 2015 1:00:14 AM (10 years ago)
Author:
vboxsync
Message:

VBoxNetFlt/linux: dev_net() appeared in 2.6.26

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/HostDrivers/VBoxNetFlt/linux/VBoxNetFlt-linux.c

    r55653 r55679  
    6868#ifndef VBOXNETFLT_LINUX_NO_XMIT_QUEUE
    6969# define VBOX_FLT_XT_TO_INST(pXT)   RT_FROM_MEMBER(pXT, VBOXNETFLTINS, u.s.XmitTask)
     70#endif
     71
     72#if 0
     73#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 22)
     74# define VBOX_NETDEV_NAME(dev)              netdev_name(dev)
     75#else
     76# define VBOX_NETDEV_NAME(dev)              ((dev)->reg_state != NETREG_REGISTERED ? "(unregistered net_device)" : (dev)->name)
     77#endif
     78#endif
     79
     80#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 26)
     81# define VBOX_DEV_NET(dev)                  dev_net(dev)
     82#else
     83# define VBOX_DEV_NET(dev)                  ((dev)->nd_net)
    7084#endif
    7185
     
    21602174    if (pThis->pSwitchPort->pfnNotifyHostAddress)
    21612175    {
    2162         struct net *net = dev_net(pThis->u.s.pDev);
     2176        struct net *net = VBOX_DEV_NET(pThis->u.s.pDev);
    21632177        struct net_device *dev;
    21642178
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette