linux-edac.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] RAS/CEC: Fix cec_init prototype
@ 2020-08-04 16:18 Luca Stefani
  2020-08-05  4:59 ` Borislav Petkov
  0 siblings, 1 reply; 9+ messages in thread
From: Luca Stefani @ 2020-08-04 16:18 UTC (permalink / raw)
  Cc: Luca Stefani, Tony Luck, Borislav Petkov, linux-edac, linux-kernel

* late_initcall expects a function to return an integer

Signed-off-by: Luca Stefani <luca.stefani.ge1@gmail.com>
---
 drivers/ras/cec.c | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/drivers/ras/cec.c b/drivers/ras/cec.c
index 569d9ad2c594..e048e0e3949a 100644
--- a/drivers/ras/cec.c
+++ b/drivers/ras/cec.c
@@ -553,20 +553,20 @@ static struct notifier_block cec_nb = {
 	.priority	= MCE_PRIO_CEC,
 };
 
-static void __init cec_init(void)
+static int __init cec_init(void)
 {
 	if (ce_arr.disabled)
-		return;
+		return 0;
 
 	ce_arr.array = (void *)get_zeroed_page(GFP_KERNEL);
 	if (!ce_arr.array) {
 		pr_err("Error allocating CE array page!\n");
-		return;
+		return 1;
 	}
 
 	if (create_debugfs_nodes()) {
 		free_page((unsigned long)ce_arr.array);
-		return;
+		return 1;
 	}
 
 	INIT_DELAYED_WORK(&cec_work, cec_work_fn);
@@ -575,6 +575,7 @@ static void __init cec_init(void)
 	mce_register_decode_chain(&cec_nb);
 
 	pr_info("Correctable Errors collector initialized.\n");
+	return 0;
 }
 late_initcall(cec_init);
 
-- 
2.28.0


^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2020-08-17 18:53 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-04 16:18 [PATCH] RAS/CEC: Fix cec_init prototype Luca Stefani
2020-08-05  4:59 ` Borislav Petkov
2020-08-05  9:57   ` [PATCH v2] " Luca Stefani
2020-08-12 21:09     ` Sami Tolvanen
2020-08-17 15:13       ` Borislav Petkov
2020-08-17 15:58         ` Sami Tolvanen
2020-08-17 17:41           ` Borislav Petkov
2020-08-17 18:11             ` Sami Tolvanen
2020-08-17 18:54               ` Borislav Petkov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).