IB/uverbs: Fix validating mandatory attributes
authorMatan Barak <matanb@mellanox.com>
Tue, 24 Apr 2018 08:15:20 +0000 (08:15 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 20 Jun 2018 19:02:50 +0000 (04:02 +0900)
commit84f66378da20a4efc07f6d7b35f31cd3327639f1
tree2ce7f996b6a982cc988fa69c91b6d0f3ce50e980
parentfb019834bf8e717a0fc0c67f4a61d4455e3cfec1
IB/uverbs: Fix validating mandatory attributes

[ Upstream commit f604db645a66b7ba4f21c426fe73253928dada41 ]

Previously, if a method contained mandatory attributes in a namespace
that wasn't given by the user, these attributes weren't validated.
Fixing this by iterating over all specification namespaces.

Fixes: fac9658cabb9 ("IB/core: Add new ioctl interface")
Signed-off-by: Matan Barak <matanb@mellanox.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/infiniband/core/uverbs_ioctl.c