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

Commit 18b7606c authored by Runmin Wang's avatar Runmin Wang
Browse files

soc: qcom: pil: Set the smem state using mask



smem_state_update_bits takes a mask instead of individual bits, so
convert the bits into a mask before call into the function.

Change-Id: I905f0d841feb8e72e24a91d3e33a482e15bafb25
Signed-off-by: default avatarRunmin Wang <runminw@codeaurora.org>
parent 9df1c7f0
Loading
Loading
Loading
Loading
+5 −3
Original line number Diff line number Diff line
@@ -822,14 +822,15 @@ static int subsys_shutdown(const struct subsys_desc *subsys, bool force_stop)
	if (!subsys_get_crash_status(d->subsys) && force_stop &&
						subsys->state) {
		qcom_smem_state_update_bits(subsys->state,
				subsys->force_stop_bit, 1);
				BIT(subsys->force_stop_bit),
				BIT(subsys->force_stop_bit));
		ret = wait_for_completion_timeout(&d->stop_ack,
				msecs_to_jiffies(STOP_ACK_TIMEOUT_MS));
		if (!ret)
			pr_warn("Timed out on stop ack from %s.\n",
							subsys->name);
		qcom_smem_state_update_bits(subsys->state,
				subsys->force_stop_bit, 0);
				BIT(subsys->force_stop_bit), 0);
	}

	pil_shutdown(&d->desc);
@@ -873,7 +874,8 @@ static void subsys_crash_shutdown(const struct subsys_desc *subsys)

	if (subsys->state && !subsys_get_crash_status(d->subsys)) {
		qcom_smem_state_update_bits(subsys->state,
				subsys->force_stop_bit, 1);
			BIT(subsys->force_stop_bit),
			BIT(subsys->force_stop_bit));
		mdelay(CRASH_STOP_ACK_TO_MS);
	}
}