From: Andrew Jones Subject: [PATCH kvm-unit-tests 3/3] arm/arm64: psci: avoid calling halt directly Date: Mon, 29 May 2017 15:58:04 +0200 Message-ID: <20170529135804.22891-4-drjones@redhat.com> References: <20170529135804.22891-1-drjones@redhat.com> Cc: rkrcmar@redhat.com To: kvm@vger.kernel.org, pbonzini@redhat.com Return-path: Received: from mx1.redhat.com ([209.132.183.28]:55628 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751146AbdE2N6M (ORCPT ); Mon, 29 May 2017 09:58:12 -0400 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id B79E517AC58 for ; Mon, 29 May 2017 13:58:11 +0000 (UTC) In-Reply-To: <20170529135804.22891-1-drjones@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: Eventually we'll allow calling functions on cpus more than once, to allow multiple subtests to run in a single execution. But that'll only work if the subtests don't halt the cpus... Signed-off-by: Andrew Jones --- arm/psci.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/arm/psci.c b/arm/psci.c index f1004339b30f..4e6bc58dbe42 100644 --- a/arm/psci.c +++ b/arm/psci.c @@ -78,9 +78,8 @@ static void cpu_on_secondary_entry(void) cpumask_set_cpu(cpu, &cpu_on_ready); while (!cpu_on_start) cpu_relax(); - cpu_on_ret[cpu] = psci_cpu_on(cpus[1], __pa(halt)); + cpu_on_ret[cpu] = psci_cpu_on(cpus[1], __pa(cpu_psci_cpu_die)); cpumask_set_cpu(cpu, &cpu_on_done); - halt(); } static bool psci_cpu_on_test(void) @@ -104,7 +103,7 @@ static bool psci_cpu_on_test(void) cpu_on_start = 1; smp_mb(); - cpu_on_ret[0] = psci_cpu_on(cpus[1], __pa(halt)); + cpu_on_ret[0] = psci_cpu_on(cpus[1], __pa(cpu_psci_cpu_die)); cpumask_set_cpu(0, &cpu_on_done); while (!cpumask_full(&cpu_on_done)) -- 2.9.4