From: Leandro Lupori <leandro.lupori@eldorado.org.br>
To: "Cédric Le Goater" <clg@kaod.org>,
qemu-devel@nongnu.org, qemu-ppc@nongnu.org
Cc: danielhb413@gmail.com, richard.henderson@linaro.org,
groug@kaod.org, Nicholas Piggin <npiggin@gmail.com>,
pbonzini@redhat.com, alex.bennee@linaro.org,
david@gibson.dropbear.id.au
Subject: Re: [RFC PATCH v3 1/5] ppc64: Add semihosting support
Date: Wed, 20 Apr 2022 14:54:56 -0300 [thread overview]
Message-ID: <92025187-7b4a-f8da-2204-d45160f9d711@eldorado.org.br> (raw)
In-Reply-To: <1d3aaac9-5aa1-9ff9-6b3c-5109ad7f4361@kaod.org>
On 4/18/22 17:22, Cédric Le Goater wrote:
>> diff --git a/semihosting/arm-compat-semi.c
>> b/semihosting/arm-compat-semi.c
>> index 7a51fd0737..e1279c316c 100644
>> --- a/semihosting/arm-compat-semi.c
>> +++ b/semihosting/arm-compat-semi.c
>> @@ -268,6 +268,31 @@ common_semi_sys_exit_extended(CPUState *cs, int nr)
>>
>> #endif
>>
>> +#ifdef TARGET_PPC64
>
> This PPC ifdef in an ARM file seems wrong.
>
> The rest looks OK.
IIUC, arm-compat-semi.c is not an ARM specific file, but it's used by
targets that implement ARM-compatible semihosting. It's currently used
by ARM and RISC-V and both use target ifdefs in small parts of this file.
Thanks,
Leandro
>
> Thanks,
>
> C.
>
>
>> +static inline target_ulong
>> +common_semi_arg(CPUState *cs, int argno)
>> +{
>> + PowerPCCPU *cpu = POWERPC_CPU(cs);
>> + CPUPPCState *env = &cpu->env;
>> + return env->gpr[3 + argno];
>> +}
>> +
>> +static inline void
>> +common_semi_set_ret(CPUState *cs, target_ulong ret)
>> +{
>> + PowerPCCPU *cpu = POWERPC_CPU(cs);
>> + CPUPPCState *env = &cpu->env;
>> + env->gpr[3] = ret;
>> +}
>> +
>> +static inline bool
>> +common_semi_sys_exit_extended(CPUState *cs, int nr)
>> +{
>> + return (nr == TARGET_SYS_EXIT_EXTENDED || sizeof(target_ulong) ==
>> 8);
>> +}
>> +
>> +#endif
>> +
next prev parent reply other threads:[~2022-04-20 17:56 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-18 19:10 [RFC PATCH v3 0/5] Port PPC64/PowerNV MMU tests to QEMU Leandro Lupori
2022-04-18 19:10 ` [RFC PATCH v3 1/5] ppc64: Add semihosting support Leandro Lupori
2022-04-18 20:22 ` Cédric Le Goater
2022-04-20 17:54 ` Leandro Lupori [this message]
2022-04-20 18:18 ` Richard Henderson
2022-04-20 18:38 ` Leandro Lupori
2022-04-20 18:09 ` Leandro Lupori
2022-04-21 2:04 ` Nicholas Piggin
2022-04-21 6:21 ` Cédric Le Goater
2022-04-21 9:56 ` Nicholas Piggin
2022-04-28 3:56 ` Nicholas Piggin
2022-05-03 15:50 ` Fabiano Rosas
2022-05-10 9:41 ` Nicholas Piggin
2022-04-21 6:12 ` Cédric Le Goater
2022-04-18 23:33 ` Richard Henderson
2022-04-19 9:26 ` Peter Maydell
2022-04-20 18:20 ` Leandro Lupori
2022-04-20 19:24 ` Peter Maydell
2022-04-20 18:05 ` Peter Maydell
2022-04-20 18:30 ` Leandro Lupori
2022-04-18 19:10 ` [RFC PATCH v3 2/5] ppc64: Fix semihosting on ppc64le Leandro Lupori
2022-04-18 23:36 ` Richard Henderson
2022-04-20 18:42 ` Leandro Lupori
2022-04-20 19:42 ` Peter Maydell
2022-04-20 19:52 ` Richard Henderson
2022-04-21 8:46 ` Alex Bennée
2022-04-21 9:13 ` Peter Maydell
2022-04-21 9:43 ` Alex Bennée
2022-04-21 10:01 ` Peter Maydell
2022-04-18 19:10 ` [RFC PATCH v3 3/5] tests/tcg/ppc64: Add basic softmmu test support Leandro Lupori
2022-04-18 20:27 ` Cédric Le Goater
2022-04-18 21:52 ` Daniel Henrique Barboza
2022-04-20 18:13 ` Leandro Lupori
2022-04-18 19:10 ` [RFC PATCH v3 4/5] tests/tcg/ppc64: Add MMU test sources Leandro Lupori
2022-04-18 19:11 ` [RFC PATCH v3 5/5] tests/tcg/ppc64: Build PowerNV and LE tests Leandro Lupori
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=92025187-7b4a-f8da-2204-d45160f9d711@eldorado.org.br \
--to=leandro.lupori@eldorado.org.br \
--cc=alex.bennee@linaro.org \
--cc=clg@kaod.org \
--cc=danielhb413@gmail.com \
--cc=david@gibson.dropbear.id.au \
--cc=groug@kaod.org \
--cc=npiggin@gmail.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-ppc@nongnu.org \
--cc=richard.henderson@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.