diff mbox

[2/2] atm: [he] adjust tests to account for sk_wmem_alloc changes

Message ID 200912041522.nB4FMHgq028277@cmf.nrl.navy.mil
State Accepted, archived
Delegated to: David Miller
Headers show

Commit Message

chas williams - CONTRACTOR Dec. 4, 2009, 3:22 p.m. UTC
From: chas williams - CONTRACTOR <chas@cmf.nrl.navy.mil>

atm: [he] adjust tests to account for sk_wmem_alloc changes

due to reference counting sk_wmem_alloc now has a value of 1 when all
the outstanding data has been sent.

Signed-off-by: Chas Williams - CONTRACTOR <chas@cmf.nrl.navy.mil>

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Comments

David Miller Dec. 9, 2009, 4:22 a.m. UTC | #1
From: "chas williams - CONTRACTOR" <chas@cmf.nrl.navy.mil>
Date: Fri, 04 Dec 2009 10:22:17 -0500

> From: chas williams - CONTRACTOR <chas@cmf.nrl.navy.mil>
> 
> atm: [he] adjust tests to account for sk_wmem_alloc changes
> 
> due to reference counting sk_wmem_alloc now has a value of 1 when all
> the outstanding data has been sent.
> 
> Signed-off-by: Chas Williams - CONTRACTOR <chas@cmf.nrl.navy.mil>

Applied.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/drivers/atm/he.c b/drivers/atm/he.c
index 7066703..d744d62 100644
--- a/drivers/atm/he.c
+++ b/drivers/atm/he.c
@@ -2505,7 +2505,7 @@  he_close(struct atm_vcc *vcc)
 		 * TBRQ, the host issues the close command to the adapter.
 		 */
 
-		while (((tx_inuse = atomic_read(&sk_atm(vcc)->sk_wmem_alloc)) > 0) &&
+		while (((tx_inuse = atomic_read(&sk_atm(vcc)->sk_wmem_alloc)) > 1) &&
 		       (retry < MAX_RETRY)) {
 			msleep(sleep);
 			if (sleep < 250)
@@ -2514,7 +2514,7 @@  he_close(struct atm_vcc *vcc)
 			++retry;
 		}
 
-		if (tx_inuse)
+		if (tx_inuse > 1)
 			hprintk("close tx cid 0x%x tx_inuse = %d\n", cid, tx_inuse);
 
 		/* 2.3.1.1 generic close operations with flush */