]> git.baikalelectronics.ru Git - kernel.git/commit
RDMA/netlink: Avoid double pass for RDMA netlink messages
authorLeon Romanovsky <leonro@mellanox.com>
Thu, 8 Jun 2017 06:05:12 +0000 (09:05 +0300)
committerLeon Romanovsky <leon@kernel.org>
Thu, 10 Aug 2017 10:15:42 +0000 (13:15 +0300)
commit00d48908da4e562bbadc82f6fdbb2c29ec091c0b
tree357ac5b8943cda31ce53e0d29e576dc4029ec4f4
parent95b6725f62ea622a74e34a37999966b9fce9ac61
RDMA/netlink: Avoid double pass for RDMA netlink messages

The standard netlink_rcv_skb function skips messages without
NLM_F_REQUEST flag in it, while SA netlink client issues them.

In commit d204897f3813 ("IB/core: Add rdma netlink helper functions")
the local function was introduced to allow such messages.

This led to double pass for every incoming message.

In this patch, we unify that local implementation and netlink_rcv_skb
functions, so there will be no need for double pass anymore.

As a outcome, this combined function gained more strict check
for NLM_F_REQUEST flag and it is now allowed for SA pathquery
client only.

Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
drivers/infiniband/core/netlink.c