patch-2.4.23 linux-2.4.23/drivers/char/amd76x_pm.c
Next file: linux-2.4.23/drivers/char/amd7xx_tco.c
Previous file: linux-2.4.23/drivers/char/agp/agpgart_fe.c
Back to the patch index
Back to the overall index
- Lines: 32
- Date:
2003-11-28 10:26:20.000000000 -0800
- Orig file:
linux-2.4.22/drivers/char/amd76x_pm.c
- Orig date:
2003-08-25 04:44:41.000000000 -0700
diff -urN linux-2.4.22/drivers/char/amd76x_pm.c linux-2.4.23/drivers/char/amd76x_pm.c
@@ -577,16 +577,18 @@
int found;
/* Find northbridge */
- found = pci_module_init(&amd_nb_driver);
- if (found < 0) {
+ found = pci_register_driver(&amd_nb_driver);
+ if (found <= 0) {
printk(KERN_ERR "amd76x_pm: Could not find northbridge\n");
+ pci_unregister_driver(&amd_nb_driver);
return 1;
}
/* Find southbridge */
- found = pci_module_init(&amd_sb_driver);
- if (found < 0) {
+ found = pci_register_driver(&amd_sb_driver);
+ if (found <= 0) {
printk(KERN_ERR "amd76x_pm: Could not find southbridge\n");
+ pci_unregister_driver(&amd_sb_driver);
pci_unregister_driver(&amd_nb_driver);
return 1;
}
@@ -620,6 +622,8 @@
#ifndef AMD76X_NTH
if (!amd76x_pm_cfg.curr_idle) {
printk(KERN_ERR "amd76x_pm: Idle function not changed\n");
+ pci_unregister_driver(&amd_nb_driver);
+ pci_unregister_driver(&amd_sb_driver);
return 1;
}
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)