1 From 341844c7e06afccd64261719fa388339a589b0a4 Mon Sep 17 00:00:00 2001
2 From: Felix Fietkau <nbd@nbd.name>
3 Date: Sun, 22 Jul 2018 12:53:04 +0200
4 Subject: [PATCH] soc: qcom: spm: add SCM probe dependency
6 Check for SCM availability before attempting to use SPM. SPM probe will
9 Signed-off-by: Felix Fietkau <nbd@nbd.name>
10 Signed-off-by: John Crispin <john@phrozen.org>
12 drivers/soc/qcom/spm.c | 3 +++
13 1 file changed, 3 insertions(+)
15 --- a/drivers/soc/qcom/spm.c
16 +++ b/drivers/soc/qcom/spm.c
17 @@ -219,6 +219,9 @@ static int __init qcom_cpuidle_init(stru
19 bool use_scm_power_down = false;
21 + if (!qcom_scm_is_available())
22 + return -EPROBE_DEFER;
25 state_node = of_parse_phandle(cpu_node, "cpu-idle-states", i);