diff options
author | Stephen Hemminger <shemminger@vyatta.com> | 2009-08-31 15:50:58 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-09-01 04:14:07 -0400 |
commit | 61357325f377889a1daffa14962d705dc814dd0e (patch) | |
tree | 7b436f1097abbc5681de6d1e5901f62963b42220 /drivers/net/r6040.c | |
parent | d0cf9c0dadcdc89a755bcb301cfc9c796eb28ccf (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/r6040.c')
-rw-r--r-- | drivers/net/r6040.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/net/r6040.c b/drivers/net/r6040.c index 8068a07eb2b3..7dfcb58b0eb4 100644 --- a/drivers/net/r6040.c +++ b/drivers/net/r6040.c | |||
@@ -883,13 +883,13 @@ static int r6040_open(struct net_device *dev) | |||
883 | return 0; | 883 | return 0; |
884 | } | 884 | } |
885 | 885 | ||
886 | static int r6040_start_xmit(struct sk_buff *skb, struct net_device *dev) | 886 | static netdev_tx_t r6040_start_xmit(struct sk_buff *skb, |
887 | struct net_device *dev) | ||
887 | { | 888 | { |
888 | struct r6040_private *lp = netdev_priv(dev); | 889 | struct r6040_private *lp = netdev_priv(dev); |
889 | struct r6040_descriptor *descptr; | 890 | struct r6040_descriptor *descptr; |
890 | void __iomem *ioaddr = lp->base; | 891 | void __iomem *ioaddr = lp->base; |
891 | unsigned long flags; | 892 | unsigned long flags; |
892 | int ret = NETDEV_TX_OK; | ||
893 | 893 | ||
894 | /* Critical Section */ | 894 | /* Critical Section */ |
895 | spin_lock_irqsave(&lp->lock, flags); | 895 | spin_lock_irqsave(&lp->lock, flags); |
@@ -899,8 +899,7 @@ static int r6040_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
899 | spin_unlock_irqrestore(&lp->lock, flags); | 899 | spin_unlock_irqrestore(&lp->lock, flags); |
900 | netif_stop_queue(dev); | 900 | netif_stop_queue(dev); |
901 | printk(KERN_ERR DRV_NAME ": no tx descriptor\n"); | 901 | printk(KERN_ERR DRV_NAME ": no tx descriptor\n"); |
902 | ret = NETDEV_TX_BUSY; | 902 | return NETDEV_TX_BUSY; |
903 | return ret; | ||
904 | } | 903 | } |
905 | 904 | ||
906 | /* Statistic Counter */ | 905 | /* Statistic Counter */ |
@@ -928,7 +927,8 @@ static int r6040_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
928 | 927 | ||
929 | dev->trans_start = jiffies; | 928 | dev->trans_start = jiffies; |
930 | spin_unlock_irqrestore(&lp->lock, flags); | 929 | spin_unlock_irqrestore(&lp->lock, flags); |
931 | return ret; | 930 | |
931 | return NETDEV_TX_OK; | ||
932 | } | 932 | } |
933 | 933 | ||
934 | static void r6040_multicast_list(struct net_device *dev) | 934 | static void r6040_multicast_list(struct net_device *dev) |