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

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'net-usbnet-convert-to-new-tasklet-api'

Emil Renner Berthing says:

====================
net: usbnet: convert to new tasklet API

This converts the usbnet driver to use the new tasklet API introduced in
commit 12cc923f1ccc ("tasklet: Introduce new initialization API")

It is split into two commits for ease of reviewing.
====================

Link: https://lore.kernel.org/r/20210123173221.5855-1-esmil@mailme.dk
Signed-off-by: Jakub Kicinski <kuba@kernel.org>

+4 -5
+4 -5
drivers/net/usb/usbnet.c
··· 1539 1539 } 1540 1540 } 1541 1541 1542 - static void usbnet_bh_tasklet(unsigned long data) 1542 + static void usbnet_bh_tasklet(struct tasklet_struct *t) 1543 1543 { 1544 - struct timer_list *t = (struct timer_list *)data; 1544 + struct usbnet *dev = from_tasklet(dev, t, bh); 1545 1545 1546 - usbnet_bh(t); 1546 + usbnet_bh(&dev->delay); 1547 1547 } 1548 1548 1549 1549 ··· 1673 1673 skb_queue_head_init (&dev->txq); 1674 1674 skb_queue_head_init (&dev->done); 1675 1675 skb_queue_head_init(&dev->rxq_pause); 1676 - dev->bh.func = usbnet_bh_tasklet; 1677 - dev->bh.data = (unsigned long)&dev->delay; 1676 + tasklet_setup(&dev->bh, usbnet_bh_tasklet); 1678 1677 INIT_WORK (&dev->kevent, usbnet_deferred_kevent); 1679 1678 init_usb_anchor(&dev->deferred); 1680 1679 timer_setup(&dev->delay, usbnet_bh, 0);