diff options
author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2013-12-09 22:22:40 -0800 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2013-12-09 22:22:40 -0800 |
commit | 5d43889c07bb38694742936aa70d1187c012e198 (patch) | |
tree | 73809dddae39ae3b746396e9779142dbd1973f33 /include/linux/if_macvlan.h | |
parent | 95f75e91588afecfb0090988393653d21f5d1f91 (diff) | |
parent | 374b105797c3d4f29c685f3be535c35f5689b30e (diff) | |
download | linux-5d43889c07bb38694742936aa70d1187c012e198.tar.gz linux-5d43889c07bb38694742936aa70d1187c012e198.tar.bz2 linux-5d43889c07bb38694742936aa70d1187c012e198.zip |
Merge tag 'v3.13-rc3' into for-linus
Merging with the mainline to sync up on changes to serio core.
Diffstat (limited to 'include/linux/if_macvlan.h')
-rw-r--r-- | include/linux/if_macvlan.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/include/linux/if_macvlan.h b/include/linux/if_macvlan.h index ddd33fd5904d..84ba5ac39e03 100644 --- a/include/linux/if_macvlan.h +++ b/include/linux/if_macvlan.h @@ -61,6 +61,7 @@ struct macvlan_dev { struct hlist_node hlist; struct macvlan_port *port; struct net_device *lowerdev; + void *fwd_priv; struct macvlan_pcpu_stats __percpu *pcpu_stats; DECLARE_BITMAP(mc_filter, MACVLAN_MC_FILTER_SZ); @@ -118,4 +119,21 @@ extern int macvlan_link_register(struct rtnl_link_ops *ops); extern netdev_tx_t macvlan_start_xmit(struct sk_buff *skb, struct net_device *dev); +#if IS_ENABLED(CONFIG_MACVLAN) +static inline struct net_device * +macvlan_dev_real_dev(const struct net_device *dev) +{ + struct macvlan_dev *macvlan = netdev_priv(dev); + + return macvlan->lowerdev; +} +#else +static inline struct net_device * +macvlan_dev_real_dev(const struct net_device *dev) +{ + BUG(); + return NULL; +} +#endif + #endif /* _LINUX_IF_MACVLAN_H */ |