lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:	Sat, 15 Dec 2007 20:58:51 +0900
From:	Akinobu Mita <akinobu.mita@...il.com>
To:	netdev@...r.kernel.org
Cc:	Stephen Hemminger <shemminger@...ux-foundation.org>
Subject: [PATCH] sky2: check pci_register_driver() error

Check pci_register_driver() error and clean up debugfs entries
if error happened.

Cc: Stephen Hemminger <shemminger@...ux-foundation.org>
Signed-off-by: Akinobu Mita <akinobu.mita@...il.com>

---
 drivers/net/sky2.c |    9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

Index: 2.6-git/drivers/net/sky2.c
===================================================================
--- 2.6-git.orig/drivers/net/sky2.c
+++ 2.6-git/drivers/net/sky2.c
@@ -4426,8 +4426,15 @@ static struct pci_driver sky2_driver = {
 
 static int __init sky2_init_module(void)
 {
+	int err;
+
 	sky2_debug_init();
-	return pci_register_driver(&sky2_driver);
+	err = pci_register_driver(&sky2_driver);
+	if (err) {
+		sky2_debug_cleanup();
+		return err;
+	}
+	return 0;
 }
 
 static void __exit sky2_cleanup_module(void)
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ