Skip to contentSkip to conversation

atm/he: reorder add_wait_queue() and

PATCH New Nishanth Aravamudan 1 participant 1 message Jan 17, 2005

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 2/22 atm/he: reorder add_wait_queue() and

Hi,

Please consider applying.

Description: Reorder set_current_state() and add_wait_queue() so that no events are missed.

drivers/atm/he.c +2 -2
@@ -2573,8 +2573,8 @@ he_close(struct atm_vcc *vcc)
 			udelay(250);
 		}
 
-		add_wait_queue(&he_vcc->rx_waitq, &wait);
 		set_current_state(TASK_UNINTERRUPTIBLE);
+		add_wait_queue(&he_vcc->rx_waitq, &wait);
 
 		he_writel_rsr0(he_dev, RSR0_CLOSE_CONN, cid);
 		(void) he_readl_rsr0(he_dev, cid);		/* flush posted writes */
@@ -2648,8 +2648,8 @@ he_close(struct atm_vcc *vcc)
 		tpd->vcc = vcc;
 		wmb();
 
-		add_wait_queue(&he_vcc->tx_waitq, &wait);
 		set_current_state(TASK_UNINTERRUPTIBLE);
+		add_wait_queue(&he_vcc->tx_waitq, &wait);
 		__enqueue_tpd(he_dev, tpd, cid);
 		spin_unlock_irqrestore(&he_dev->global_lock, flags);
 

_______________________________________________
Kernel-janitors mailing list
[email protected]
http://lists.osdl.org/mailman/listinfo/kernel-janitors