bus: mhi: ep: Save channel state locally during suspend and resume
authorManivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Wed, 28 Dec 2022 16:17:04 +0000 (21:47 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 10 Mar 2023 08:34:31 +0000 (09:34 +0100)
commit01836e56fdd207e9c47f8839a969cbb597d5fb80
tree12c7959a6a72db4fb2b3dc99f1df65c2e579586c
parent69cc38576293507668ad7f936c2b5f5a37fbbbf5
bus: mhi: ep: Save channel state locally during suspend and resume

commit 8a1c24bb908f9ecbc4be0fea014df67d43161551 upstream.

During suspend and resume, the channel state needs to be saved locally.
Otherwise, the endpoint may access the channels while they were being
suspended and causing access violations.

Fix it by saving the channel state locally during suspend and resume.

Cc: <stable@vger.kernel.org> # 5.19
Fixes: e4b7b5f0f30a ("bus: mhi: ep: Add support for suspending and resuming channels")
Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Reviewed-by: Jeffrey Hugo <quic_jhugo@quicinc.com)
Link: https://lore.kernel.org/r/20221228161704.255268-7-manivannan.sadhasivam@linaro.org
Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/bus/mhi/ep/main.c