diff options
author | Jason Gunthorpe <jgg@mellanox.com> | 2018-11-25 20:51:17 +0200 |
---|---|---|
committer | Jason Gunthorpe <jgg@mellanox.com> | 2018-11-26 16:48:07 -0700 |
commit | da0f60df7bd5a045aa423ec64fe5d7e29ba803ff (patch) | |
tree | 08a0c90e7d48bc5ba6b442b544c9527f2682cbc7 /drivers/android | |
parent | 669dac1e00c50a65cb8ecf08862c3c9dd7a29a98 (diff) |
RDMA/uverbs: Prohibit write() calls with too small buffers
The size meta-data in the prior patch describes the smallest acceptable
buffer for the write() interface. Globally check this in the core code.
This is necessary in the case of write() methods that have a driver udata
to prevent computing a negative udata buffer length.
The return code of -ENOSPC is chosen here as some of the handlers already
use this code, however many other handler use EINVAL.
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Diffstat (limited to 'drivers/android')
0 files changed, 0 insertions, 0 deletions