Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ec634fe3 authored by Patrick McHardy's avatar Patrick McHardy Committed by David S. Miller
Browse files

net: convert remaining non-symbolic return values in ndo_start_xmit() functions



This patch converts the remaining occurences of raw return values to their
symbolic counterparts in ndo_start_xmit() functions that were missed by the
previous automatic conversion.

Additionally code that assumed the symbolic value of NETDEV_TX_OK to be zero
is changed to explicitly use NETDEV_TX_OK.

Signed-off-by: default avatarPatrick McHardy <kaber@trash.net>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent a73e76e2
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -545,7 +545,7 @@ static int iss_net_start_xmit(struct sk_buff *skb, struct net_device *dev)
	spin_unlock_irqrestore(&lp->lock, flags);
	spin_unlock_irqrestore(&lp->lock, flags);


	dev_kfree_skb(skb);
	dev_kfree_skb(skb);
	return 0;
	return NETDEV_TX_OK;
}
}




+1 −1
Original line number Original line Diff line number Diff line
@@ -148,7 +148,7 @@ net_send_packet(struct sk_buff *skb, struct net_device *dev)
	if (lp->sk_count <= 3) {
	if (lp->sk_count <= 3) {
		schedule_work(&((hysdn_card *) dev->ml_priv)->irq_queue);
		schedule_work(&((hysdn_card *) dev->ml_priv)->irq_queue);
	}
	}
	return (0);		/* success */
	return NETDEV_TX_OK;	/* success */
}				/* net_send_packet */
}				/* net_send_packet */




+2 −2
Original line number Original line Diff line number Diff line
@@ -1051,12 +1051,12 @@ isdn_net_xmit(struct net_device *ndev, struct sk_buff *skb)
	isdn_net_dev *nd;
	isdn_net_dev *nd;
	isdn_net_local *slp;
	isdn_net_local *slp;
	isdn_net_local *lp = (isdn_net_local *) netdev_priv(ndev);
	isdn_net_local *lp = (isdn_net_local *) netdev_priv(ndev);
	int retv = 0;
	int retv = NETDEV_TX_OK;


	if (((isdn_net_local *) netdev_priv(ndev))->master) {
	if (((isdn_net_local *) netdev_priv(ndev))->master) {
		printk("isdn BUG at %s:%d!\n", __FILE__, __LINE__);
		printk("isdn BUG at %s:%d!\n", __FILE__, __LINE__);
		dev_kfree_skb(skb);
		dev_kfree_skb(skb);
		return 0;
		return NETDEV_TX_OK;
	}
	}


	/* For the other encaps the header has already been built */
	/* For the other encaps the header has already been built */
+3 −3
Original line number Original line Diff line number Diff line
@@ -1223,7 +1223,7 @@ isdn_ppp_xmit(struct sk_buff *skb, struct net_device *netdev)
	isdn_net_dev *nd;
	isdn_net_dev *nd;
	unsigned int proto = PPP_IP;     /* 0x21 */
	unsigned int proto = PPP_IP;     /* 0x21 */
	struct ippp_struct *ipt,*ipts;
	struct ippp_struct *ipt,*ipts;
	int slot, retval = 0;
	int slot, retval = NETDEV_TX_OK;


	mlp = (isdn_net_local *) netdev_priv(netdev);
	mlp = (isdn_net_local *) netdev_priv(netdev);
	nd = mlp->netdev;       /* get master lp */
	nd = mlp->netdev;       /* get master lp */
@@ -1240,7 +1240,7 @@ isdn_ppp_xmit(struct sk_buff *skb, struct net_device *netdev)
	if (!(ipts->pppcfg & SC_ENABLE_IP)) {	/* PPP connected ? */
	if (!(ipts->pppcfg & SC_ENABLE_IP)) {	/* PPP connected ? */
		if (ipts->debug & 0x1)
		if (ipts->debug & 0x1)
			printk(KERN_INFO "%s: IP frame delayed.\n", netdev->name);
			printk(KERN_INFO "%s: IP frame delayed.\n", netdev->name);
		retval = 1;
		retval = NETDEV_TX_BUSY;
		goto out;
		goto out;
	}
	}


@@ -1261,7 +1261,7 @@ isdn_ppp_xmit(struct sk_buff *skb, struct net_device *netdev)
	lp = isdn_net_get_locked_lp(nd);
	lp = isdn_net_get_locked_lp(nd);
	if (!lp) {
	if (!lp) {
		printk(KERN_WARNING "%s: all channels busy - requeuing!\n", netdev->name);
		printk(KERN_WARNING "%s: all channels busy - requeuing!\n", netdev->name);
		retval = 1;
		retval = NETDEV_TX_BUSY;
		goto out;
		goto out;
	}
	}
	/* we have our lp locked from now on */
	/* we have our lp locked from now on */
+1 −1
Original line number Original line Diff line number Diff line
@@ -485,7 +485,7 @@ static int el_start_xmit(struct sk_buff *skb, struct net_device *dev)
			if (el_debug > 2)
			if (el_debug > 2)
				pr_debug(" queued xmit.\n");
				pr_debug(" queued xmit.\n");
			dev_kfree_skb(skb);
			dev_kfree_skb(skb);
			return 0;
			return NETDEV_TX_OK;
		}
		}
		/* A receive upset our load, despite our best efforts */
		/* A receive upset our load, despite our best efforts */
		if (el_debug > 2)
		if (el_debug > 2)
Loading