OpenCloudOS-Kernel/drivers/soc/ti
Dave Gerlach 03729cfa0d soc: ti: wkup_m3_ipc: Fix race condition with rproc_boot
Any user of wkup_m3_ipc calls wkup_m3_ipc_get to get a handle and this
checks the value of the static variable m3_ipc_state to see if the
wkup_m3 is ready. Currently this is populated during probe before
rproc_boot has been called, meaning there is a window of time that
wkup_m3_ipc_get can return a valid handle but the wkup_m3 itself is not
ready, leading to invalid IPC calls to the wkup_m3 and system
instability.

To avoid this, move the population of the m3_ipc_state variable until
after rproc_boot has succeeded to guarantee a valid and usable handle
is always returned.

Reported-by: Suman Anna <s-anna@ti.com>
Signed-off-by: Dave Gerlach <d-gerlach@ti.com>
Acked-by: Santosh Shilimkar <ssantosh@kernel.org>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2019-12-17 15:18:36 -08:00
..
Kconfig ARM: Device-tree updates 2019-07-19 17:19:24 -07:00
Makefile soc: ti: add initial PRM driver with reset control support 2019-10-09 08:55:36 -07:00
knav_dma.c soc: ti: knav_dma: Use proper enum in pktdma_init_chan 2019-01-30 10:22:17 -08:00
knav_qmss.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 174 2019-05-30 11:26:41 -07:00
knav_qmss_acc.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 174 2019-05-30 11:26:41 -07:00
knav_qmss_queue.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 174 2019-05-30 11:26:41 -07:00
omap_prm.c soc: ti: omap-prm: fix return value check in omap_prm_probe() 2019-10-29 09:57:56 -07:00
pm33xx.c soc: ti: pm33xx: Make two symbols static 2019-08-13 05:05:38 -07:00
ti_sci_inta_msi.c soc: ti: Add MSI domain bus support for Interrupt Aggregator 2019-05-01 10:49:17 +01:00
ti_sci_pm_domains.c soc: ti: ti_sci_pm_domains: Add support for exclusive and shared access 2019-09-04 20:44:35 +02:00
wkup_m3_ipc.c soc: ti: wkup_m3_ipc: Fix race condition with rproc_boot 2019-12-17 15:18:36 -08:00