From patchwork Wed Aug 16 05:06:40 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yi Sun X-Patchwork-Id: 9903027 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 6B3B060244 for ; Wed, 16 Aug 2017 05:25:38 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 607E7288C3 for ; Wed, 16 Aug 2017 05:25:38 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 552D528965; Wed, 16 Aug 2017 05:25:38 +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=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id E5C5E288C3 for ; Wed, 16 Aug 2017 05:25:37 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dhqnX-0003Uq-8H; Wed, 16 Aug 2017 05:23:19 +0000 Received: from mail6.bemta6.messagelabs.com ([193.109.254.103]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dhqnW-0003Uk-Ot for xen-devel@lists.xenproject.org; Wed, 16 Aug 2017 05:23:18 +0000 Received: from [193.109.254.147] by server-10.bemta-6.messagelabs.com id 3D/69-18185-6C6D3995; Wed, 16 Aug 2017 05:23:18 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFnrJLMWRWlGSWpSXmKPExsXS1tYhonv02uR Ig+NLNCy+b5nM5MDocfjDFZYAxijWzLyk/IoE1oz2jyuZCs6xVlyYztHAuJGli5GLQ0hgGqPE 7kVtTF2MnBwSArwSR5bNYIWw/SVabk9jgihqYJT4NXciG0iCTUBd4vHXHrAGEQEliXurJoMVM Qt0Mkoce3UQrEhYwEBi1ba7zCA2i4CqxLTJH9lBbF4BD4mub+9ZIDbISZw8Npl1AiP3AkaGVY waxalFZalFuobmeklFmekZJbmJmTm6hgZmermpxcWJ6ak5iUnFesn5uZsYgR5mAIIdjLc3Bhx ilORgUhLlXXR2UqQQX1J+SmVGYnFGfFFpTmrxIUYZDg4lCV79q5MjhQSLUtNTK9Iyc4ChBpOW 4OBREuFVAEnzFhck5hZnpkOkTjEaczR92PKFiePVhP/fmIRY8vLzUqXEeX1BSgVASjNK8+AGw WLgEqOslDAvI9BpQjwFqUW5mSWo8q8YxTkYlYR5b4JM4cnMK4Hb9wroFCagU660TwI5pSQRIS XVwNimF/e+yXFJ82on16aXaSmNn6TfThOcbHmk5XJktaTwm7u69iffHZt1QbXa0WwLZ5f/BR6 nb5MY3CL2yGYFTrWprpP5sygku6RuDmeRt9P/n0rn+7l62nYsrfTL61k2VWRJjnrMoofNex48 /XS9TGSh/bpUtpD8m5nShQymM/YyiO66lWt8SYmlOCPRUIu5qDgRAFQOZ5p8AgAA X-Env-Sender: yi.y.sun@linux.intel.com X-Msg-Ref: server-12.tower-27.messagelabs.com!1502860995!110524250!1 X-Originating-IP: [134.134.136.20] X-SpamReason: No, hits=0.0 required=7.0 tests=sa_preprocessor: VHJ1c3RlZCBJUDogMTM0LjEzNC4xMzYuMjAgPT4gMzU1MzU4\n X-StarScan-Received: X-StarScan-Version: 9.4.45; banners=-,-,- X-VirusChecked: Checked Received: (qmail 51674 invoked from network); 16 Aug 2017 05:23:17 -0000 Received: from mga02.intel.com (HELO mga02.intel.com) (134.134.136.20) by server-12.tower-27.messagelabs.com with DHE-RSA-AES256-GCM-SHA384 encrypted SMTP; 16 Aug 2017 05:23:17 -0000 Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga101.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 15 Aug 2017 22:23:14 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.41,381,1498546800"; d="scan'208";a="124079082" Received: from vmmmba-s2600wft.bj.intel.com ([10.240.193.80]) by orsmga002.jf.intel.com with ESMTP; 15 Aug 2017 22:23:13 -0700 From: Yi Sun To: xen-devel@lists.xenproject.org Date: Wed, 16 Aug 2017 13:06:40 +0800 Message-Id: <1502860000-14137-1-git-send-email-yi.y.sun@linux.intel.com> X-Mailer: git-send-email 1.9.1 Cc: andrew.cooper3@citrix.com, Yi Sun , wei.liu2@citrix.com, jbeulich@suse.com, chao.p.peng@linux.intel.com Subject: [Xen-devel] [PATCH] x86/psr: fix coding style issue X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" X-Virus-Scanned: ClamAV using ClamSMTP In psr.c, we defined some macros but the coding style is not good. Use '(1u << X)' to replace '(1< --- xen/arch/x86/psr.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/xen/arch/x86/psr.c b/xen/arch/x86/psr.c index 9ce8f17..3622de0 100644 --- a/xen/arch/x86/psr.c +++ b/xen/arch/x86/psr.c @@ -31,9 +31,9 @@ * - PSR Intel Platform Shared Resource */ -#define PSR_CMT (1<<0) -#define PSR_CAT (1<<1) -#define PSR_CDP (1<<2) +#define PSR_CMT (1u << 0) +#define PSR_CAT (1u << 1) +#define PSR_CDP (1u << 2) #define CAT_CBM_LEN_MASK 0x1f #define CAT_COS_MAX_MASK 0xffff