]> git.baikalelectronics.ru Git - kernel.git/commit
net: lan966x: Fix sleep in atomic context when injecting frames
authorHoratiu Vultur <horatiu.vultur@microchip.com>
Tue, 25 Jan 2022 11:48:15 +0000 (12:48 +0100)
committerDavid S. Miller <davem@davemloft.net>
Wed, 26 Jan 2022 15:45:49 +0000 (15:45 +0000)
commit30be524b0004c32fa5444d4f2feb00fcb1d4da2e
treee7c9766aba159a715ae78522a40f91394f986ab8
parent96044e494ef6215d1be59c6841e2ec565e65f51b
net: lan966x: Fix sleep in atomic context when injecting frames

On lan966x, when injecting a frame it was polling the register
QS_INJ_STATUS to see if it can continue with the injection of the frame.
The problem was that it was using readx_poll_timeout which could sleep
in atomic context.
This patch fixes this issue by using readx_poll_timeout_atomic.

Fixes: bb48b7a2878d28 ("net: lan966x: add port module support")
Signed-off-by: Horatiu Vultur <horatiu.vultur@microchip.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/microchip/lan966x/lan966x_main.c