Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

hdlc: convert to netdev_tx_t

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Stephen Hemminger and committed by
David S. Miller
4c5d502d d71a6749

+16 -20
+3 -4
drivers/char/synclink.c
··· 7697 7697 * 7698 7698 * skb socket buffer containing HDLC frame 7699 7699 * dev pointer to network device structure 7700 - * 7701 - * returns 0 if success, otherwise error code 7702 7700 */ 7703 - static int hdlcdev_xmit(struct sk_buff *skb, struct net_device *dev) 7701 + static netdev_tx_t hdlcdev_xmit(struct sk_buff *skb, 7702 + struct net_device *dev) 7704 7703 { 7705 7704 struct mgsl_struct *info = dev_to_port(dev); 7706 7705 unsigned long flags; ··· 7730 7731 usc_start_transmitter(info); 7731 7732 spin_unlock_irqrestore(&info->irq_spinlock,flags); 7732 7733 7733 - return 0; 7734 + return NETDEV_TX_OK; 7734 7735 } 7735 7736 7736 7737 /**
+3 -4
drivers/char/synclinkmp.c
··· 1608 1608 * 1609 1609 * skb socket buffer containing HDLC frame 1610 1610 * dev pointer to network device structure 1611 - * 1612 - * returns 0 if success, otherwise error code 1613 1611 */ 1614 - static int hdlcdev_xmit(struct sk_buff *skb, struct net_device *dev) 1612 + static netdev_tx_t hdlcdev_xmit(struct sk_buff *skb, 1613 + struct net_device *dev) 1615 1614 { 1616 1615 SLMP_INFO *info = dev_to_port(dev); 1617 1616 unsigned long flags; ··· 1641 1642 tx_start(info); 1642 1643 spin_unlock_irqrestore(&info->lock,flags); 1643 1644 1644 - return 0; 1645 + return NETDEV_TX_OK; 1645 1646 } 1646 1647 1647 1648 /**
+4 -4
include/linux/hdlc.h
··· 38 38 int (*ioctl)(struct net_device *dev, struct ifreq *ifr); 39 39 __be16 (*type_trans)(struct sk_buff *skb, struct net_device *dev); 40 40 int (*netif_rx)(struct sk_buff *skb); 41 - int (*xmit)(struct sk_buff *skb, struct net_device *dev); 41 + netdev_tx_t (*xmit)(struct sk_buff *skb, struct net_device *dev); 42 42 struct module *module; 43 43 struct hdlc_proto *next; /* next protocol in the list */ 44 44 }; ··· 51 51 unsigned short encoding, unsigned short parity); 52 52 53 53 /* hardware driver must handle this instead of dev->hard_start_xmit */ 54 - int (*xmit)(struct sk_buff *skb, struct net_device *dev); 54 + netdev_tx_t (*xmit)(struct sk_buff *skb, struct net_device *dev); 55 55 56 56 /* Things below are for HDLC layer internal use only */ 57 57 const struct hdlc_proto *proto; ··· 60 60 spinlock_t state_lock; 61 61 void *state; 62 62 void *priv; 63 - }hdlc_device; 63 + } hdlc_device; 64 64 65 65 66 66 ··· 106 106 /* May be used by hardware driver */ 107 107 int hdlc_change_mtu(struct net_device *dev, int new_mtu); 108 108 /* Must be pointed to by hw driver's dev->netdev_ops->ndo_start_xmit */ 109 - int hdlc_start_xmit(struct sk_buff *skb, struct net_device *dev); 109 + netdev_tx_t hdlc_start_xmit(struct sk_buff *skb, struct net_device *dev); 110 110 111 111 int attach_hdlc_protocol(struct net_device *dev, struct hdlc_proto *proto, 112 112 size_t size);