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

Commit 26da8e64 authored by Ameya Thakur's avatar Ameya Thakur
Browse files

esoc: mdm-4x: Add support for boot done notification



We now return from the power up function only once we recieve a
BOOT_DONE notification from the mdm-helper. This is to ensure
that when we return from power on the esoc is fully accessible
to the client.

Change-Id: I6da8f7461fab33e4a7bde7c05c551deaf5808886
Signed-off-by: default avatarAmeya Thakur <ameyat@codeaurora.org>
parent 1e9cff42
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -465,6 +465,9 @@ static void mdm_notify(enum esoc_notify notify, struct esoc_clink *esoc)
			schedule_delayed_work(&mdm->mdm2ap_status_check_work,
				msecs_to_jiffies(MDM2AP_STATUS_TIMEOUT_MS));
		break;
	case ESOC_BOOT_DONE:
		esoc_clink_evt_notify(ESOC_RUN_STATE, esoc);
		break;
	case ESOC_IMG_XFER_RETRY:
		mdm->init = 1;
		mdm_toggle_soft_reset(mdm);
@@ -547,7 +550,6 @@ static irqreturn_t mdm_status_change(int irq, void *dev_id)
	} else if (value == 1) {
		cancel_delayed_work(&mdm->mdm2ap_status_check_work);
		dev_dbg(dev, "status = 1: mdm is now ready\n");
		esoc_clink_evt_notify(ESOC_RUN_STATE, esoc);
		mdm->ready = true;
		queue_work(mdm->mdm_queue, &mdm->mdm_status_work);
		if (mdm->get_restart_reason)
+1 −0
Original line number Diff line number Diff line
@@ -30,6 +30,7 @@ enum esoc_cmd {

enum esoc_notify {
	ESOC_IMG_XFER_DONE = 1,
	ESOC_BOOT_DONE,
	ESOC_IMG_XFER_RETRY,
	ESOC_IMG_XFER_FAIL,
	ESOC_UPGRADE_AVAILABLE,