mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH -mm] pcmcia/ds: must_check fixes
@ 2006-07-12  3:51 Randy.Dunlap
  0 siblings, 0 replies; only message in thread
From: Randy.Dunlap @ 2006-07-12  3:51 UTC (permalink / raw)
  To: lkml, linux-pcmcia; +Cc: linux, akpm

From: Randy Dunlap <rdunlap@xenotime.net>

Check all __must_check warnings in pcmcia/ds.c

Signed-off-by: Randy Dunlap <rdunlap@xenotime.net>
---
 drivers/pcmcia/ds.c |   16 ++++++++++++++--
 1 files changed, 14 insertions(+), 2 deletions(-)

--- linux-2618-rc1mm1.orig/drivers/pcmcia/ds.c
+++ linux-2618-rc1mm1/drivers/pcmcia/ds.c
@@ -1367,10 +1367,22 @@ struct bus_type pcmcia_bus_type = {
 
 static int __init init_pcmcia_bus(void)
 {
+	int ret;
+
 	spin_lock_init(&pcmcia_dev_list_lock);
 
-	bus_register(&pcmcia_bus_type);
-	class_interface_register(&pcmcia_bus_interface);
+	ret = bus_register(&pcmcia_bus_type);
+	if (ret < 0) {
+		printk(KERN_WARNING "pcmcia: bus_register error: %d\n", ret);
+		return ret;
+	}
+	ret = class_interface_register(&pcmcia_bus_interface);
+	if (ret < 0) {
+		printk(KERN_WARNING
+			"pcmcia: class_interface_register error: %d\n", ret);
+		bus_unregister(&pcmcia_bus_type);
+		return ret;
+	}
 
 	pcmcia_setup_ioctl();
 


---

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

only message in thread, other threads:[~2006-07-12  3:52 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-07-12  3:51 [PATCH -mm] pcmcia/ds: must_check fixes Randy.Dunlap

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®