[2/2] drivers: firmware: psci: checker: Use psci_is_available()
diff mbox

Message ID 1507708982-12336-3-git-send-email-geert+renesas@glider.be
State Under Review
Delegated to: Geert Uytterhoeven
Headers show

Commit Message

Geert Uytterhoeven Oct. 11, 2017, 8:03 a.m. UTC
Use the psci_is_available() helper instead of direct accesses to
psci_ops internals.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
 drivers/firmware/psci_checker.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch
diff mbox

diff --git a/drivers/firmware/psci_checker.c b/drivers/firmware/psci_checker.c
index 6523ce9628659755..72b40ed2dcce7cf4 100644
--- a/drivers/firmware/psci_checker.c
+++ b/drivers/firmware/psci_checker.c
@@ -54,7 +54,7 @@  static int psci_ops_check(void)
 	int migrate_type = -1;
 	int cpu;
 
-	if (!(psci_ops.cpu_off && psci_ops.cpu_on && psci_ops.cpu_suspend)) {
+	if (!psci_is_available()) {
 		pr_warn("Missing PSCI operations, aborting tests\n");
 		return -EOPNOTSUPP;
 	}