From patchwork Tue May 15 09:57:01 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Miquel Raynal X-Patchwork-Id: 913533 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=bootlin.com Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 40lY6S6QlSz9s28 for ; Tue, 15 May 2018 20:03:12 +1000 (AEST) Received: by lists.denx.de (Postfix, from userid 105) id 6DD69C21DFF; Tue, 15 May 2018 10:02:26 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=RCVD_IN_DNSWL_NONE autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id 23137C21F04; Tue, 15 May 2018 09:57:42 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 24109C21D8E; Tue, 15 May 2018 09:57:34 +0000 (UTC) Received: from mail.bootlin.com (mail.bootlin.com [62.4.15.54]) by lists.denx.de (Postfix) with ESMTP id 09E00C21C93 for ; Tue, 15 May 2018 09:57:34 +0000 (UTC) Received: by mail.bootlin.com (Postfix, from userid 110) id D2F5120794; Tue, 15 May 2018 11:57:32 +0200 (CEST) Received: from localhost.localdomain (LStLambert-657-1-97-87.w90-63.abo.wanadoo.fr [90.63.216.87]) by mail.bootlin.com (Postfix) with ESMTPSA id 9998B208BA; Tue, 15 May 2018 11:57:32 +0200 (CEST) From: Miquel Raynal To: Tom Rini , Simon Glass Date: Tue, 15 May 2018 11:57:01 +0200 Message-Id: <20180515095728.16572-6-miquel.raynal@bootlin.com> X-Mailer: git-send-email 2.14.1 In-Reply-To: <20180515095728.16572-1-miquel.raynal@bootlin.com> References: <20180515095728.16572-1-miquel.raynal@bootlin.com> Cc: u-boot@lists.denx.de, Bastian Fraune Subject: [U-Boot] [PATCH v4 05/32] tpm: use the BIT() macro where applicable X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" Fix following checkpatch.pl issue in TPM-related code: CHECK: Prefer using the BIT macro Signed-off-by: Miquel Raynal Reviewed-by: Tom Rini Reviewed-by: Simon Glass --- include/tpm.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/include/tpm.h b/include/tpm.h index 62117f6cc2..241597d879 100644 --- a/include/tpm.h +++ b/include/tpm.h @@ -83,13 +83,13 @@ enum tpm_capability_areas { TPM_CAP_VERSION_VAL = 0x0000001A, }; -#define TPM_NV_PER_GLOBALLOCK (1U << 15) -#define TPM_NV_PER_PPREAD (1U << 16) -#define TPM_NV_PER_PPWRITE (1U << 0) -#define TPM_NV_PER_READ_STCLEAR (1U << 31) -#define TPM_NV_PER_WRITE_STCLEAR (1U << 14) -#define TPM_NV_PER_WRITEDEFINE (1U << 13) -#define TPM_NV_PER_WRITEALL (1U << 12) +#define TPM_NV_PER_GLOBALLOCK BIT(15) +#define TPM_NV_PER_PPREAD BIT(16) +#define TPM_NV_PER_PPWRITE BIT(0) +#define TPM_NV_PER_READ_STCLEAR BIT(31) +#define TPM_NV_PER_WRITE_STCLEAR BIT(14) +#define TPM_NV_PER_WRITEDEFINE BIT(13) +#define TPM_NV_PER_WRITEALL BIT(12) enum { TPM_PUBEK_SIZE = 256,