CVSROOT: /cvs Module name: src Changes by: d...@cvs.openbsd.org 2018/02/11 18:43:42
Modified files: sys/net : if_etherip.c Log message: restore the previous semantics wrt if up, tunnel, and address config. our network drivers have a feature where if you configure an address on the interface, it implicitly brings the interface up. i changed etherip so you could only change the tunnel configuration while it down, but maintained the implicit up behaviour. bringing the tunnel up also relied on having valid configuration, ie, tunnel addreses must be configured otherwise up will fail. this means people who have address config in their hostname.etherip files before config for the tunnel addresses will have problems. firstly, the address wont be configured because falling through to the interface up fails because the tunnel isnt configured correctly, and that error makes the address config roll back. secondly, config that relies on configuring the address to bring the interface up will fail because there's no explicit up after the tunnel config. this diff rolls the tunnel config back to keeping the interface on a list, and allowing config at any time. the caveat to this is that it makes mpsafety hard because inconsistent intermediate states are visible when packets are being processed.