diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2022-03-16 11:39:48 +0300 |
---|---|---|
committer | Jason Gunthorpe <jgg@nvidia.com> | 2022-03-18 15:40:54 -0300 |
commit | 87e0eacb176f9500c2063d140c0a1d7fa51ab8a5 (patch) | |
tree | ca1be05ebaec1584c1bb63405614b6ad8a73a2ed /drivers/infiniband/hw/qib | |
parent | 2e11a5e459c1c4f1d27430d2707ec7ef77f371ca (diff) | |
download | linux-stable-87e0eacb176f9500c2063d140c0a1d7fa51ab8a5.tar.gz linux-stable-87e0eacb176f9500c2063d140c0a1d7fa51ab8a5.tar.bz2 linux-stable-87e0eacb176f9500c2063d140c0a1d7fa51ab8a5.zip |
RDMA/nldev: Prevent underflow in nldev_stat_set_counter_dynamic_doit()
This code checks "index" for an upper bound but it does not check for
negatives. Change the type to unsigned to prevent underflows.
Fixes: 3c3c1f141639 ("RDMA/nldev: Allow optional-counter status configuration through RDMA netlink")
Link: https://lore.kernel.org/r/20220316083948.GC30941@kili
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Leon Romanovsky <leonro@nvidia.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Diffstat (limited to 'drivers/infiniband/hw/qib')
0 files changed, 0 insertions, 0 deletions