Patchwork [4/9] claw: invalid return codes from hard_start_xmit

login
register
mail settings
Submitter Ursula Braun
Date March 24, 2009, 1:27 p.m.
Message ID <20090324133049.239518000@linux.vnet.ibm.com>
Download mbox | patch
Permalink /patch/24963/
State Accepted
Delegated to: David Miller
Headers show

Comments

Ursula Braun - March 24, 2009, 1:27 p.m.
From: Ursula Braun <ursula.braun@de.ibm.com>

Avoid kernel warnings by using the correct hard_start_xmit return
code NETDEV_TX_BUSY for skb requeuing.

Signed-off-by: Ursula Braun <ursula.braun@de.ibm.com>
---

 drivers/s390/net/claw.c |    2 ++
 1 file changed, 2 insertions(+)


--
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

Patch

diff -urpN linux-2.6/drivers/s390/net/claw.c linux-2.6-patched/drivers/s390/net/claw.c
--- linux-2.6/drivers/s390/net/claw.c	2008-12-25 00:26:37.000000000 +0100
+++ linux-2.6-patched/drivers/s390/net/claw.c	2009-03-04 15:58:30.000000000 +0100
@@ -335,6 +335,8 @@  claw_tx(struct sk_buff *skb, struct net_
         rc=claw_hw_tx( skb, dev, 1 );
         spin_unlock_irqrestore(get_ccwdev_lock(p_ch->cdev), saveflags);
 	CLAW_DBF_TEXT_(4, trace, "clawtx%d", rc);
+	if (rc)
+		rc = NETDEV_TX_BUSY;
         return rc;
 }   /*  end of claw_tx */