Thread (24 messages) read the whole thread 24 messages, 5 authors, 2025-01-23

Re: [PATCH net-next 1/7] eth: tg3: fix calling napi_enable() in atomic context

From: Michael Chan <michael.chan@broadcom.com>
Date: 2025-01-22 07:42:06

On Tue, Jan 21, 2025 at 2:15 PM Jakub Kicinski [off-list ref] wrote:
tg3 has a spin lock protecting most of the config,
switch to taking netdev_lock() explicitly on enable/start
paths. Disable/stop paths seem to not be under the spin
lock (since napi_disable() already couldn't sleep),
so leave that side as is.

tg3_restart_hw() releases and re-takes the spin lock,
we need to do the same because dev_close() needs to
take netdev_lock().
The patch looks good to me.  One minor suggestion is to add the Sparse macros:

__releases(tp->dev->lock)
__acquires(tp->dev->lock)

to tg3_restart_hw() since we already do the same thing there for tp->lock.

Attachments

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help