[prev in list] [next in list] [prev in thread] [next in thread] 

List:       linux-backports
Subject:    [PATCH 8/8] patches: patches: Restrict MTU changes to struct net_device
From:       Hauke Mehrtens <hauke () hauke-m ! de>
Date:       2020-04-19 17:10:39
Message-ID: 20200419171039.17268-9-hauke () hauke-m ! de
[Download RAW message or body]

The struct ieee80211_hw got a max_mtu element, but no min_mtu element.
This spatch was also applied to this structure accidentally.

This adds the type to make sure this spatch is only applied to mtu_min
and mtu_max attributes on the net_device structure.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 patches/0073-netdevice-mtu-range.cocci        | 6 +++---
 patches/0074-netdevice-mtu-range-ifdefs.cocci | 4 ++--
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/patches/0073-netdevice-mtu-range.cocci \
b/patches/0073-netdevice-mtu-range.cocci index 7a4b6532..7afe900e 100644
--- a/patches/0073-netdevice-mtu-range.cocci
+++ b/patches/0073-netdevice-mtu-range.cocci
@@ -4,7 +4,7 @@
 first_ops = 0
 
 @both@
-expression ndevexp;
+struct net_device *ndevexp;
 constant e1, e2;
 identifier func;
 position p;
@@ -17,7 +17,7 @@ func(...) {
 }
 
 @@
-expression ndevexp;
+struct net_device *ndevexp;
 constant MAX;
 identifier func;
 position p != both.p;
@@ -58,7 +58,7 @@ if not(first_ops == ln):
   cocci.include_match(False)
 
 @r1 exists@
-expression ndevexp;
+struct net_device *ndevexp;
 constant e1, e2;
 identifier func;
 @@
diff --git a/patches/0074-netdevice-mtu-range-ifdefs.cocci \
b/patches/0074-netdevice-mtu-range-ifdefs.cocci index 5689f438..bb1ca95c 100644
--- a/patches/0074-netdevice-mtu-range-ifdefs.cocci
+++ b/patches/0074-netdevice-mtu-range-ifdefs.cocci
@@ -1,5 +1,5 @@
 @@
-expression ndevexp;
+struct net_device *ndevexp;
 expression E;
 identifier func;
 @@
@@ -12,7 +12,7 @@ func(...) {
 }
 
 @@
-expression ndevexp;
+struct net_device *ndevexp;
 expression E;
 identifier func;
 @@
-- 
2.20.1

--
To unsubscribe from this list: send the line "unsubscribe backports" in


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic