From patchwork Thu Jun 10 09:06:53 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexander Schmidt X-Patchwork-Id: 105333 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o5A96wq4003919 for ; Thu, 10 Jun 2010 09:06:58 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758700Ab0FJJG5 (ORCPT ); Thu, 10 Jun 2010 05:06:57 -0400 Received: from mtagate4.uk.ibm.com ([194.196.100.164]:33313 "EHLO mtagate4.uk.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752960Ab0FJJG4 (ORCPT ); Thu, 10 Jun 2010 05:06:56 -0400 Received: from d06nrmr1806.portsmouth.uk.ibm.com (d06nrmr1806.portsmouth.uk.ibm.com [9.149.39.193]) by mtagate4.uk.ibm.com (8.13.1/8.13.1) with ESMTP id o5A96tWU022934; Thu, 10 Jun 2010 09:06:55 GMT Received: from d06av02.portsmouth.uk.ibm.com (d06av02.portsmouth.uk.ibm.com [9.149.37.228]) by d06nrmr1806.portsmouth.uk.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id o5A96t4Q1171476; Thu, 10 Jun 2010 10:06:55 +0100 Received: from d06av02.portsmouth.uk.ibm.com (loopback [127.0.0.1]) by d06av02.portsmouth.uk.ibm.com (8.12.11.20060308/8.13.3) with ESMTP id o5A96sAE026667; Thu, 10 Jun 2010 10:06:55 +0100 Received: from alex-laptop (dyn-9-152-241-49.boeblingen.de.ibm.com [9.152.241.49]) by d06av02.portsmouth.uk.ibm.com (8.12.11.20060308/8.12.11) with ESMTP id o5A96sAa026648; Thu, 10 Jun 2010 10:06:54 +0100 Date: Thu, 10 Jun 2010 11:06:53 +0200 From: Alexander Schmidt To: Roland Dreier , Linux RDMA Cc: lkml , Stefan Roscher , Joachim Fenkes , Christoph Raisch , Hoang-Nam Nguyen Subject: [PATCH] ib/ehca: bitmask handling for lock_hcalls Message-ID: <20100610110653.17885a81@alex-laptop> X-Mailer: Claws Mail 3.6.1 (GTK+ 2.16.1; i486-pc-linux-gnu) Mime-Version: 1.0 Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Thu, 10 Jun 2010 09:06:58 +0000 (UTC) --- linux-2.6.35-rc2.orig/drivers/infiniband/hw/ehca/ehca_main.c +++ linux-2.6.35-rc2/drivers/infiniband/hw/ehca/ehca_main.c @@ -360,7 +360,8 @@ static int ehca_sense_attributes(struct * 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;