linux-stable/drivers/bus
Bhaumik Bhatt ce16274a6b bus: mhi: host: Add spinlock to protect WP access when queueing TREs
commit b89b6a863d upstream.

Protect WP accesses such that multiple threads queueing buffers for
incoming data do not race.

Meanwhile, if CONFIG_TRACE_IRQFLAGS is enabled, irq will be enabled once
__local_bh_enable_ip is called as part of write_unlock_bh. Hence, let's
take irqsave lock after TRE is generated to avoid running write_unlock_bh
when irqsave lock is held.

Cc: stable@vger.kernel.org
Fixes: 189ff97cca ("bus: mhi: core: Add support for data transfer")
Signed-off-by: Bhaumik Bhatt <bbhatt@codeaurora.org>
Signed-off-by: Qiang Yu <quic_qianyu@quicinc.com>
Reviewed-by: Jeffrey Hugo <quic_jhugo@quicinc.com>
Tested-by: Jeffrey Hugo <quic_jhugo@quicinc.com>
Reviewed-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Link: https://lore.kernel.org/r/1702276972-41296-2-git-send-email-quic_qianyu@quicinc.com
Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-01-31 16:18:52 -08:00
..
fsl-mc ARM: SoC cleanups for 6.6 2023-08-30 16:49:40 -07:00
mhi bus: mhi: host: Add spinlock to protect WP access when queueing TREs 2024-01-31 16:18:52 -08:00
arm-cci.c
arm-integrator-lm.c bus: arm-integrator-lm: remove MODULE_LICENSE in non-modules 2023-04-13 13:13:50 -07:00
brcmstb_gisb.c bus: brcmstb_gisb: Use devm_platform_get_and_ioremap_resource() 2023-03-14 14:07:16 -07:00
bt1-apb.c bus: remove MODULE_LICENSE in non-modules 2023-04-13 13:13:53 -07:00
bt1-axi.c bus: remove MODULE_LICENSE in non-modules 2023-04-13 13:13:53 -07:00
da8xx-mstpri.c
hisi_lpc.c bus: Explicitly include correct DT includes 2023-08-12 10:31:01 +02:00
imx-weim.c bus: imx-weim: use devm_platform_ioremap_resource 2023-07-19 10:14:11 +08:00
intel-ixp4xx-eb.c bus: ixp4xx: fix IXP4XX_EXP_T1_MASK 2023-07-05 22:22:55 +02:00
Kconfig bus: ti-sysc: Build driver for TI K3 SoCs 2023-08-10 09:21:45 +03:00
Makefile bus: add driver for initializing the SSC bus on (some) qcom SoCs 2022-04-19 13:03:57 -05:00
mips_cdmm.c driver core: make struct bus_type.uevent() take a const * 2023-01-27 13:45:52 +01:00
moxtet.c bus: moxtet: Add spi device table 2024-01-20 11:51:47 +01:00
mvebu-mbus.c bus: mvebu-mbus: Remove open coded "ranges" parsing 2023-04-18 11:18:24 -05:00
omap-ocp2scp.c
omap_l3_noc.c treewide: Replace GPLv2 boilerplate/reference with SPDX - gpl-2.0_320.RULE 2022-06-10 14:51:36 +02:00
omap_l3_noc.h treewide: Replace GPLv2 boilerplate/reference with SPDX - gpl-2.0_320.RULE 2022-06-10 14:51:36 +02:00
omap_l3_smx.c ARM: SoC cleanups for 6.6 2023-08-30 16:49:40 -07:00
omap_l3_smx.h
qcom-ebi2.c bus: qcom: remove MODULE_LICENSE in non-modules 2023-04-13 13:13:50 -07:00
qcom-ssc-block-bus.c bus: remove MODULE_LICENSE in non-modules 2023-04-13 13:13:50 -07:00
simple-pm-bus.c bus: Explicitly include correct DT includes 2023-08-12 10:31:01 +02:00
sun50i-de2.c bus: sun50i-de2: Adjust printing error message 2021-10-13 14:48:48 +02:00
sunxi-rsb.c ARM: SoC cleanups for 6.6 2023-08-30 16:49:40 -07:00
tegra-aconnect.c
tegra-gmi.c bus: tegra-gmi: Convert to devm_platform_ioremap_resource() 2023-07-21 17:27:33 +02:00
ti-pwmss.c bus: Explicitly include correct DT includes 2023-08-12 10:31:01 +02:00
ti-sysc.c bus: ti-sysc: Flush posted write only after srst_udelay 2024-01-01 12:42:46 +00:00
ts-nbus.c treewide: Replace GPLv2 boilerplate/reference with SPDX - gpl-2.0_56.RULE (part 2) 2022-06-10 14:51:35 +02:00
uniphier-system-bus.c bus: uniphier-system-bus: Remove open coded "ranges" parsing 2023-03-30 13:37:21 -05:00
vexpress-config.c bus: vexpress-config: Convert to devm_platform_ioremap_resource() 2023-07-13 14:38:44 +01:00