Patchwork [RFC,v7,06/19] Add a function to indicate if device use external buffer.

login
register
mail settings
Submitter Xin, Xiaohui
Date June 5, 2010, 10:14 a.m.
Message ID <1275732899-5423-6-git-send-email-xiaohui.xin@intel.com>
Download mbox | patch
Permalink /patch/54763/
State RFC
Delegated to: David Miller
Headers show

Comments

Xin, Xiaohui - June 5, 2010, 10:14 a.m.
From: Xin Xiaohui <xiaohui.xin@intel.com>

Signed-off-by: Xin Xiaohui <xiaohui.xin@intel.com>
Signed-off-by: Zhao Yu <yzhao81new@gmail.com>
Reviewed-by: Jeff Dike <jdike@linux.intel.com>
---
 include/linux/netdevice.h |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

Patch

diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index 31d9c4a..0cb78f4 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -1602,6 +1602,11 @@  extern void netdev_mp_port_detach(struct net_device *dev);
 extern int netdev_mp_port_prep(struct net_device *dev,
 			struct mpassthru_port *port);
 
+static inline bool dev_is_mpassthru(struct net_device *dev)
+{
+	return (dev && dev->mp_port);
+}
+
 static inline void napi_free_frags(struct napi_struct *napi)
 {
 	kfree_skb(napi->skb);