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

Commit 1e83ee33 authored by Michael Scott's avatar Michael Scott Committed by Greg Kroah-Hartman
Browse files

greybus: arche-platform: assert wake-detect to complete WAKE_OUT event



After SVC generates WAKE_OUT (pulling wake-detect pin low) and APB is
brought out of reset, we need to assert wake-detect again to complete
SVC WAKE_OUT logic.

Testing Done:
- Used for DB3.5/EVT1.5 hardware during bringup
- Regression tested on DB3.1+ES2, DB3.1+ES3

Signed-off-by: default avatarMichael Scott <michael.scott@linaro.org>
Reviewed-by: default avatarVaibhav Hiremath <vaibhav.hiremath@linaro.org>
Tested-by: default avatarVaibhav Hiremath <vaibhav.hiremath@linaro.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@google.com>
parent 9e1aef82
Loading
Loading
Loading
Loading
+4 −2
Original line number Original line Diff line number Diff line
@@ -79,10 +79,12 @@ static void svc_delayed_work(struct work_struct *work)


	if (timeout >= 0) {
	if (timeout >= 0) {
		ret = of_platform_populate(np, NULL, NULL, dev);
		ret = of_platform_populate(np, NULL, NULL, dev);
		if (!ret)
		if (!ret) {
			/* Should we set wake_detect gpio to output again? */
			/* re-assert wake_detect to confirm SVC WAKE_OUT */
			gpio_direction_output(arche_pdata->wake_detect_gpio, 1);
			return;
			return;
		}
		}
	}


	/* FIXME: We may want to limit retries here */
	/* FIXME: We may want to limit retries here */
	gpio_direction_output(arche_pdata->wake_detect_gpio, 0);
	gpio_direction_output(arche_pdata->wake_detect_gpio, 0);