lkml.org 
[lkml]   [2003]   [Sep]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Subject[PATCH] fix smc-mca cleanup breakage
From
Date
The latest set of smc-mca fixes broke the driver.  Apparently, it wasn't
realised that request_region() actually returns a pointer to the region
you're requesting if it can. Without this fix, the smc-mca cannot
attach to any device.

James
===== drivers/net/smc-mca.c 1.11 vs edited =====
--- 1.11/drivers/net/smc-mca.c Thu Sep 4 02:36:29 2003
+++ edited/drivers/net/smc-mca.c Thu Sep 25 15:26:14 2003
@@ -269,9 +269,10 @@
goto err_unregister_netdev;
}

- rc = request_region(ioaddr, ULTRA_IO_EXTENT, dev->name);
- if (rc)
+ if (!request_region(ioaddr, ULTRA_IO_EXTENT, dev->name)) {
+ rc = -ENODEV;
goto err_unregister_netdev;
+ }

reg4 = inb(ioaddr + 4) & 0x7f;
outb(reg4, ioaddr + 4);

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:48    [W:3.011 / U:1.068 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site