RDMA/nldev: Return an error message on failure to turn auto mode
authorPatrisious Haddad <phaddad@nvidia.com>
Wed, 30 Dec 2020 13:02:40 +0000 (15:02 +0200)
committerJason Gunthorpe <jgg@nvidia.com>
Mon, 18 Jan 2021 20:02:14 +0000 (16:02 -0400)
commit33eb12f2966ef9c529ce7138711a9c150a17931e
tree9c11432e0795dcc649c11356d687705c603b3e04
parent7fbc3c373eefc291ff96d48496106c106b7f81c6
RDMA/nldev: Return an error message on failure to turn auto mode

The bounded counter can't be reconfigured to be in auto mode, in attempt
to do it, the user will get an error, but without any hint why. Update
nldev interface to return an error message through extack mechanism.

Link: https://lore.kernel.org/r/20201230130240.180737-1-leon@kernel.org
Signed-off-by: Patrisious Haddad <phaddad@nvidia.com>
Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
drivers/infiniband/core/counters.c
drivers/infiniband/core/nldev.c
include/rdma/rdma_counter.h