backport: fix netdev destructor backport for v4.11.9
authorLuca Coelho <luciano.coelho@intel.com>
Tue, 5 Sep 2017 06:50:39 +0000 (09:50 +0300)
committerJohannes Berg <johannes.berg@intel.com>
Wed, 6 Sep 2017 14:52:02 +0000 (16:52 +0200)
The patch that changed the netdev destructor code was backported to
v4.11.9, so handle that in the backport.

Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
backport/backport-include/linux/netdevice.h

index d22eec2d311355288fc4456544f5d388b57727ad..112bcf2b1c156935d2410b8e7a02e46df01d8ddb 100644 (file)
@@ -320,7 +320,8 @@ static inline void netif_trans_update(struct net_device *dev)
 }
 #endif
 
-#if LINUX_VERSION_IS_LESS(4,12,0)
+#if LINUX_VERSION_IS_LESS(4,12,0) &&           \
+       !LINUX_VERSION_IN_RANGE(4,11,9, 4,12,0)
 #define netdev_set_priv_destructor(_dev, _destructor) \
        (_dev)->destructor = __ ## _destructor
 #define netdev_set_def_destructor(_dev) \