net: usbnet: convert to new tasklet API
Subsystems (5)
cover net: usbnet: convert to new tasklet API
From: Emil Renner Berthing <[email protected]>
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.
Emil Renner Berthing (2):
net: usbnet: use tasklet_init
net: usbnet: use new tasklet API
drivers/net/usb/usbnet.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-)
Signature · 1 line
2.30.0
PATCH 1/2 net: usbnet: initialize tasklet using tasklet_init
From: Emil Renner Berthing <[email protected]>
Initialize tasklet using tasklet_init() rather than open-coding it.
--- drivers/net/usb/usbnet.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/net/usb/usbnet.c +1 -2
@@ -1673,8 +1673,7 @@ usbnet_probe (struct usb_interface *udev, const struct usb_device_id *prod)skb_queue_head_init (&dev->txq);skb_queue_head_init (&dev->done);skb_queue_head_init (&dev->rxq_pause); - dev->bh.func = usbnet_bh_tasklet; - dev->bh.data = (unsigned long )&dev->delay; +tasklet_init (&dev->bh, usbnet_bh_tasklet, (unsigned long )&dev->delay);INIT_WORK (&dev->kevent, usbnet_deferred_kevent);init_usb_anchor (&dev->deferred);timer_setup (&dev->delay, usbnet_bh,0 );
Signature · 1 line
2.30.0
Re: [PATCH 1/2] net: usbnet: initialize tasklet using tasklet_init
Am Samstag, den 23.01.2021, 18:32 +0100 schrieb Emil Renner Berthing:
Quoted 5 lines
From: Emil Renner Berthing <[email protected]>
Initialize tasklet using
tasklet_init()rather than open-coding it.Signed-off-by Emil Renner Berthing <[email protected]>
PATCH 2/2 net: usbnet: use new tasklet API
In reply to Emil Renner BerthingFrom: Emil Renner Berthing <[email protected]>
This converts the driver to use the new tasklet API introduced in commit 12cc923f1ccc ("tasklet: Introduce new initialization API")
--- drivers/net/usb/usbnet.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/net/usb/usbnet.c +4 -4
@@ -1539,11 +1539,11 @@ static void usbnet_bh (struct timer_list *t) } } -static void usbnet_bh_tasklet (unsigned long data) +static void usbnet_bh_tasklet (struct tasklet_struct *t) { -struct timer_list *t = (struct timer_list *)data; +struct usbnet *dev =from_tasklet (dev, t, bh); -usbnet_bh (t); +usbnet_bh (&dev->delay); }
@@ -1673,7 +1673,7 @@ usbnet_probe (struct usb_interface *udev, const struct usb_device_id *prod)skb_queue_head_init (&dev->txq);skb_queue_head_init (&dev->done);skb_queue_head_init (&dev->rxq_pause); -tasklet_init (&dev->bh, usbnet_bh_tasklet, (unsigned long )&dev->delay); +tasklet_setup (&dev->bh, usbnet_bh_tasklet);INIT_WORK (&dev->kevent, usbnet_deferred_kevent);init_usb_anchor (&dev->deferred);timer_setup (&dev->delay, usbnet_bh,0 );
Signature · 1 line
2.30.0
Re: [PATCH 2/2] net: usbnet: use new tasklet API
Am Samstag, den 23.01.2021, 18:32 +0100 schrieb Emil Renner Berthing:
Quoted 6 lines
From: Emil Renner Berthing <[email protected]>
This converts the driver to use the new tasklet API introduced in commit
12cc923f1ccc("tasklet: Introduce new initialization API")Signed-off-by Emil Renner Berthing <[email protected]>
This series was applied to netdev/net-next.git (refs/heads/master):
Hello:
This series was applied to netdev/net-next.git (refs/heads/master):
Quoted 8 lines · On Sat, 23 Jan 2021 18:32:19 +0100 you wrote:
From: Emil Renner Berthing <[email protected]>
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.
[...]
Here is the summary with links:
- [1/2] net: usbnet: initialize tasklet using tasklet_init
https://git.kernel.org/netdev/net-next/c/90a586b8d741 - [2/2] net: usbnet: use new tasklet API https://git.kernel.org/netdev/net-next/c/c955e329bb9d
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html