OSDN Git Service

RDMA/uverbs: Fix RCU annotation for radix slot deference
authorJason Gunthorpe <jgg@mellanox.com>
Fri, 28 Sep 2018 22:28:02 +0000 (16:28 -0600)
committerJason Gunthorpe <jgg@mellanox.com>
Wed, 3 Oct 2018 22:01:40 +0000 (16:01 -0600)
commite73798f20ecb35f7d6c672d48d6b9da57c8cbf64
treeb8ee7f7b3a89ccc1d278b22c605cff360e93cd01
parent914e5d7d4697fb9815fa237a4d42bfb952bf48d6
RDMA/uverbs: Fix RCU annotation for radix slot deference

The uapi radix tree is a write-once data structure protected by kref.
Once we get to the ioctl() fop it is not possible for anything else
to be writing to it, so the access should use rcu_dereference_protected.

Reported-by: Matthew Wilcox <willy@infradead.org>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
drivers/infiniband/core/uverbs_ioctl.c