From patchwork Tue Sep 25 01:07:16 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: NeilBrown X-Patchwork-Id: 10613215 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 2A52E1390 for ; Tue, 25 Sep 2018 01:13:25 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2EA3429050 for ; Tue, 25 Sep 2018 01:13:25 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 233FB290EA; Tue, 25 Sep 2018 01:13:25 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from pdx1-mailman02.dreamhost.com (pdx1-mailman02.dreamhost.com [64.90.62.194]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id DC51D29050 for ; Tue, 25 Sep 2018 01:13:24 +0000 (UTC) Received: from pdx1-mailman02.dreamhost.com (localhost [IPv6:::1]) by pdx1-mailman02.dreamhost.com (Postfix) with ESMTP id 810E64C43A4; Mon, 24 Sep 2018 18:13:24 -0700 (PDT) X-Original-To: lustre-devel@lists.lustre.org Delivered-To: lustre-devel-lustre.org@pdx1-mailman02.dreamhost.com Received: from mx1.suse.de (mx2.suse.de [195.135.220.15]) by pdx1-mailman02.dreamhost.com (Postfix) with ESMTP id 759EB4C4383 for ; Mon, 24 Sep 2018 18:13:23 -0700 (PDT) X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id B6918B032; Tue, 25 Sep 2018 01:13:22 +0000 (UTC) From: NeilBrown To: Oleg Drokin , Doug Oucharek , James Simmons , Andreas Dilger Date: Tue, 25 Sep 2018 11:07:16 +1000 Message-ID: <153783763611.32103.14845537928418369718.stgit@noble> In-Reply-To: <153783752960.32103.8394391715843917125.stgit@noble> References: <153783752960.32103.8394391715843917125.stgit@noble> User-Agent: StGit/0.17.1-dirty MIME-Version: 1.0 Subject: [lustre-devel] [PATCH 33/34] lnet: use BIT() macro for LNET_MD_* flags X-BeenThere: lustre-devel@lists.lustre.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "For discussing Lustre software development." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Lustre Development List Errors-To: lustre-devel-bounces@lists.lustre.org Sender: "lustre-devel" X-Virus-Scanned: ClamAV using ClamSMTP As these are bit flags, it aids clarity to use the BIT() macro. Signed-off-by: NeilBrown --- .../lustre/include/uapi/linux/lnet/lnet-types.h | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/drivers/staging/lustre/include/uapi/linux/lnet/lnet-types.h b/drivers/staging/lustre/include/uapi/linux/lnet/lnet-types.h index e80ef4182e5d..62f062c0d1bf 100644 --- a/drivers/staging/lustre/include/uapi/linux/lnet/lnet-types.h +++ b/drivers/staging/lustre/include/uapi/linux/lnet/lnet-types.h @@ -483,22 +483,22 @@ struct lnet_md { /** * Options for the MD structure. See lnet_md::options. */ -#define LNET_MD_OP_PUT (1 << 0) +#define LNET_MD_OP_PUT BIT(0) /** See lnet_md::options. */ -#define LNET_MD_OP_GET (1 << 1) +#define LNET_MD_OP_GET BIT(1) /** See lnet_md::options. */ -#define LNET_MD_MANAGE_REMOTE (1 << 2) -/* unused (1 << 3) */ +#define LNET_MD_MANAGE_REMOTE BIT(2) +/* unused BIT(3) */ /** See lnet_md::options. */ -#define LNET_MD_TRUNCATE (1 << 4) +#define LNET_MD_TRUNCATE BIT(4) /** See lnet_md::options. */ -#define LNET_MD_ACK_DISABLE (1 << 5) +#define LNET_MD_ACK_DISABLE BIT(5) /** See lnet_md::options. */ -#define LNET_MD_IOVEC (1 << 6) +#define LNET_MD_IOVEC BIT(6) /** See lnet_md::options. */ -#define LNET_MD_MAX_SIZE (1 << 7) +#define LNET_MD_MAX_SIZE BIT(7) /** See lnet_md::options. */ -#define LNET_MD_KIOV (1 << 8) +#define LNET_MD_KIOV BIT(8) /* For compatibility with Cray Portals */ #define LNET_MD_PHYS 0