[PATCH] kill dead DEV_STALE_* codepathes in non-networking drivers

Christoph Hellwig hch at lst.de
Mon Aug 25 16:26:14 BST 2003


I guess there was some overzealous copy & pasting going on..


--- 1.24/drivers/char/pcmcia/synclink_cs.c	Tue Jul 15 19:01:29 2003
+++ edited/drivers/char/pcmcia/synclink_cs.c	Mon Aug 25 12:47:04 2003
@@ -725,14 +725,6 @@
     if (debug_level >= DEBUG_LEVEL_INFO)
 	    printk("mgslpc_release(0x%p)\n", link);
 
-    if (link->open) {
-	    if (debug_level >= DEBUG_LEVEL_INFO)
-		    printk("synclink_cs: release postponed, '%s' still open\n",
-			   link->dev->dev_name);
-	    link->state |= DEV_STALE_CONFIG;
-	    return;
-    }
-
     /* Unlink the device chain */
     link->dev = NULL;
     link->state &= ~DEV_CONFIG;
===== drivers/isdn/hardware/avm/avm_cs.c 1.10 vs edited =====
--- 1.10/drivers/isdn/hardware/avm/avm_cs.c	Sat Aug 16 22:22:50 2003
+++ edited/drivers/isdn/hardware/avm/avm_cs.c	Mon Aug 25 12:47:04 2003
@@ -431,15 +431,6 @@
 
 static void avmcs_release(dev_link_t *link)
 {
-    /*
-       If the device is currently in use, we won't release until it
-       is actually closed.
-    */
-    if (link->open) {
-	link->state |= DEV_STALE_CONFIG;
-	return;
-    }
-
     b1pcmcia_delcard(link->io.BasePort1, link->irq.AssignedIRQ);
 
     /* Unlink the device chain */
===== drivers/isdn/hisax/avma1_cs.c 1.7 vs edited =====
--- 1.7/drivers/isdn/hisax/avma1_cs.c	Sat Aug 16 22:22:51 2003
+++ edited/drivers/isdn/hisax/avma1_cs.c	Mon Aug 25 12:47:04 2003
@@ -438,17 +438,6 @@
 
     DEBUG(0, "avma1cs_release(0x%p)\n", link);
 
-    /*
-       If the device is currently in use, we won't release until it
-       is actually closed.
-    */
-    if (link->open) {
-	DEBUG(1, "avma1_cs: release postponed, '%s' still open\n",
-	      link->dev->dev_name);
-	link->state |= DEV_STALE_CONFIG;
-	return;
-    }
-
     /* no unregister function with hisax */
     HiSax_closecard(local->node.minor);
 
@@ -463,7 +452,6 @@
     
     if (link->state & DEV_STALE_LINK)
 	avma1cs_detach(link);
-    
 } /* avma1cs_release */
 
 /*======================================================================
===== drivers/isdn/hisax/elsa_cs.c 1.8 vs edited =====
--- 1.8/drivers/isdn/hisax/elsa_cs.c	Sat Aug 16 22:22:51 2003
+++ edited/drivers/isdn/hisax/elsa_cs.c	Mon Aug 25 12:47:04 2003
@@ -442,18 +442,6 @@
 
     DEBUG(0, "elsa_cs_release(0x%p)\n", link);
 
-    /*
-       If the device is currently in use, we won't release until it
-       is actually closed, because until then, we can't be sure that
-       no one will try to access the device or its data structures.
-    */
-    if (link->open) {
-        DEBUG(1, "elsa_cs: release postponed, '%s' "
-                   "still open\n", link->dev->dev_name);
-        link->state |= DEV_STALE_CONFIG;
-        return;
-    }
-
     /* Unlink the device chain */
     link->dev = NULL;
 
===== drivers/isdn/hisax/sedlbauer_cs.c 1.11 vs edited =====
--- 1.11/drivers/isdn/hisax/sedlbauer_cs.c	Sat Aug 16 22:22:51 2003
+++ edited/drivers/isdn/hisax/sedlbauer_cs.c	Mon Aug 25 12:47:04 2003
@@ -535,18 +535,6 @@
 {
     DEBUG(0, "sedlbauer_release(0x%p)\n", link);
 
-    /*
-       If the device is currently in use, we won't release until it
-       is actually closed, because until then, we can't be sure that
-       no one will try to access the device or its data structures.
-    */
-    if (link->open) {
-	DEBUG(1, "sedlbauer_cs: release postponed, '%s' still open\n",
-	      link->dev->dev_name);
-	link->state |= DEV_STALE_CONFIG;
-	return;
-    }
-
     /* Unlink the device chain */
     link->dev = NULL;
 



More information about the linux-pcmcia mailing list