linux-stable/drivers/soc
Sean Anderson 9a3ca8292c soc: fsl: qbman: Use raw spinlock for cgr_lock
[ Upstream commit fbec4e7fed ]

smp_call_function always runs its callback in hard IRQ context, even on
PREEMPT_RT, where spinlocks can sleep. So we need to use a raw spinlock
for cgr_lock to ensure we aren't waiting on a sleeping task.

Although this bug has existed for a while, it was not apparent until
commit ef2a8d5478 ("net: dpaa: Adjust queue depth on rate change")
which invokes smp_call_function_single via qman_update_cgr_safe every
time a link goes up or down.

Fixes: 96f413f476 ("soc/fsl/qbman: fix issue in qman_delete_cgr_safe()")
CC: stable@vger.kernel.org
Reported-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Closes: https://lore.kernel.org/all/20230323153935.nofnjucqjqnz34ej@skbuf/
Reported-by: Steffen Trumtrar <s.trumtrar@pengutronix.de>
Closes: https://lore.kernel.org/linux-arm-kernel/87wmsyvclu.fsf@pengutronix.de/
Signed-off-by: Sean Anderson <sean.anderson@linux.dev>
Reviewed-by: Camelia Groza <camelia.groza@nxp.com>
Tested-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-04-10 16:18:42 +02:00
..
actions
amlogic drivers: meson: secure-pwrc: always enable DMA domain 2023-07-23 13:47:09 +02:00
aspeed soc: aspeed: socinfo: Add kfree for kstrdup 2023-08-26 14:23:36 +02:00
atmel
bcm
canaan
dove
fsl soc: fsl: qbman: Use raw spinlock for cgr_lock 2024-04-10 16:18:42 +02:00
gemini
imx soc: imx8m: Enable OCOTP clock for imx8mm before reading registers 2023-10-06 13:18:14 +02:00
ixp4xx
lantiq
litex
mediatek pmdomain: mediatek: fix race conditions with genpd 2024-03-01 13:21:47 +01:00
qcom pmdomain: qcom: rpmhpd: Fix enabled_corner aggregation 2024-03-06 14:38:49 +00:00
renesas pmdomain: renesas: r8a77980-sysc: CR7 must be always on 2024-03-01 13:21:48 +01:00
rockchip
samsung
sifive soc: sifive: l2_cache: fix missing of_node_put() in sifive_l2_init() 2023-04-26 13:51:56 +02:00
sunxi
tegra
ti soc: ti: pm33xx: Fix refcount leak in am33xx_pm_probe 2023-05-11 23:00:20 +09:00
ux500 ARM: ux500: do not directly dereference __iomem 2023-01-12 11:58:50 +01:00
versatile
xilinx
Kconfig
Makefile