Received: by 2002:a05:6a10:2726:0:0:0:0 with SMTP id ib38csp2233752pxb; Wed, 30 Mar 2022 20:10:41 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw/Q0V6cnOdpIJAIZyUTZMQpWNKAuvV+eBsp6zepU1jJx438286Bh6FY6iN/AEOMpkcbtfJ X-Received: by 2002:a63:2316:0:b0:381:ac6:94a5 with SMTP id j22-20020a632316000000b003810ac694a5mr8837823pgj.501.1648696241186; Wed, 30 Mar 2022 20:10:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1648696241; cv=none; d=google.com; s=arc-20160816; b=Qe6s3i90ZW7iGruY0rnvRjFCeSD888teH1VxLHtbIZNKAtbDDTpot4HRwInEJGPe3h ZEKrw+7/j4bjmGfcw0XwBfIHjqA9WyqtHIUjOqDWF/B8JyvVtkCB6mqXRASkjrsJdMcF uPr7TNkVBXXKu5QLQOu0uSxRK3xtWEJTTWXrigVgs2wo3QnF0mY24pYpFimW7DqCxxqm Aq/smtx4q9jjdhfqNBQuuTKtJGoh7lBY5OKwRq1Bmhu/yBji4oalnYKx4gWg/NYyC6hC PGvq1mO8YEvKgDX9MYmKkLAKmGh1U2MOocjrnqtlIlsZDRuRq5v5JQMq8MKHuT2htFeV nQGg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:organization:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=Z/lY7oP/7ORJAnXRhYFHKef3QEULofImgpbt0loIiq0=; b=QsGE6C56eP0RqAot/hXW3jx/6/Qvg1yNbQqmx15Gj4yXd50/e4bbOQBv7RcT78gMsV lPVaqYZtJBacpj1RzmlHanU+/lA/V6kVzjzk1dBhpg8ZDiA+pW8VOd1MOpNi6zEpdBLj EABKsBI8skC28ONrxkqsSPspe+o27KQi6smSfq9vCX0/2D+R3W04ioElYnj88PvRHZuS qrkzPKnvrZftpUf0Yg2sbp9HNGMZ2aN4KG1JDJUWCE44q8VPxBv7OAZ2nuA/sUxYZhQm YXgCKRNZtM10queBaoWevu2vpVRrIzIEs6j72rOPaTxljrdjgf+y0CLpydDOBdNfcQYt 8Y+Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=KoNoPzdZ; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id y18-20020a056a00181200b004fa3a8e0074si26763484pfa.299.2022.03.30.20.10.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 30 Mar 2022 20:10:41 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=KoNoPzdZ; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 4DC58939EC; Wed, 30 Mar 2022 19:46:50 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1348478AbiC3P5P (ORCPT + 99 others); Wed, 30 Mar 2022 11:57:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46488 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1348471AbiC3P5N (ORCPT ); Wed, 30 Mar 2022 11:57:13 -0400 Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E3341E032 for ; Wed, 30 Mar 2022 08:55:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1648655728; x=1680191728; h=date:from:to:cc:subject:message-id:references: mime-version:content-transfer-encoding:in-reply-to; bh=imgBikfhZr82zU3PBkryKfey7V06+8mpRuA1SfZVnbs=; b=KoNoPzdZP8OeR08rNH4Q95uSgvH3Xaa4xjLp3qVhFXQqV3Xm0p/07/0j EnO0hbhx5wlGqiwOdSrwZaq+pn0iVil0+X3KQ+YaXT8/I6IOiG4ISc+FA wElR5I6gDCaAELFsSXfm1Y6fVNUeAoATjNfrmOtQkGDvPd9IHjjq4GhKL b0apBGJ/+WhFznAyQlfok5ixqAWc3fA63QoLA9vrvpU4mkoIKojbbE2rG jMi8hmtGQG8YtC94SXhADRD+ff+1vTPTg4la+VRDQV7xrwkTaHfx8cUSh MW2JWQ7gq/6ygpbg//l29TuCD2u8e1Dgg06YE/lkjhsfq3t6mWaLkOGRn Q==; X-IronPort-AV: E=McAfee;i="6200,9189,10302"; a="247077479" X-IronPort-AV: E=Sophos;i="5.90,223,1643702400"; d="scan'208";a="247077479" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 30 Mar 2022 08:55:28 -0700 X-IronPort-AV: E=Sophos;i="5.90,223,1643702400"; d="scan'208";a="565603486" Received: from smile.fi.intel.com ([10.237.72.59]) by orsmga008-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 30 Mar 2022 08:55:26 -0700 Received: from andy by smile.fi.intel.com with local (Exim 4.95) (envelope-from ) id 1nZaeq-009UHk-By; Wed, 30 Mar 2022 18:54:52 +0300 Date: Wed, 30 Mar 2022 18:54:52 +0300 From: Andy Shevchenko To: Dave Hansen Cc: Neil Armstrong , tglx@linutronix.de, mingo@redhat.com, bp@alien8.de, dave.hansen@linux.intel.com, hpa@zytor.com, x86@kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] x86: undef REG_IN/REG_OUT to avoid define collisions Message-ID: References: <20220330152808.1461758-1-narmstrong@baylibre.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Mar 30, 2022 at 08:33:26AM -0700, Dave Hansen wrote: > On 3/30/22 08:28, Neil Armstrong wrote: > > These defines are only used in the inline functions declared > > in the arch_hweight.h file, and collides with internal defines > > of the Amlogic Mes pinctrl driver when COMPILE_TEST is enabled: > > > > arch/x86/include/asm/arch_hweight.h:9:17: error: expected identifier before string constant > > 9 | #define REG_OUT "a" > > | ^~~ > > drivers/pinctrl/meson/pinctrl-meson.h:69:9: note: in expansion of macro ‘REG_OUT’ > > 69 | REG_OUT, Thanks for the patch! > > Reported-by: Andy Shevchenko > > Signed-off-by: Neil Armstrong > > --- > > arch/x86/include/asm/arch_hweight.h | 3 +++ > > 1 file changed, 3 insertions(+) > > > > diff --git a/arch/x86/include/asm/arch_hweight.h b/arch/x86/include/asm/arch_hweight.h > > index ba88edd0d58b..139a4b0a2a14 100644 > > --- a/arch/x86/include/asm/arch_hweight.h > > +++ b/arch/x86/include/asm/arch_hweight.h > > @@ -52,4 +52,7 @@ static __always_inline unsigned long __arch_hweight64(__u64 w) > > } > > #endif /* CONFIG_X86_32 */ > > > > +#undef REG_IN > > +#undef REG_OUT > > Wouldn't it be a bit less hackish to give these a more qualified name > like HWEIGHT_REG_IN? Either way, would it be good to undef them here anyway? -- With Best Regards, Andy Shevchenko