bjorn at mork.no
Fri Apr 11 01:59:04 PDT 2014
Aleksander Morgado <aleksander at aleksander.es> writes:
>> In the end, there is still no protection against turing wwan down while the
>> vlan is in use. It seems to me that some additional mechanism is needed in
>> the kernel driver to ensure that.
> Yeah.. that's true... :/
Sounds reasonable. It would have been nice if there was some generic
VLAN policy for this. But I don't think there is? I tried to look for
something useful, but the closest I found was the 'loose_binding' flag.
Which will allow you to add a VLAN link even if the master interface is
down, but it still won't be able to forward any traffic so it doesn't
Maybe this will just have to end up as another hack in the driver.
Something like: if any VLAN subinterface is running, then we do not
allow closing the master interface.
Does anyone know of any driver doing something similar? That would
help... But I guess not, as the need for this is caused by the
over-creative usage of VLAN interfaces in this driver.
Maybe we should add it as a generic VLAN policy instead of a driver
Another terrible hack I could think of, allowing userspace to decouple
the master interface from the "session 0 IP interface", is to add an
*optional* magic VLAN for IP session 0. So if you add VLAN 1024 (or
whatever) then the driver will use that for session 0 instead of
untagged traffic. That way you don't need to worry about handing the
master interface over to some IP management application, and you are
free to set the MTU etc on the master interface independently of the IP
session 0 MTU.
I believe this could work, but it is going to add to the already complex
and weird userspace API.. Note that we won't change the default
behaviour. So if you don't add the new magic VLAN, the IP session 0 is
mapped to the untagged master interface.
Crazy? No need to hold back on the comments - I know most of my ideas
are best forgotten :-)
More information about the libmbim-devel