]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
batman-adv: drop duplicated wifi_flags assignments
authorSven Eckelmann <sven@narfation.org>
Tue, 2 Jun 2026 15:41:15 +0000 (17:41 +0200)
committerSven Eckelmann <sven@narfation.org>
Fri, 5 Jun 2026 07:12:06 +0000 (09:12 +0200)
During the initialization of the batadv_wifi_net_device_state, it is enough
to write the wifi_flags once before the batadv_wifi_net_device_state is
added to the batadv_wifi_net_devices rhashtable.

Signed-off-by: Sven Eckelmann <sven@narfation.org>
net/batman-adv/hard-interface.c

index 43ebf86e7b3686796e21ae1537a9939ba1b01973..96b8130375a3af96aea99cef301fe8fcaa6c275c 100644 (file)
@@ -987,7 +987,6 @@ batadv_wifi_net_device_insert(struct net_device *net_dev, u32 wifi_flags)
        if (!device_state)
                return -ENOMEM;
 
-       device_state->wifi_flags = wifi_flags;
        netdev_hold(net_dev, &device_state->dev_tracker, GFP_ATOMIC);
        device_state->netdev = net_dev;
        WRITE_ONCE(device_state->wifi_flags, wifi_flags);