From: Stephen Rothwell Date: Thu, 4 Jan 2007 06:04:21 +0000 (+1100) Subject: [POWERPC] iSeries: fix lpevents initialisation X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=13d2c9bbb09e37e8a231a36b279a97861d6d5407;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git [POWERPC] iSeries: fix lpevents initialisation /proc/iSeries/lpevents should only be created if we are running on legacy iSeries. Signed-off-by: Stephen Rothwell Signed-off-by: Paul Mackerras --- diff --git a/arch/powerpc/platforms/iseries/lpevents.c b/arch/powerpc/platforms/iseries/lpevents.c index e3e929e1b460..c1f4502a3c6a 100644 --- a/arch/powerpc/platforms/iseries/lpevents.c +++ b/arch/powerpc/platforms/iseries/lpevents.c @@ -17,6 +17,7 @@ #include #include +#include #include #include #include @@ -318,6 +319,9 @@ static int __init proc_lpevents_init(void) { struct proc_dir_entry *e; + if (!firmware_has_feature(FW_FEATURE_ISERIES)) + return 0; + e = create_proc_entry("iSeries/lpevents", S_IFREG|S_IRUGO, NULL); if (e) e->proc_fops = &proc_lpevents_operations;