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

Commit 902ee4a8 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "esoc: mdm-4x: Remove boot and debug timeouts"

parents e23a6878 d2e82524
Loading
Loading
Loading
Loading
+5 −7
Original line number Diff line number Diff line
@@ -407,12 +407,7 @@ static int mdm_cmd_exe(enum esoc_cmd cmd, struct esoc_clink *esoc)
		 * then power down the mdm and switch gpios to booting
		 * config
		 */
		if (!wait_for_completion_timeout(&mdm->debug_done,
				msecs_to_jiffies(mdm->dump_timeout_ms))) {
			dev_err(mdm->dev, "ramdump collection timedout\n");
			mdm->debug = 0;
			return -ETIMEDOUT;
		}
		wait_for_completion(&mdm->debug_done);
		if (mdm->debug_fail) {
			dev_err(mdm->dev, "unable to collect ramdumps\n");
			mdm->debug = 0;
@@ -507,7 +502,10 @@ static void mdm_notify(enum esoc_notify notify, struct esoc_clink *esoc)
		mdm_toggle_soft_reset(mdm);
		break;
	case ESOC_IMG_XFER_FAIL:
		esoc_clink_evt_notify(ESOC_BOOT_FAIL, esoc);
		esoc_clink_evt_notify(ESOC_INVALID_STATE, esoc);
		break;
	case ESOC_BOOT_FAIL:
		esoc_clink_evt_notify(ESOC_INVALID_STATE, esoc);
		break;
	case ESOC_UPGRADE_AVAILABLE:
		break;
+2 −8
Original line number Diff line number Diff line
@@ -27,8 +27,6 @@ enum {
	 PEER_CRASH,
};

#define MDM_BOOT_TIMEOUT	60000L

struct mdm_drv {
	unsigned mode;
	struct esoc_eng cmd_eng;
@@ -59,7 +57,7 @@ static void mdm_handle_clink_evt(enum esoc_evt evt,
{
	struct mdm_drv *mdm_drv = to_mdm_drv(eng);
	switch (evt) {
	case ESOC_BOOT_FAIL:
	case ESOC_INVALID_STATE:
		mdm_drv->boot_fail = true;
		complete(&mdm_drv->boot_done);
		break;
@@ -165,11 +163,7 @@ static int mdm_subsys_powerup(const struct subsys_desc *crashed_subsys)
			return ret;
		}
	}
	if (!wait_for_completion_timeout(&mdm_drv->boot_done,
					msecs_to_jiffies(MDM_BOOT_TIMEOUT))) {
		dev_err(&esoc_clink->dev, "Unable to boot\n");
		return -ETIMEDOUT;
	}
	wait_for_completion(&mdm_drv->boot_done);
	if (mdm_drv->boot_fail) {
		dev_err(&esoc_clink->dev, "booting failed\n");
		return -EIO;
+2 −1
Original line number Diff line number Diff line
@@ -21,7 +21,7 @@ enum esoc_evt {
	ESOC_UNEXPECTED_RESET,
	ESOC_ERR_FATAL,
	ESOC_IN_DEBUG,
	ESOC_BOOT_FAIL,
	ESOC_INVALID_STATE,
};

enum esoc_cmd {
@@ -36,6 +36,7 @@ enum esoc_cmd {
enum esoc_notify {
	ESOC_IMG_XFER_DONE = 1,
	ESOC_BOOT_DONE,
	ESOC_BOOT_FAIL,
	ESOC_IMG_XFER_RETRY,
	ESOC_IMG_XFER_FAIL,
	ESOC_UPGRADE_AVAILABLE,