Received: by 2002:ac0:bc90:0:0:0:0:0 with SMTP id a16csp2240205img; Sun, 24 Mar 2019 03:31:23 -0700 (PDT) X-Google-Smtp-Source: APXvYqzg385bIgnALXIDMq7h2pEGE/3uGB5sb6/B9819ejeyrqWFDb9/7/bXERZ4M7QReCoPqspr X-Received: by 2002:a17:902:9a98:: with SMTP id w24mr19025582plp.247.1553423483098; Sun, 24 Mar 2019 03:31:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1553423483; cv=none; d=google.com; s=arc-20160816; b=c8+fp8FZigS9hH2BfEXTV0JKSZYkg0XQSkj9SBgWEj3xe602Rv/BAVRWWjtrqCOohe KnfM8/Yx8X/5l3yNmMRS8YNHXkJr7QWuu4LjzzJTC2QRWakssfadxsUiNYRrTbD+h91Y fVivr8VOirvV1hwix0zyZWbNknHSkg2A4oe20B/6pSnULkwXDdWCv7EPnyZ3TWP9Sk5P 1pRBtbtXbRpwSo+EwKPoVruIvfSq8CfknwIRAauu1sAeQ1lFY8LqBDVIjfNKSN5ffo34 kwvGc+EMxymeLytSrbwLA0eyOlwAeaulVI7WWfezI5O/0t/IKmIK5vehUMbExQ+BJflt Vgww== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-disposition :content-transfer-encoding:mime-version:robot-unsubscribe:robot-id :git-commit-id:subject:to:references:in-reply-to:reply-to:cc :message-id:from:date; bh=vWBl/ixtgZWfIPVL4Um8jnMk5qUHAfEyy9LeRrXpHeY=; b=AkwfgwgdsTxoMou20EIUY0orTqvw4JpWO20LdRQ4bYQz+axaSP850c8JTq5wFg/3X5 WvvNN9K7bsFgIDoLcrtxnc1En1PkmloI2AYjBTz6Eiq/hfEBm6PvyYu5yAZt1BwxSRbL XeUfAlCzC2rtxKzt209YgSdWLPLXP52NQ0Am6us17r0+OVLBIAHI8TqhBPhtEsyS7GVR mbBwAAlKJAmEQI72RyPKsBOA/XGBXktRpuFRp0HnK5NKiJh101UHhe81w0UJumVyh0P/ KQodzLQ1x/yEiIkaQuQCoo/9JGA79kITx8trg82T5/g8a6X42WgcoDJud4s969jTa8Qg imgA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n185si124688pgn.400.2019.03.24.03.31.07; Sun, 24 Mar 2019 03:31:23 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728709AbfCXK3m (ORCPT + 99 others); Sun, 24 Mar 2019 06:29:42 -0400 Received: from terminus.zytor.com ([198.137.202.136]:46005 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726970AbfCXK3l (ORCPT ); Sun, 24 Mar 2019 06:29:41 -0400 Received: from terminus.zytor.com (localhost [127.0.0.1]) by terminus.zytor.com (8.15.2/8.15.2) with ESMTPS id x2OASR9t1420097 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NO); Sun, 24 Mar 2019 03:28:27 -0700 Received: (from tipbot@localhost) by terminus.zytor.com (8.15.2/8.15.2/Submit) id x2OASJxG1420085; Sun, 24 Mar 2019 03:28:19 -0700 Date: Sun, 24 Mar 2019 03:28:19 -0700 X-Authentication-Warning: terminus.zytor.com: tipbot set sender to tipbot@zytor.com using -f From: tip-bot for Yazen Ghannam Message-ID: Cc: yazen.ghannam@amd.com, vishal.l.verma@intel.com, mingo@kernel.org, tglx@linutronix.de, linux-kernel@vger.kernel.org, qiuxu.zhuo@intel.com, hpa@zytor.com, puwen@hygon.cn, arnd@arndb.de, bp@suse.de, mingo@redhat.com, rafal@milecki.pl, x86@kernel.org, clemej@gmail.com, tony.luck@intel.com Reply-To: mingo@kernel.org, tglx@linutronix.de, vishal.l.verma@intel.com, yazen.ghannam@amd.com, hpa@zytor.com, linux-kernel@vger.kernel.org, qiuxu.zhuo@intel.com, mingo@redhat.com, bp@suse.de, rafal@milecki.pl, puwen@hygon.cn, arnd@arndb.de, x86@kernel.org, tony.luck@intel.com, clemej@gmail.com In-Reply-To: <20190322202848.20749-3-Yazen.Ghannam@amd.com> References: <20190322202848.20749-3-Yazen.Ghannam@amd.com> To: linux-tip-commits@vger.kernel.org Subject: [tip:ras/core] x86/MCE: Group AMD function prototypes in Git-Commit-ID: 9308fd4074551f222f30322d1ee8c5aff18e9747 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline X-Spam-Status: No, score=-0.8 required=5.0 tests=ALL_TRUSTED,BAYES_00, FREEMAIL_FORGED_REPLYTO,T_DATE_IN_FUTURE_96_Q autolearn=no autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on terminus.zytor.com Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: 9308fd4074551f222f30322d1ee8c5aff18e9747 Gitweb: https://git.kernel.org/tip/9308fd4074551f222f30322d1ee8c5aff18e9747 Author: Yazen Ghannam AuthorDate: Fri, 22 Mar 2019 20:29:00 +0000 Committer: Borislav Petkov CommitDate: Sun, 24 Mar 2019 10:54:13 +0100 x86/MCE: Group AMD function prototypes in There are two groups of "ifdef CONFIG_X86_MCE_AMD" function prototypes in . Merge these two groups. No functional change. [ bp: align vertically. ] Signed-off-by: Yazen Ghannam Signed-off-by: Borislav Petkov Cc: Arnd Bergmann Cc: "clemej@gmail.com" Cc: "H. Peter Anvin" Cc: Ingo Molnar Cc: Pu Wen Cc: Qiuxu Zhuo Cc: "rafal@milecki.pl" Cc: Thomas Gleixner Cc: Tony Luck Cc: Vishal Verma Cc: x86-ml Link: https://lkml.kernel.org/r/20190322202848.20749-3-Yazen.Ghannam@amd.com --- arch/x86/include/asm/mce.h | 25 +++++++++++-------------- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/arch/x86/include/asm/mce.h b/arch/x86/include/asm/mce.h index 22d05e3835f0..dc2d4b206ab7 100644 --- a/arch/x86/include/asm/mce.h +++ b/arch/x86/include/asm/mce.h @@ -210,16 +210,6 @@ static inline void cmci_rediscover(void) {} static inline void cmci_recheck(void) {} #endif -#ifdef CONFIG_X86_MCE_AMD -void mce_amd_feature_init(struct cpuinfo_x86 *c); -int umc_normaddr_to_sysaddr(u64 norm_addr, u16 nid, u8 umc, u64 *sys_addr); -#else -static inline void mce_amd_feature_init(struct cpuinfo_x86 *c) { } -static inline int umc_normaddr_to_sysaddr(u64 norm_addr, u16 nid, u8 umc, u64 *sys_addr) { return -EINVAL; }; -#endif - -static inline void mce_hygon_feature_init(struct cpuinfo_x86 *c) { return mce_amd_feature_init(c); } - int mce_available(struct cpuinfo_x86 *c); bool mce_is_memory_error(struct mce *m); bool mce_is_correctable(struct mce *m); @@ -345,12 +335,19 @@ extern bool amd_mce_is_memory_error(struct mce *m); extern int mce_threshold_create_device(unsigned int cpu); extern int mce_threshold_remove_device(unsigned int cpu); -#else +void mce_amd_feature_init(struct cpuinfo_x86 *c); +int umc_normaddr_to_sysaddr(u64 norm_addr, u16 nid, u8 umc, u64 *sys_addr); -static inline int mce_threshold_create_device(unsigned int cpu) { return 0; }; -static inline int mce_threshold_remove_device(unsigned int cpu) { return 0; }; -static inline bool amd_mce_is_memory_error(struct mce *m) { return false; }; +#else +static inline int mce_threshold_create_device(unsigned int cpu) { return 0; }; +static inline int mce_threshold_remove_device(unsigned int cpu) { return 0; }; +static inline bool amd_mce_is_memory_error(struct mce *m) { return false; }; +static inline void mce_amd_feature_init(struct cpuinfo_x86 *c) { } +static inline int +umc_normaddr_to_sysaddr(u64 norm_addr, u16 nid, u8 umc, u64 *sys_addr) { return -EINVAL; }; #endif +static inline void mce_hygon_feature_init(struct cpuinfo_x86 *c) { return mce_amd_feature_init(c); } + #endif /* _ASM_X86_MCE_H */