OpenVZ Forum


Home » Mailing lists » Devel » [PATCH 0/5] Diet struct net_device a bit
[PATCH 5/5] Cut off dn_ptr from net_device [message #22148 is a reply to message #22143] Mon, 22 October 2007 12:37 Go to previous messageGo to previous message
Pavel Emelianov is currently offline  Pavel Emelianov
Messages: 1149
Registered: September 2006
Senior Member
And remove a BUG_TRAP from netdev_run_todo as well.

Signed-off-by: Pavel Emelyanov <xemul@openvz.org>

---

diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index 472d9cc..e94c636 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -577,7 +577,9 @@ struct net_device
 	
 	void 			*atalk_ptr;	/* AppleTalk link 	*/
 	void			*ip_ptr;	/* IPv4 specific data	*/  
+#if defined(CONFIG_DECNET) || defined(CONFIG_DECNET_MODULE)
 	void                    *dn_ptr;        /* DECnet specific data */
+#endif
 	void                    *ip6_ptr;       /* IPv6 specific data */
 #if defined(CONFIG_ECONET) || defined(CONFIG_ECONET_MODULE)
 	void			*ec_ptr;	/* Econet specific data	*/
diff --git a/net/core/dev.c b/net/core/dev.c
index 8726589..3ac35fe 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -3781,7 +3781,9 @@ void netdev_run_todo(void)
 		BUG_ON(atomic_read(&dev->refcnt));
 		BUG_TRAP(!dev->ip_ptr);
 		BUG_TRAP(!dev->ip6_ptr);
+#if defined(CONFIG_DECNET) || defined(CONFIG_DECNET_MODULE)
 		BUG_TRAP(!dev->dn_ptr);
+#endif
 
 		if (dev->destructor)
 			dev->destructor(dev);
-- 
1.5.3.4
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: [PATCH] nf_sockopts list head cleanup
Next Topic: Re: LSM and Containers (was: LSM conversion to static interface)
Goto Forum:
  


Current Time: Mon Oct 27 19:27:21 GMT 2025

Total time taken to generate the page: 0.12140 seconds