]> git.baikalelectronics.ru Git - kernel.git/commit
IB/hfi1: Set in_use_ctxts bits for user ctxts only
authorMichael J. Ruhl <michael.j.ruhl@intel.com>
Mon, 2 Jul 2018 15:08:27 +0000 (08:08 -0700)
committerJason Gunthorpe <jgg@mellanox.com>
Tue, 3 Jul 2018 20:29:12 +0000 (14:29 -0600)
commit127b530f148f97902e61130265372d7188777a35
tree62db1fb8046ef37d3b8cd2c781f35e3daeace4ab
parent337471d08c88660452f3abd67fd3a41a2768c61b
IB/hfi1: Set in_use_ctxts bits for user ctxts only

The in_use_ctxts bitmask is for user receive contexts only.  Setting it for
any other type of receive context is incorrect.

Move initial set of in_use_ctxts bits from the general context init to the
user context specific init. Having this bit set can allow contexts to be
incorrectly identified by some IRQ handlers. This will allow
handle_user_interrupt() will now filter user contexts correctly.

Clean up redundant is_rcv_urgent_int() user context check.

A follow on patch will clean up an incorrect code path in the
is_rcv_avail_int().

Fixes: 40c1f3eab50d ("IB/hfi1: Fix an assign/ordering issue with shared context IDs")
Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com>
Reviewed-by: Kamenee Arumugam <kamenee.arumugam@intel.com>
Signed-off-by: Michael J. Ruhl <michael.j.ruhl@intel.com>
Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
drivers/infiniband/hw/hfi1/chip.c
drivers/infiniband/hw/hfi1/file_ops.c
drivers/infiniband/hw/hfi1/init.c