Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit cbe5a149 authored by Jeff Hugo's avatar Jeff Hugo
Browse files

soc: qcom: glink_smd_xprt: Sync probe wait status with close



A closed channel is no longer waiting on the probe of the underlying SMD
pipe.  The probe wait status is not updated when the channel is closed
which can lead to the wrong code path being executed if the probe occurs.

Sync the probe wait status of the channel with the close status of the
channel so that the correct code path is run if the probe were to occur
after channel close.

CRs-Fixed: 844123
Change-Id: I3916d36881a9468af3f1a879ccde4ac2f10bce2b
Signed-off-by: default avatarJeffrey Hugo <jhugo@codeaurora.org>
parent bb17b318
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -765,6 +765,7 @@ static void smd_data_ch_close(struct channel *ch)
	SMDXPRT_INFO("%s Closing SMD channel lcid %u\n", __func__, ch->lcid);

	ch->is_closing = true;
	ch->wait_for_probe = false;
	flush_workqueue(ch->wq);

	if (ch->smd_ch) {
@@ -1280,6 +1281,7 @@ static int ssr(struct glink_transport_if *if_ptr)
		if (!ch->smd_ch)
			continue;
		ch->is_closing = true;
		ch->wait_for_probe = false;
		flush_workqueue(ch->wq);
		smd_close(ch->smd_ch);
		ch->smd_ch = NULL;