]> git.baikalelectronics.ru Git - kernel.git/commit
rtnetlink: fallback to UNSPEC if current family has no doit callback
authorFlorian Westphal <fw@strlen.de>
Thu, 10 Aug 2017 14:53:01 +0000 (16:53 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 10 Aug 2017 16:50:22 +0000 (09:50 -0700)
commit8ed7275e3b98bc6148996318d98d8e0a7eb1b01c
tree2bfea64354f5fc77b88e1a4b1d84db0de185f7e4
parent8e570f3e2c1a674b71a5aa8c086427d413e53a21
rtnetlink: fallback to UNSPEC if current family has no doit callback

We need to use PF_UNSPEC in case the requested family has no doit
callback, otherwise this now fails with EOPNOTSUPP instead of running the
unspec doit callback, as before.

Fixes: cf175bd081cb ("rtnetlink: protect handler table with rcu")
Signed-off-by: Florian Westphal <fw@strlen.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/core/rtnetlink.c