All of lore.kernel.org
 help / color / mirror / Atom feed
* [KJ] [PATCH] misc_register : arch/x86_64/kernel/mce.c
@ 2006-10-02 12:00 Christophe Lucas
  0 siblings, 0 replies; only message in thread
From: Christophe Lucas @ 2006-10-02 12:00 UTC (permalink / raw)
  To: kernel-janitors

Description :
Audit return codes (and handle failure correctly) for misc_register.


Signed-off-by: Christophe Lucas <clucas@rotomalug.org>

Index: linux-2.6.18/arch/x86_64/kernel/mce.c
=================================--- linux-2.6.18.orig/arch/x86_64/kernel/mce.c	2006-10-02 13:57:17.000000000 +0200
+++ linux-2.6.18/arch/x86_64/kernel/mce.c	2006-10-02 13:57:58.000000000 +0200
@@ -663,7 +663,9 @@
 	}
 
 	register_hotcpu_notifier(&mce_cpu_notifier);
-	misc_register(&mce_log_device);
+	err = misc_register(&mce_log_device);
+	if (err < 0)
+		printk(KERN_ERR, "Failed to register mce.\n");
 	return err;
 }
 
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2006-10-02 12:00 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-10-02 12:00 [KJ] [PATCH] misc_register : arch/x86_64/kernel/mce.c Christophe Lucas

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.