static int __init alsa_card_mychip_init(void)
{
- int err;
-
- if ((err = pci_module_init(&driver)) < 0) {
- #ifdef MODULE
- printk(KERN_ERR "My chip soundcard not found "
- "or device busy\n");
- #endif
- return err;
- }
- return 0;
+ return pci_module_init(&driver);
}the added message does not really give any additional information. The patch also improves the consistency with the majority of the drivers in the kernel that just use return pci_module_init(&driver); with out giving any message.
-Jeff
diff -ur alsa-kernel/Documentation/DocBook/writing-an-alsa-driver.tmpl alsa-kernel-mod-init/Documentation/DocBook/writing-an-alsa-driver.tmpl
--- alsa-kernel/Documentation/DocBook/writing-an-alsa-driver.tmpl 2004-03-20 19:33:32.000000000 -0500
+++ alsa-kernel-mod-init/Documentation/DocBook/writing-an-alsa-driver.tmpl 2004-03-20 19:57:12.000000000 -0500
@@ -1355,16 +1355,7 @@
// initialization of the module
static int __init alsa_card_mychip_init(void)
{
- int err;
-
- if ((err = pci_module_init(&driver)) < 0) {
- #ifdef MODULE
- printk(KERN_ERR "My chip soundcard not found "
- "or device busy\n");
- #endif
- return err;
- }
- return 0;
+ return pci_module_init(&driver);
}
// clean up the module
@@ -1781,16 +1772,7 @@
<