diff options
Diffstat (limited to 'include/linux/netdevice.h')
-rw-r--r-- | include/linux/netdevice.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index a1c2c2204498..fdac1159253e 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h | |||
@@ -808,7 +808,9 @@ void dev_net_set(struct net_device *dev, struct net *net) | |||
808 | */ | 808 | */ |
809 | static inline void *netdev_priv(const struct net_device *dev) | 809 | static inline void *netdev_priv(const struct net_device *dev) |
810 | { | 810 | { |
811 | return dev->priv; | 811 | return (char *)dev + ((sizeof(struct net_device) |
812 | + NETDEV_ALIGN_CONST) | ||
813 | & ~NETDEV_ALIGN_CONST); | ||
812 | } | 814 | } |
813 | 815 | ||
814 | /* Set the sysfs physical device reference for the network logical device | 816 | /* Set the sysfs physical device reference for the network logical device |