aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/irda
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/irda')
-rw-r--r--drivers/net/irda/au1k_ir.c4
-rw-r--r--drivers/net/irda/donauboe.c8
-rw-r--r--drivers/net/irda/irda-usb.c4
-rw-r--r--drivers/net/irda/kingsun-sir.c5
-rw-r--r--drivers/net/irda/ks959-sir.c5
-rw-r--r--drivers/net/irda/ksdazzle-sir.c5
-rw-r--r--drivers/net/irda/mcs7780.c6
-rw-r--r--drivers/net/irda/sir_dev.c2
8 files changed, 12 insertions, 27 deletions
diff --git a/drivers/net/irda/au1k_ir.c b/drivers/net/irda/au1k_ir.c
index 269153eedd26..c4361d466597 100644
--- a/drivers/net/irda/au1k_ir.c
+++ b/drivers/net/irda/au1k_ir.c
@@ -512,13 +512,13 @@ static int au1k_irda_hard_xmit(struct sk_buff *skb, struct net_device *dev)
512 printk(KERN_DEBUG "%s: tx_full\n", dev->name); 512 printk(KERN_DEBUG "%s: tx_full\n", dev->name);
513 netif_stop_queue(dev); 513 netif_stop_queue(dev);
514 aup->tx_full = 1; 514 aup->tx_full = 1;
515 return 1; 515 return NETDEV_TX_BUSY;
516 } 516 }
517 else if (((aup->tx_head + 1) & (NUM_IR_DESC - 1)) == aup->tx_tail) { 517 else if (((aup->tx_head + 1) & (NUM_IR_DESC - 1)) == aup->tx_tail) {
518 printk(KERN_DEBUG "%s: tx_full\n", dev->name); 518 printk(KERN_DEBUG "%s: tx_full\n", dev->name);
519 netif_stop_queue(dev); 519 netif_stop_queue(dev);
520 aup->tx_full = 1; 520 aup->tx_full = 1;
521 return 1; 521 return NETDEV_TX_BUSY;
522 } 522 }
523 523
524 pDB = aup->tx_db_inuse[aup->tx_head]; 524 pDB = aup->tx_db_inuse[aup->tx_head];
diff --git a/drivers/net/irda/donauboe.c b/drivers/net/irda/donauboe.c
index 6b6548b9fda0..9a0346e751ac 100644
--- a/drivers/net/irda/donauboe.c
+++ b/drivers/net/irda/donauboe.c
@@ -994,11 +994,11 @@ toshoboe_hard_xmit (struct sk_buff *skb, struct net_device *dev)
994 994
995 /* change speed pending, wait for its execution */ 995 /* change speed pending, wait for its execution */
996 if (self->new_speed) 996 if (self->new_speed)
997 return -EBUSY; 997 return NETDEV_TX_BUSY;
998 998
999 /* device stopped (apm) wait for restart */ 999 /* device stopped (apm) wait for restart */
1000 if (self->stopped) 1000 if (self->stopped)
1001 return -EBUSY; 1001 return NETDEV_TX_BUSY;
1002 1002
1003 toshoboe_checkstuck (self); 1003 toshoboe_checkstuck (self);
1004 1004
@@ -1049,7 +1049,7 @@ toshoboe_hard_xmit (struct sk_buff *skb, struct net_device *dev)
1049 if (self->txpending) 1049 if (self->txpending)
1050 { 1050 {
1051 spin_unlock_irqrestore(&self->spinlock, flags); 1051 spin_unlock_irqrestore(&self->spinlock, flags);
1052 return -EBUSY; 1052 return NETDEV_TX_BUSY;
1053 } 1053 }
1054 1054
1055 /* If in SIR mode we need to generate a string of XBOFs */ 1055 /* If in SIR mode we need to generate a string of XBOFs */
@@ -1105,7 +1105,7 @@ dumpbufs(skb->data,skb->len,'>');
1105 ,skb->len, self->ring->tx[self->txs].control, self->txpending); 1105 ,skb->len, self->ring->tx[self->txs].control, self->txpending);
1106 toshoboe_start_DMA(self, OBOE_CONFIG0H_ENTX); 1106 toshoboe_start_DMA(self, OBOE_CONFIG0H_ENTX);
1107 spin_unlock_irqrestore(&self->spinlock, flags); 1107 spin_unlock_irqrestore(&self->spinlock, flags);
1108 return -EBUSY; 1108 return NETDEV_TX_BUSY;
1109 } 1109 }
1110 1110
1111 if (INB (OBOE_ENABLEH) & OBOE_ENABLEH_SIRON) 1111 if (INB (OBOE_ENABLEH) & OBOE_ENABLEH_SIRON)
diff --git a/drivers/net/irda/irda-usb.c b/drivers/net/irda/irda-usb.c
index 394b2b17075e..0c0831c03f64 100644
--- a/drivers/net/irda/irda-usb.c
+++ b/drivers/net/irda/irda-usb.c
@@ -389,7 +389,6 @@ static int irda_usb_hard_xmit(struct sk_buff *skb, struct net_device *netdev)
389 s32 speed; 389 s32 speed;
390 s16 xbofs; 390 s16 xbofs;
391 int res, mtt; 391 int res, mtt;
392 int err = 1; /* Failed */
393 392
394 IRDA_DEBUG(4, "%s() on %s\n", __func__, netdev->name); 393 IRDA_DEBUG(4, "%s() on %s\n", __func__, netdev->name);
395 394
@@ -430,7 +429,6 @@ static int irda_usb_hard_xmit(struct sk_buff *skb, struct net_device *netdev)
430 irda_usb_change_speed_xbofs(self); 429 irda_usb_change_speed_xbofs(self);
431 netdev->trans_start = jiffies; 430 netdev->trans_start = jiffies;
432 /* Will netif_wake_queue() in callback */ 431 /* Will netif_wake_queue() in callback */
433 err = 0; /* No error */
434 goto drop; 432 goto drop;
435 } 433 }
436 } 434 }
@@ -542,7 +540,7 @@ drop:
542 /* Drop silently the skb and exit */ 540 /* Drop silently the skb and exit */
543 dev_kfree_skb(skb); 541 dev_kfree_skb(skb);
544 spin_unlock_irqrestore(&self->lock, flags); 542 spin_unlock_irqrestore(&self->lock, flags);
545 return err; /* Usually 1 */ 543 return NETDEV_TX_OK;
546} 544}
547 545
548/*------------------------------------------------------------------*/ 546/*------------------------------------------------------------------*/
diff --git a/drivers/net/irda/kingsun-sir.c b/drivers/net/irda/kingsun-sir.c
index 9d813bc4502e..c3e4e2c435ba 100644
--- a/drivers/net/irda/kingsun-sir.c
+++ b/drivers/net/irda/kingsun-sir.c
@@ -156,9 +156,6 @@ static int kingsun_hard_xmit(struct sk_buff *skb, struct net_device *netdev)
156 int wraplen; 156 int wraplen;
157 int ret = 0; 157 int ret = 0;
158 158
159 if (skb == NULL || netdev == NULL)
160 return -EINVAL;
161
162 netif_stop_queue(netdev); 159 netif_stop_queue(netdev);
163 160
164 /* the IRDA wrapping routines don't deal with non linear skb */ 161 /* the IRDA wrapping routines don't deal with non linear skb */
@@ -197,7 +194,7 @@ static int kingsun_hard_xmit(struct sk_buff *skb, struct net_device *netdev)
197 dev_kfree_skb(skb); 194 dev_kfree_skb(skb);
198 spin_unlock(&kingsun->lock); 195 spin_unlock(&kingsun->lock);
199 196
200 return ret; 197 return NETDEV_TX_OK;
201} 198}
202 199
203/* Receive callback function */ 200/* Receive callback function */
diff --git a/drivers/net/irda/ks959-sir.c b/drivers/net/irda/ks959-sir.c
index b6ffe9715b61..d73b8b64fcb9 100644
--- a/drivers/net/irda/ks959-sir.c
+++ b/drivers/net/irda/ks959-sir.c
@@ -391,9 +391,6 @@ static int ks959_hard_xmit(struct sk_buff *skb, struct net_device *netdev)
391 unsigned int wraplen; 391 unsigned int wraplen;
392 int ret = 0; 392 int ret = 0;
393 393
394 if (skb == NULL || netdev == NULL)
395 return -EINVAL;
396
397 netif_stop_queue(netdev); 394 netif_stop_queue(netdev);
398 395
399 /* the IRDA wrapping routines don't deal with non linear skb */ 396 /* the IRDA wrapping routines don't deal with non linear skb */
@@ -428,7 +425,7 @@ static int ks959_hard_xmit(struct sk_buff *skb, struct net_device *netdev)
428 dev_kfree_skb(skb); 425 dev_kfree_skb(skb);
429 spin_unlock(&kingsun->lock); 426 spin_unlock(&kingsun->lock);
430 427
431 return ret; 428 return NETDEV_TX_OK;
432} 429}
433 430
434/* Receive callback function */ 431/* Receive callback function */
diff --git a/drivers/net/irda/ksdazzle-sir.c b/drivers/net/irda/ksdazzle-sir.c
index 64df27f2bfd4..1ef45ec74422 100644
--- a/drivers/net/irda/ksdazzle-sir.c
+++ b/drivers/net/irda/ksdazzle-sir.c
@@ -304,9 +304,6 @@ static int ksdazzle_hard_xmit(struct sk_buff *skb, struct net_device *netdev)
304 unsigned int wraplen; 304 unsigned int wraplen;
305 int ret = 0; 305 int ret = 0;
306 306
307 if (skb == NULL || netdev == NULL)
308 return -EINVAL;
309
310 netif_stop_queue(netdev); 307 netif_stop_queue(netdev);
311 308
312 /* the IRDA wrapping routines don't deal with non linear skb */ 309 /* the IRDA wrapping routines don't deal with non linear skb */
@@ -341,7 +338,7 @@ static int ksdazzle_hard_xmit(struct sk_buff *skb, struct net_device *netdev)
341 dev_kfree_skb(skb); 338 dev_kfree_skb(skb);
342 spin_unlock(&kingsun->lock); 339 spin_unlock(&kingsun->lock);
343 340
344 return ret; 341 return NETDEV_TX_OK;
345} 342}
346 343
347/* Receive callback function */ 344/* Receive callback function */
diff --git a/drivers/net/irda/mcs7780.c b/drivers/net/irda/mcs7780.c
index fac504d0cfd8..f4df1001983c 100644
--- a/drivers/net/irda/mcs7780.c
+++ b/drivers/net/irda/mcs7780.c
@@ -824,10 +824,6 @@ static int mcs_hard_xmit(struct sk_buff *skb, struct net_device *ndev)
824 int wraplen; 824 int wraplen;
825 int ret = 0; 825 int ret = 0;
826 826
827
828 if (skb == NULL || ndev == NULL)
829 return -EINVAL;
830
831 netif_stop_queue(ndev); 827 netif_stop_queue(ndev);
832 mcs = netdev_priv(ndev); 828 mcs = netdev_priv(ndev);
833 829
@@ -870,7 +866,7 @@ static int mcs_hard_xmit(struct sk_buff *skb, struct net_device *ndev)
870 866
871 dev_kfree_skb(skb); 867 dev_kfree_skb(skb);
872 spin_unlock_irqrestore(&mcs->lock, flags); 868 spin_unlock_irqrestore(&mcs->lock, flags);
873 return ret; 869 return NETDEV_TX_OK;
874} 870}
875 871
876static const struct net_device_ops mcs_netdev_ops = { 872static const struct net_device_ops mcs_netdev_ops = {
diff --git a/drivers/net/irda/sir_dev.c b/drivers/net/irda/sir_dev.c
index d940809762ec..fd0796c3db3c 100644
--- a/drivers/net/irda/sir_dev.c
+++ b/drivers/net/irda/sir_dev.c
@@ -607,7 +607,7 @@ static int sirdev_hard_xmit(struct sk_buff *skb, struct net_device *ndev)
607 * stopped so the network layer will retry after the 607 * stopped so the network layer will retry after the
608 * fsm completes and wakes the queue. 608 * fsm completes and wakes the queue.
609 */ 609 */
610 return 1; 610 return NETDEV_TX_BUSY;
611 } 611 }
612 else if (unlikely(err)) { 612 else if (unlikely(err)) {
613 /* other fatal error - forget the speed change and 613 /* other fatal error - forget the speed change and