kernel: generic: Fix skip GRO for foreign MAC address patches
authorHauke Mehrtens <hauke@hauke-m.de>
Sat, 24 Feb 2018 11:47:59 +0000 (12:47 +0100)
committerFelix Fietkau <nbd@nbd.name>
Sat, 24 Feb 2018 15:05:28 +0000 (16:05 +0100)
Somewhere in the kernel 4.9 migration process it looks like this patch
was broken. The update should be done when a device is added to the
bridge and when it gets removed, currently it is only done on the remove
path twice which does not make any sense.
I do not have a setup to test this now so this is only compile tested.

Fixes: f791fb4af450 ("kernel: add linux 4.9 support")
Fixes: b3f95490b9be ("kernel: generic: Add kernel 4.14 support")
Reported-by: Andrey Jr. Melnikov <temnota.am@gmail.com>
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
target/linux/generic/pending-4.14/680-NET-skip-GRO-for-foreign-MAC-addresses.patch
target/linux/generic/pending-4.9/680-NET-skip-GRO-for-foreign-MAC-addresses.patch

index 5bcf99a64848e4dd86a267d07d68549ea8ed1b46..d565a1b8bd00ef17826367726a09dd2c36fd7578 100644 (file)
@@ -91,11 +91,18 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
  static int __netdev_upper_dev_link(struct net_device *dev,
                                   struct net_device *upper_dev, bool master,
                                   void *upper_priv, void *upper_info)
-@@ -6353,6 +6398,8 @@ void netdev_upper_dev_unlink(struct net_
+@@ -6276,6 +6321,7 @@ static int __netdev_upper_dev_link(struc
+       if (ret)
+               return ret;
++      netdev_update_addr_mask(dev);
+       ret = call_netdevice_notifiers_info(NETDEV_CHANGEUPPER, dev,
+                                           &changeupper_info.info);
+       ret = notifier_to_errno(ret);
+@@ -6353,6 +6399,7 @@ void netdev_upper_dev_unlink(struct net_
  
        __netdev_adjacent_dev_unlink_neighbour(dev, upper_dev);
  
-+      netdev_update_addr_mask(dev);
 +      netdev_update_addr_mask(dev);
        call_netdevice_notifiers_info(NETDEV_CHANGEUPPER, dev,
                                      &changeupper_info.info);
index ce13e719e32153b3d016ba081cf756fbcffc456b..5d432b1f3e7887f81ae94d7df91536e37149d341 100644 (file)
@@ -93,11 +93,18 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
  static int __netdev_upper_dev_link(struct net_device *dev,
                                   struct net_device *upper_dev, bool master,
                                   void *upper_priv, void *upper_info)
-@@ -6021,6 +6066,8 @@ void netdev_upper_dev_unlink(struct net_
+@@ -5895,6 +5940,7 @@ static int __netdev_upper_dev_link(struc
+                       goto rollback_lower_mesh;
+       }
++      netdev_update_addr_mask(dev);
+       ret = call_netdevice_notifiers_info(NETDEV_CHANGEUPPER, dev,
+                                           &changeupper_info.info);
+       ret = notifier_to_errno(ret);
+@@ -6021,6 +6067,7 @@ void netdev_upper_dev_unlink(struct net_
        list_for_each_entry(i, &upper_dev->all_adj_list.upper, list)
                __netdev_adjacent_dev_unlink(dev, i->dev, i->ref_nr);
  
-+      netdev_update_addr_mask(dev);
 +      netdev_update_addr_mask(dev);
        call_netdevice_notifiers_info(NETDEV_CHANGEUPPER, dev,
                                      &changeupper_info.info);