From: Zhengqiang <zhengqiang10@huawei.com> To: Borislav Petkov <bp@alien8.de>, James Morse <james.morse@arm.com> Cc: Tyler Baicar <tbaicar@qti.qualcomm.com>, mchehab@kernel.org, toshi.kani@hpe.com, linux-edac@vger.kernel.org, linuxarm@huawei.com, "linux-arm-kernel@lists.infradead.org" <linux-arm-kernel@lists.infradead.org> Subject: EDAC, ghes: Make platform-based whitelisting x86-only Date: Mon, 21 May 2018 17:39:01 +0800 [thread overview] Message-ID: <5B0293B5.5060406@huawei.com> (raw) Thanks, it works for me. On 2018/5/18 19:20, Borislav Petkov wrote: > From: Borislav Petkov <bp@suse.de> > > ARM machines all have DMI tables so if they request hw error reporting > through GHES, then the driver should be able to detect DIMMs and report > errors successfully (famous last words :)). > > Make the platform-based list x86-specific so that ghes_edac can load on > ARM. > > Signed-off-by: Borislav Petkov <bp@suse.de> > Reviewed-by: James Morse <james.morse@arm.com> > Tested-by: James Morse <james.morse@arm.com> > Cc: Qiang Zheng <zhengqiang10@huawei.com> > Link: https://lkml.kernel.org/r/1526039543-180996-1-git-send-email-zhengqiang10@huawei.com Tested-by: Qiang Zheng <zhengqiang10@huawei.com> > --- > drivers/edac/ghes_edac.c | 14 +++++++++----- > 1 file changed, 9 insertions(+), 5 deletions(-) > > diff --git a/drivers/edac/ghes_edac.c b/drivers/edac/ghes_edac.c > index 863fbf3db29f..473aeec4b1da 100644 > --- a/drivers/edac/ghes_edac.c > +++ b/drivers/edac/ghes_edac.c > @@ -440,12 +440,16 @@ int ghes_edac_register(struct ghes *ghes, struct device *dev) > struct mem_ctl_info *mci; > struct edac_mc_layer layers[1]; > struct ghes_edac_dimm_fill dimm_fill; > - int idx; > + int idx = -1; > > - /* Check if safe to enable on this system */ > - idx = acpi_match_platform_list(plat_list); > - if (!force_load && idx < 0) > - return -ENODEV; > + if (IS_ENABLED(CONFIG_X86)) { > + /* Check if safe to enable on this system */ > + idx = acpi_match_platform_list(plat_list); > + if (!force_load && idx < 0) > + return -ENODEV; > + } else { > + idx = 0; > + } > > /* > * We have only one logical memory controller to which all DIMMs belong. > --- To unsubscribe from this list: send the line "unsubscribe linux-edac" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
WARNING: multiple messages have this Message-ID (diff)
From: zhengqiang10@huawei.com (Zhengqiang) To: linux-arm-kernel@lists.infradead.org Subject: [PATCH] EDAC, ghes: Make platform-based whitelisting x86-only Date: Mon, 21 May 2018 17:39:01 +0800 [thread overview] Message-ID: <5B0293B5.5060406@huawei.com> (raw) In-Reply-To: <20180518112028.GD17285@pd.tnic> Thanks, it works for me. On 2018/5/18 19:20, Borislav Petkov wrote: > From: Borislav Petkov <bp@suse.de> > > ARM machines all have DMI tables so if they request hw error reporting > through GHES, then the driver should be able to detect DIMMs and report > errors successfully (famous last words :)). > > Make the platform-based list x86-specific so that ghes_edac can load on > ARM. > > Signed-off-by: Borislav Petkov <bp@suse.de> > Reviewed-by: James Morse <james.morse@arm.com> > Tested-by: James Morse <james.morse@arm.com> > Cc: Qiang Zheng <zhengqiang10@huawei.com> > Link: https://lkml.kernel.org/r/1526039543-180996-1-git-send-email-zhengqiang10 at huawei.com Tested-by: Qiang Zheng <zhengqiang10@huawei.com> > --- > drivers/edac/ghes_edac.c | 14 +++++++++----- > 1 file changed, 9 insertions(+), 5 deletions(-) > > diff --git a/drivers/edac/ghes_edac.c b/drivers/edac/ghes_edac.c > index 863fbf3db29f..473aeec4b1da 100644 > --- a/drivers/edac/ghes_edac.c > +++ b/drivers/edac/ghes_edac.c > @@ -440,12 +440,16 @@ int ghes_edac_register(struct ghes *ghes, struct device *dev) > struct mem_ctl_info *mci; > struct edac_mc_layer layers[1]; > struct ghes_edac_dimm_fill dimm_fill; > - int idx; > + int idx = -1; > > - /* Check if safe to enable on this system */ > - idx = acpi_match_platform_list(plat_list); > - if (!force_load && idx < 0) > - return -ENODEV; > + if (IS_ENABLED(CONFIG_X86)) { > + /* Check if safe to enable on this system */ > + idx = acpi_match_platform_list(plat_list); > + if (!force_load && idx < 0) > + return -ENODEV; > + } else { > + idx = 0; > + } > > /* > * We have only one logical memory controller to which all DIMMs belong. >
next reply other threads:[~2018-05-21 9:39 UTC|newest] Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top 2018-05-21 9:39 Zhengqiang [this message] 2018-05-21 9:39 ` [PATCH] EDAC, ghes: Make platform-based whitelisting x86-only Zhengqiang -- strict thread matches above, loose matches on Subject: below -- 2018-05-22 2:10 Tyler Baicar 2018-05-22 2:10 ` [PATCH] " Tyler Baicar 2018-05-21 20:44 Borislav Petkov 2018-05-21 20:44 ` [PATCH] " Borislav Petkov 2018-05-21 20:34 Tyler Baicar 2018-05-21 20:34 ` [PATCH] " Tyler Baicar 2018-05-21 17:15 Borislav Petkov 2018-05-21 17:15 ` [PATCH] " Borislav Petkov 2018-05-21 13:48 Tyler Baicar 2018-05-21 13:48 ` [PATCH] " Tyler Baicar 2018-05-18 11:20 Borislav Petkov 2018-05-18 11:20 ` [PATCH] " Borislav Petkov 2018-05-18 11:11 ghes_edac: enable HIP08 platform edac driver Borislav Petkov 2018-05-18 11:11 ` [PATCH] " Borislav Petkov 2018-05-18 7:13 Zhengqiang 2018-05-18 7:13 ` [PATCH] " Zhengqiang 2018-05-17 18:02 James Morse 2018-05-17 18:02 ` [PATCH] " James Morse 2018-05-16 18:29 Borislav Petkov 2018-05-16 18:29 ` [PATCH] " Borislav Petkov 2018-05-16 13:38 James Morse 2018-05-16 13:38 ` [PATCH] " James Morse 2018-05-14 16:47 Borislav Petkov 2018-05-14 16:47 ` [PATCH] " Borislav Petkov 2018-05-14 15:12 James Morse 2018-05-14 15:12 ` [PATCH] " James Morse 2018-05-14 9:47 Borislav Petkov 2018-05-14 4:11 Zhengqiang 2018-05-11 12:19 Borislav Petkov 2018-05-11 11:52 Zhengqiang
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=5B0293B5.5060406@huawei.com \ --to=zhengqiang10@huawei.com \ --cc=bp@alien8.de \ --cc=james.morse@arm.com \ --cc=linux-arm-kernel@lists.infradead.org \ --cc=linux-edac@vger.kernel.org \ --cc=linuxarm@huawei.com \ --cc=mchehab@kernel.org \ --cc=tbaicar@qti.qualcomm.com \ --cc=toshi.kani@hpe.com \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.