[Olsr-dev] [PATCH v1 0/9] Also consider link state

Bastian Bittorf (spam-protected)
Thu Feb 11 13:27:08 CET 2016


* Henning Rogge <(spam-protected)> [11.02.2016 13:19]:
> > needed. maybe it is enough to ask e.g.  '/sys/class/net/eth0.2/operstate'?
> > is it polled or does ethtool.h gives you an event?
> 
> The ethtool thing is my fault... I could not remember why we removed
> the IFF_RUNNING detection... so I suggested trying something
> different.
> 
> But if the ethtool output is broken TOO (on the routers), it will not help.

ethtool output will NOT work on switches, but
/sys/class/net/eth0.2/operstate will. it means if 1 port goes up
all ports are 'on'. so the worst case is, that it cannot be detected
if an interface goes down. I can give some more examples if needed.

the /sys/class/net/$INTERFACE/operstate thingy seems not
working on tap-devices ("unknown") but is fine with wifi.

bye, bastian



More information about the Olsr-dev mailing list