-stable review patch.  If anyone has any objections, please let us know.

----

From: Andres Salomon <[EMAIL PROTECTED]>

It seems to me that in the VIA Rhine device driver the requested irq might
not be freed in case the alloc_ring() function fails. alloc_ring()
can fail with a ENOMEM return value because of possible
pci_alloc_consistent() failures.
   
Updated to CodingStyle.

Signed-off-by: Jeff Garzik <[EMAIL PROTECTED]>
Signed-off-by: Chris Wright <[EMAIL PROTECTED]>
Signed-off-by: Greg Kroah-Hartman <[EMAIL PROTECTED]>

--- 1.89/drivers/net/via-rhine.c        2005-01-10 08:52:27 -08:00
+++ edited/drivers/net/via-rhine.c      2005-03-11 15:18:25 -08:00
@@ -1197,8 +1197,10 @@ static int rhine_open(struct net_device 
                       dev->name, rp->pdev->irq);
 
        rc = alloc_ring(dev);
-       if (rc)
+       if (rc) {
+               free_irq(rp->pdev->irq, dev);
                return rc;
+       }
        alloc_rbufs(dev);
        alloc_tbufs(dev);
        rhine_chip_reset(dev);
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to