]> git.baikalelectronics.ru Git - kernel.git/commit
RDMA/ocrdma: Fix off by one in ocrdma_query_gid()
authorDan Carpenter <dan.carpenter@oracle.com>
Mon, 16 Feb 2015 10:01:36 +0000 (13:01 +0300)
committerRoland Dreier <roland@purestorage.com>
Wed, 18 Feb 2015 16:31:06 +0000 (08:31 -0800)
commited9afd53005d294d7cf73d47b9344040f432e9b0
treefd19996d49c158c5dd612c9f7d000434ce8610c1
parenta5f85dc0450d4c137295228e0df96213d34eaf2a
RDMA/ocrdma: Fix off by one in ocrdma_query_gid()

The ->sgid_tbl[] array has OCRDMA_MAX_SGID number of elements so this
test is off by one.  ->sgid_tbl is allocated in ocrdma_alloc_resources().

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Selvin Xavier <selvin.xavier@emulex.com>
Signed-off-by: Roland Dreier <roland@purestorage.com>
drivers/infiniband/hw/ocrdma/ocrdma_verbs.c