aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/vxlan.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2018-12-06 13:26:07 -0800
committerDavid S. Miller <davem@davemloft.net>2018-12-06 13:26:07 -0800
commitef2df7fc11f8847e9e1912c06fd9cfef1cca438c (patch)
treee5068b2df94dd9e3665f30167297072620d6897a /drivers/net/vxlan.c
parenttcp: fix code style in tcp_recvmsg() (diff)
parentselftests: mlxsw: Add a new test extack.sh (diff)
downloadlinux-dev-ef2df7fc11f8847e9e1912c06fd9cfef1cca438c.tar.xz
linux-dev-ef2df7fc11f8847e9e1912c06fd9cfef1cca438c.zip
Merge branch 'Pass-extack-to-NETDEV_PRE_UP'
Petr Machata says: ==================== Pass extack to NETDEV_PRE_UP Drivers may need to validate configuration of a device that's about to be upped. An example is mlxsw, which needs to check the configuration of a VXLAN device attached to an offloaded bridge. Should the validation fail, there's currently no way to communicate details of the failure to the user, beyond an error number. Therefore this patch set extends the NETDEV_PRE_UP event to include extack, if available. There are three vectors through which NETDEV_PRE_UP invocation can be reached. The two major ones are dev_open() and dev_change_flags(), the last is then __dev_change_flags(). In patch #1, the first access vector, dev_open() is addressed. An extack parameter is added and all users converted to use it. Before addressing the second vector, two preparatory patches propagate extack argument to the proximity of the dev_change_flags() call in VRF and IPVLAN drivers. That happens in patches #2 and #3. Then in patch #4, dev_change_flags() is treated similarly to dev_open(). Likewise in patch #5, __dev_change_flags() is extended. Then in patches #6 and #7, the extack is finally propagated all the way to the point where the notification is emitted. This change allows particularly mlxsw (which already has code to leverage extack if available) to communicate to the user error messages regarding VXLAN configuration. In patch #8, add a test case that exercises this code and checks that an error message is propagated. For example: local 192.0.2.17 remote 192.0.2.18 \ dstport 4789 nolearning noudpcsum tos inherit ttl 100 local 192.0.2.17 remote 192.0.2.18 \ dstport 4789 nolearning noudpcsum tos inherit ttl 100 Error: mlxsw_spectrum: Conflicting NVE tunnels configuration. v2: - Add David Ahern's tags. ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/vxlan.c')
0 files changed, 0 insertions, 0 deletions