diff options
author | Eli Cohen <eli@dev.mellanox.co.il> | 2014-09-14 16:47:52 +0300 |
---|---|---|
committer | Roland Dreier <roland@purestorage.com> | 2014-10-09 00:08:40 -0700 |
commit | 377b513485fd885dea1083a9a5430df65b35e048 (patch) | |
tree | 3947b460bda50002a70cbb9dad074d9cda8d3bad | |
parent | 900a6d79176ea9172e19f86aa324e9198b40339c (diff) | |
download | op-kernel-dev-377b513485fd885dea1083a9a5430df65b35e048.zip op-kernel-dev-377b513485fd885dea1083a9a5430df65b35e048.tar.gz |
IB/core: Avoid leakage from kernel to user space
Clear the reserved field of struct ib_uverbs_async_event_desc which is
copied to user space.
Signed-off-by: Eli Cohen <eli@mellanox.com>
Reviewed-by: Yann Droneaud <ydroneaud@opteya.com>
Signed-off-by: Roland Dreier <roland@purestorage.com>
-rw-r--r-- | drivers/infiniband/core/uverbs_main.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/infiniband/core/uverbs_main.c b/drivers/infiniband/core/uverbs_main.c index c73b22a..b21af1e 100644 --- a/drivers/infiniband/core/uverbs_main.c +++ b/drivers/infiniband/core/uverbs_main.c @@ -477,6 +477,7 @@ static void ib_uverbs_async_handler(struct ib_uverbs_file *file, entry->desc.async.element = element; entry->desc.async.event_type = event; + entry->desc.async.reserved = 0; entry->counter = counter; list_add_tail(&entry->list, &file->async_file->event_list); |