Skip to content

Commit 0dbaf0f

Browse files
GUO Zihuakuba-moo
authored andcommitted
net: xscale: Fix return type for implementation of ndo_start_xmit
Since Linux now supports CFI, it will be a good idea to fix mismatched return type for implementation of hooks. Otherwise this might get cought out by CFI and cause a panic. eth_xmit() would return either NETDEV_TX_BUSY or NETDEV_TX_OK, so change the return type to netdev_tx_t directly. Signed-off-by: GUO Zihua <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 12f7bd2 commit 0dbaf0f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/net/ethernet/xscale/ixp4xx_eth.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -841,7 +841,7 @@ static void eth_txdone_irq(void *unused)
841841
}
842842
}
843843

844-
static int eth_xmit(struct sk_buff *skb, struct net_device *dev)
844+
static netdev_tx_t eth_xmit(struct sk_buff *skb, struct net_device *dev)
845845
{
846846
struct port *port = netdev_priv(dev);
847847
unsigned int txreadyq = port->plat->txreadyq;

0 commit comments

Comments
 (0)