Skip to content

Commit c8ef3c9

Browse files
GUO Zihuakuba-moo
authored andcommitted
net: lantiq_etop: 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. ltq_etop_tx() 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 7b620e1 commit c8ef3c9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/net/ethernet/lantiq_etop.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -470,7 +470,7 @@ ltq_etop_stop(struct net_device *dev)
470470
return 0;
471471
}
472472

473-
static int
473+
static netdev_tx_t
474474
ltq_etop_tx(struct sk_buff *skb, struct net_device *dev)
475475
{
476476
int queue = skb_get_queue_mapping(skb);

0 commit comments

Comments
 (0)