summaryrefslogtreecommitdiff
path: root/drivers/infiniband/sw
diff options
context:
space:
mode:
authorJiewei Ke <kejiewei.cn@gmail.com>2019-12-27 19:36:13 +0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-02-24 08:34:44 +0100
commit1a0ea3b872f8408cad3e9187958d6ea0e848a11e (patch)
tree378c1dac5ae23c479cc32fc864ea3d2cc2027764 /drivers/infiniband/sw
parent14e843570f05168ae1b915cc43dae75d692dda8e (diff)
downloadlinux-1a0ea3b872f8408cad3e9187958d6ea0e848a11e.tar.gz
linux-1a0ea3b872f8408cad3e9187958d6ea0e848a11e.tar.bz2
linux-1a0ea3b872f8408cad3e9187958d6ea0e848a11e.zip
RDMA/rxe: Fix error type of mmap_offset
[ Upstream commit 6ca18d8927d468c763571f78c9a7387a69ffa020 ] The type of mmap_offset should be u64 instead of int to match the type of mminfo.offset. If otherwise, after we create several thousands of CQs, it will run into overflow issues. Link: https://lore.kernel.org/r/20191227113613.5020-1-kejiewei.cn@gmail.com Signed-off-by: Jiewei Ke <kejiewei.cn@gmail.com> Reviewed-by: Jason Gunthorpe <jgg@mellanox.com> Signed-off-by: Jason Gunthorpe <jgg@mellanox.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'drivers/infiniband/sw')
-rw-r--r--drivers/infiniband/sw/rxe/rxe_verbs.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/infiniband/sw/rxe/rxe_verbs.h b/drivers/infiniband/sw/rxe/rxe_verbs.h
index 6a75f96b9096..b4e24362edbb 100644
--- a/drivers/infiniband/sw/rxe/rxe_verbs.h
+++ b/drivers/infiniband/sw/rxe/rxe_verbs.h
@@ -407,7 +407,7 @@ struct rxe_dev {
struct list_head pending_mmaps;
spinlock_t mmap_offset_lock; /* guard mmap_offset */
- int mmap_offset;
+ u64 mmap_offset;
atomic64_t stats_counters[RXE_NUM_OF_COUNTERS];