linux_old1/net/batman-adv
Sven Eckelmann 7c946062b3 batman-adv: Fix double call of dev_queue_xmit
The net_xmit_eval has side effects because it is not making sure that e
isn't evaluated twice.

    #define net_xmit_eval(e)        ((e) == NET_XMIT_CN ? 0 : (e))

The code requested by David Miller [1]

    return net_xmit_eval(dev_queue_xmit(skb));

will get transformed into

    return ((dev_queue_xmit(skb)) == NET_XMIT_CN ? 0 : (dev_queue_xmit(skb)))

dev_queue_xmit will therefore be tried again (with an already consumed skb)
whenever the return code is not NET_XMIT_CN.

[1] https://lkml.kernel.org/r/20170125.225624.965229145391320056.davem@davemloft.net

Fixes: c33705188c ("batman-adv: Treat NET_XMIT_CN as transmit successfully")
Signed-off-by: Sven Eckelmann <sven@narfation.org>
Signed-off-by: Simon Wunderlich <sw@simonwunderlich.de>
2017-01-28 10:40:35 +01:00
..
Kconfig batman-adv: Allow selecting BATMAN V if CFG80211 is not built 2016-10-17 16:28:48 +02:00
Makefile batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
bat_algo.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
bat_algo.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
bat_iv_ogm.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
bat_iv_ogm.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
bat_v.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
bat_v.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
bat_v_elp.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
bat_v_elp.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
bat_v_ogm.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
bat_v_ogm.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
bitarray.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
bitarray.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
bridge_loop_avoidance.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
bridge_loop_avoidance.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
debugfs.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
debugfs.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
distributed-arp-table.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
distributed-arp-table.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
fragmentation.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
fragmentation.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
gateway_client.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
gateway_client.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
gateway_common.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
gateway_common.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
hard-interface.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
hard-interface.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
hash.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
hash.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
icmp_socket.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
icmp_socket.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
log.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
log.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
main.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
main.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
multicast.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
multicast.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
netlink.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
netlink.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
network-coding.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
network-coding.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
originator.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
originator.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
packet.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
routing.c batman-adv: Remove one condition check in batadv_route_unicast_packet 2017-01-26 08:37:01 +01:00
routing.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
send.c batman-adv: Fix double call of dev_queue_xmit 2017-01-28 10:40:35 +01:00
send.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
soft-interface.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
soft-interface.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
sysfs.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
sysfs.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
tp_meter.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
tp_meter.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
translation-table.c batman-adv: Remove unused variable in batadv_tt_local_set_flags 2017-01-26 08:34:20 +01:00
translation-table.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
tvlv.c batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
tvlv.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00
types.h batman-adv: update copyright years for 2017 2017-01-26 08:34:19 +01:00