aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/r8169.c
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@vyatta.com>2009-08-31 15:50:58 -0400
committerDavid S. Miller <davem@davemloft.net>2009-09-01 04:14:07 -0400
commit61357325f377889a1daffa14962d705dc814dd0e (patch)
tree7b436f1097abbc5681de6d1e5901f62963b42220 /drivers/net/r8169.c
parentd0cf9c0dadcdc89a755bcb301cfc9c796eb28ccf (diff)
netdev: convert bulk of drivers to netdev_tx_t
In a couple of cases collapse some extra code like: int retval = NETDEV_TX_OK; ... return retval; into return NETDEV_TX_OK; Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/r8169.c')
-rw-r--r--drivers/net/r8169.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/net/r8169.c b/drivers/net/r8169.c
index 8cd85309c675..ec0092affd5d 100644
--- a/drivers/net/r8169.c
+++ b/drivers/net/r8169.c
@@ -507,7 +507,8 @@ MODULE_LICENSE("GPL");
507MODULE_VERSION(RTL8169_VERSION); 507MODULE_VERSION(RTL8169_VERSION);
508 508
509static int rtl8169_open(struct net_device *dev); 509static int rtl8169_open(struct net_device *dev);
510static int rtl8169_start_xmit(struct sk_buff *skb, struct net_device *dev); 510static netdev_tx_t rtl8169_start_xmit(struct sk_buff *skb,
511 struct net_device *dev);
511static irqreturn_t rtl8169_interrupt(int irq, void *dev_instance); 512static irqreturn_t rtl8169_interrupt(int irq, void *dev_instance);
512static int rtl8169_init_ring(struct net_device *dev); 513static int rtl8169_init_ring(struct net_device *dev);
513static void rtl_hw_start(struct net_device *dev); 514static void rtl_hw_start(struct net_device *dev);
@@ -3357,7 +3358,8 @@ static inline u32 rtl8169_tso_csum(struct sk_buff *skb, struct net_device *dev)
3357 return 0; 3358 return 0;
3358} 3359}
3359 3360
3360static int rtl8169_start_xmit(struct sk_buff *skb, struct net_device *dev) 3361static netdev_tx_t rtl8169_start_xmit(struct sk_buff *skb,
3362 struct net_device *dev)
3361{ 3363{
3362 struct rtl8169_private *tp = netdev_priv(dev); 3364 struct rtl8169_private *tp = netdev_priv(dev);
3363 unsigned int frags, entry = tp->cur_tx % NUM_TX_DESC; 3365 unsigned int frags, entry = tp->cur_tx % NUM_TX_DESC;
@@ -3366,7 +3368,6 @@ static int rtl8169_start_xmit(struct sk_buff *skb, struct net_device *dev)
3366 dma_addr_t mapping; 3368 dma_addr_t mapping;
3367 u32 status, len; 3369 u32 status, len;
3368 u32 opts1; 3370 u32 opts1;
3369 int ret = NETDEV_TX_OK;
3370 3371
3371 if (unlikely(TX_BUFFS_AVAIL(tp) < skb_shinfo(skb)->nr_frags)) { 3372 if (unlikely(TX_BUFFS_AVAIL(tp) < skb_shinfo(skb)->nr_frags)) {
3372 if (netif_msg_drv(tp)) { 3373 if (netif_msg_drv(tp)) {
@@ -3418,13 +3419,12 @@ static int rtl8169_start_xmit(struct sk_buff *skb, struct net_device *dev)
3418 } 3419 }
3419 3420
3420out: 3421out:
3421 return ret; 3422 return NETDEV_TX_OK;
3422 3423
3423err_stop: 3424err_stop:
3424 netif_stop_queue(dev); 3425 netif_stop_queue(dev);
3425 ret = NETDEV_TX_BUSY;
3426 dev->stats.tx_dropped++; 3426 dev->stats.tx_dropped++;
3427 goto out; 3427 return NETDEV_TX_BUSY;
3428} 3428}
3429 3429
3430static void rtl8169_pcierr_interrupt(struct net_device *dev) 3430static void rtl8169_pcierr_interrupt(struct net_device *dev)