summaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/ehca/ehca_main.c
diff options
context:
space:
mode:
authorAlexander Schmidt <alexs@linux.vnet.ibm.com>2010-06-10 09:06:53 +0000
committerRoland Dreier <rolandd@cisco.com>2010-07-19 13:23:32 -0700
commit91fb0dd9cb71ab1a90ab1f48c34b935fdbca55b9 (patch)
treee4e64985b1528b3095b356f0f242984377488d73 /drivers/infiniband/hw/ehca/ehca_main.c
parent589643be6693c46fbc54bae77745f336c8ed4bcc (diff)
IB/ehca: Fix bitmask handling for lock_hcalls
Fix reading hcall locking capability bit from device capabilities. Signed-off-by: Alexander Schmidt <alexs@linux.vnet.ibm.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'drivers/infiniband/hw/ehca/ehca_main.c')
-rw-r--r--drivers/infiniband/hw/ehca/ehca_main.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/infiniband/hw/ehca/ehca_main.c b/drivers/infiniband/hw/ehca/ehca_main.c
index ecb51b396c4..cfc4de7a5da 100644
--- a/drivers/infiniband/hw/ehca/ehca_main.c
+++ b/drivers/infiniband/hw/ehca/ehca_main.c
@@ -360,7 +360,8 @@ static int ehca_sense_attributes(struct ehca_shca *shca)
* a firmware property, so it's valid across all adapters
*/
if (ehca_lock_hcalls == -1)
- ehca_lock_hcalls = !(shca->hca_cap & HCA_CAP_H_ALLOC_RES_SYNC);
+ ehca_lock_hcalls = !EHCA_BMASK_GET(HCA_CAP_H_ALLOC_RES_SYNC,
+ shca->hca_cap);
/* translate supported MR page sizes; always support 4K */
shca->hca_cap_mr_pgsize = EHCA_PAGESIZE;