diff options
author | Leon Romanovsky <leonro@mellanox.com> | 2018-02-21 18:12:35 +0200 |
---|---|---|
committer | Doug Ledford <dledford@redhat.com> | 2018-02-22 22:29:11 -0500 |
commit | a9ed5b38aad704bbc250f9df2e9a29ee54388829 (patch) | |
tree | cad767da50270939cb9403a05b0843715df7ea92 /drivers/infiniband/core | |
parent | 43ae95130db8fb70010f09b734c7c606eb9e61ce (diff) | |
download | linux-stable-a9ed5b38aad704bbc250f9df2e9a29ee54388829.tar.gz linux-stable-a9ed5b38aad704bbc250f9df2e9a29ee54388829.tar.bz2 linux-stable-a9ed5b38aad704bbc250f9df2e9a29ee54388829.zip |
RDMA/uverbs: Return not supported error code for unsupported commands
Command that doesn't exist means that it is not supported,
so update code to return -EOPNOTSUPP in case of failure.
Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to 'drivers/infiniband/core')
-rw-r--r-- | drivers/infiniband/core/uverbs_main.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/infiniband/core/uverbs_main.c b/drivers/infiniband/core/uverbs_main.c index 2189a26bbe64..8d1547f5dc8e 100644 --- a/drivers/infiniband/core/uverbs_main.c +++ b/drivers/infiniband/core/uverbs_main.c @@ -714,7 +714,7 @@ static ssize_t ib_uverbs_write(struct file *filp, const char __user *buf, } if (!verify_command_idx(command, extended_command)) { - ret = -EINVAL; + ret = -EOPNOTSUPP; goto out; } |