On Montag, 14. Mai 2018 06:38:49 CEST Marek Lindner wrote:
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
v2:
- added ethtool compat code for Linux < 4.6
- additional explanation text in the commit msg & code
Applied in d60b8fc69ef2 [1]
Thanks, Sven
[1] https://git.open-mesh.org/batman-adv.git/commit/d60b8fc69ef24d56a10b85210685...