[PATCH 07/29] target/arm/tcg/psci.c: make compilation unit common

Pierrick Bouvier posted 29 patches 1 month ago
Maintainers: Richard Henderson <richard.henderson@linaro.org>, Paolo Bonzini <pbonzini@redhat.com>, "Alex Bennée" <alex.bennee@linaro.org>, "Philippe Mathieu-Daudé" <philmd@linaro.org>, Peter Maydell <peter.maydell@linaro.org>, Michael Rolnik <mrolnik@gmail.com>, Brian Cain <brian.cain@oss.qualcomm.com>, Helge Deller <deller@gmx.de>, Zhao Liu <zhao1.liu@intel.com>, Eduardo Habkost <eduardo@habkost.net>, Song Gao <gaosong@loongson.cn>, Laurent Vivier <laurent@vivier.eu>, "Edgar E. Iglesias" <edgar.iglesias@gmail.com>, Aurelien Jarno <aurelien@aurel32.net>, Jiaxun Yang <jiaxun.yang@flygoat.com>, Aleksandar Rikalo <arikalo@gmail.com>, Stafford Horne <shorne@gmail.com>, Nicholas Piggin <npiggin@gmail.com>, Chinmay Rath <rathc@linux.ibm.com>, Palmer Dabbelt <palmer@dabbelt.com>, Alistair Francis <alistair.francis@wdc.com>, Weiwei Li <liwei1518@gmail.com>, Daniel Henrique Barboza <dbarboza@ventanamicro.com>, Liu Zhiwei <zhiwei_liu@linux.alibaba.com>, Yoshinori Sato <yoshinori.sato@nifty.com>, Ilya Leoshkevich <iii@linux.ibm.com>, David Hildenbrand <david@kernel.org>, Thomas Huth <thuth@redhat.com>, Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>, Artyom Tarasenko <atar4qemu@gmail.com>, Bastian Koppelmann <kbastian@rumtueddeln.de>, Max Filippov <jcmvbkbc@gmail.com>
There is a newer version of this series
[PATCH 07/29] target/arm/tcg/psci.c: make compilation unit common
Posted by Pierrick Bouvier 1 month ago
Now that helper.h does not contain TARGET_AARCH64 identifier, we can
move forward with this file.

Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
---
 target/arm/tcg/psci.c      | 2 +-
 target/arm/tcg/meson.build | 5 +----
 2 files changed, 2 insertions(+), 5 deletions(-)

diff --git a/target/arm/tcg/psci.c b/target/arm/tcg/psci.c
index 2d409301578..fc23d62ed94 100644
--- a/target/arm/tcg/psci.c
+++ b/target/arm/tcg/psci.c
@@ -68,7 +68,7 @@ void arm_handle_psci_call(ARMCPU *cpu)
     CPUARMState *env = &cpu->env;
     uint64_t param[4];
     uint64_t context_id, mpidr;
-    target_ulong entry;
+    uint64_t entry;
     int32_t ret = 0;
     int i;
 
diff --git a/target/arm/tcg/meson.build b/target/arm/tcg/meson.build
index 1b115656c46..144a8cd9474 100644
--- a/target/arm/tcg/meson.build
+++ b/target/arm/tcg/meson.build
@@ -49,10 +49,6 @@ arm_ss.add(when: 'TARGET_AARCH64', if_true: files(
   'sve_helper.c',
 ))
 
-arm_system_ss.add(files(
-  'psci.c',
-))
-
 arm_system_ss.add(when: 'CONFIG_ARM_V7M', if_true: files('cpu-v7m.c'))
 arm_user_ss.add(when: 'TARGET_AARCH64', if_false: files('cpu-v7m.c'))
 
@@ -67,6 +63,7 @@ arm_common_system_ss.add(files(
   'cpregs-at.c',
   'hflags.c',
   'neon_helper.c',
+  'psci.c',
   'tlb_helper.c',
   'tlb-insns.c',
   'vfp_helper.c',
-- 
2.47.3
Re: [PATCH 07/29] target/arm/tcg/psci.c: make compilation unit common
Posted by Richard Henderson 1 month ago
On 1/9/26 16:31, Pierrick Bouvier wrote:
> Now that helper.h does not contain TARGET_AARCH64 identifier, we can
> move forward with this file.
> 
> Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
> ---
>   target/arm/tcg/psci.c      | 2 +-
>   target/arm/tcg/meson.build | 5 +----
>   2 files changed, 2 insertions(+), 5 deletions(-)

Since this is just concerns helper_wfi, it might be more appropriate to split out an 
arm_wfi() function rather than involving tcg.


r~
Re: [PATCH 07/29] target/arm/tcg/psci.c: make compilation unit common
Posted by Richard Henderson 1 month ago
On 1/9/26 16:31, Pierrick Bouvier wrote:
> Now that helper.h does not contain TARGET_AARCH64 identifier, we can
> move forward with this file.
> 
> Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
> ---
>   target/arm/tcg/psci.c      | 2 +-
>   target/arm/tcg/meson.build | 5 +----
>   2 files changed, 2 insertions(+), 5 deletions(-)
> 
> diff --git a/target/arm/tcg/psci.c b/target/arm/tcg/psci.c
> index 2d409301578..fc23d62ed94 100644
> --- a/target/arm/tcg/psci.c
> +++ b/target/arm/tcg/psci.c
> @@ -68,7 +68,7 @@ void arm_handle_psci_call(ARMCPU *cpu)
>       CPUARMState *env = &cpu->env;
>       uint64_t param[4];
>       uint64_t context_id, mpidr;
> -    target_ulong entry;
> +    uint64_t entry;
>       int32_t ret = 0;
>       int i;

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>

r~

>   
> diff --git a/target/arm/tcg/meson.build b/target/arm/tcg/meson.build
> index 1b115656c46..144a8cd9474 100644
> --- a/target/arm/tcg/meson.build
> +++ b/target/arm/tcg/meson.build
> @@ -49,10 +49,6 @@ arm_ss.add(when: 'TARGET_AARCH64', if_true: files(
>     'sve_helper.c',
>   ))
>   
> -arm_system_ss.add(files(
> -  'psci.c',
> -))
> -
>   arm_system_ss.add(when: 'CONFIG_ARM_V7M', if_true: files('cpu-v7m.c'))
>   arm_user_ss.add(when: 'TARGET_AARCH64', if_false: files('cpu-v7m.c'))
>   
> @@ -67,6 +63,7 @@ arm_common_system_ss.add(files(
>     'cpregs-at.c',
>     'hflags.c',
>     'neon_helper.c',
> +  'psci.c',
>     'tlb_helper.c',
>     'tlb-insns.c',
>     'vfp_helper.c',
Re: [PATCH 07/29] target/arm/tcg/psci.c: make compilation unit common
Posted by Philippe Mathieu-Daudé 1 month ago
On 9/1/26 06:31, Pierrick Bouvier wrote:
> Now that helper.h does not contain TARGET_AARCH64 identifier, we can
> move forward with this file.
> 
> Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
> ---
>   target/arm/tcg/psci.c      | 2 +-
>   target/arm/tcg/meson.build | 5 +----
>   2 files changed, 2 insertions(+), 5 deletions(-)

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>