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: Ameya Thakur <ameyat@codeaurora.org>
This commit is contained in:
Ameya Thakur 2014-01-24 16:53:41 -08:00
parent 1e9cff42da
commit 26da8e647e
2 changed files with 4 additions and 1 deletions

View File

@ -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)

View File

@ -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,