]> git.baikalelectronics.ru Git - kernel.git/commit
batman-adv: disable ethtool link speed detection when auto negotiation off
authorMarek Lindner <mareklindner@neomailbox.ch>
Sun, 13 May 2018 22:38:49 +0000 (06:38 +0800)
committerSimon Wunderlich <sw@simonwunderlich.de>
Mon, 14 May 2018 07:30:57 +0000 (09:30 +0200)
commit341ea390762fd94c0256c8d4a76d99364c85d646
tree1048de2ca86bed96050c0d827a10a34fa733f99f
parent5cdc4be29d3ab680d9a2ae31d7d16265e5b392fc
batman-adv: disable ethtool link speed detection when auto negotiation off

Virtual interface drivers such as tun / tap interfaces, VLAN, etc tend
to initialize the interface throughput with some value for the sake of
having a throughput number to export via ethtool. This exported
throughput leaves batman-adv to conclude the interface throughput is
genuine (reflecting reality), thus no measurements are necessary.

Based on the observation that those interface types also tend to set
the link auto-negotiation to 'off', batman-adv shall check this
setting to differentiate between genuine link throughput information
and placeholders installed by virtual interfaces.

The "default throughput" setting exported via sysfs still allows to
configure the batman-adv throughput for the interface, thus disabling
the measurements.

Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch>
Acked-by: Antonio Quartulli <a@unstable.cc>
Signed-off-by: Sven Eckelmann <sven@narfation.org>
Signed-off-by: Simon Wunderlich <sw@simonwunderlich.de>
net/batman-adv/bat_v_elp.c