qemu-ppc
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH for-5.0?] linux-user/ppc: Fix padding in mcontext_t for ppc64


From: David Gibson
Subject: Re: [PATCH for-5.0?] linux-user/ppc: Fix padding in mcontext_t for ppc64
Date: Wed, 8 Apr 2020 12:10:06 +1000

On Mon, Apr 06, 2020 at 08:21:05PM -0700, Richard Henderson wrote:
> The padding that was added in 95cda4c44ee was added to a union,
> and so it had no effect.  This fixes misalignment errors detected
> by clang sanitizers for ppc64 and ppc64le.
> 
> In addition, only ppc64 allocates space for VSX registers, so do
> not save them for ppc32.  The kernel only has references to
> CONFIG_SPE in signal_32.c, so do not attempt to save them for ppc64.
> 
> Fixes: 95cda4c44ee
> Signed-off-by: Richard Henderson <address@hidden>

Applied to ppc-for-5.0, thanks.

> ---
> 
> Note that ppc64abi32 is *not* fixed by this patch.  It looks to
> me that all of the defined(TARGET_PPC64) tests in this file are
> incorrect, and that we should instead be testing TARGET_ABI_BITS
> vs 32/64.  In addition, virtually all of the target_ulong structure
> members would need to be abi_ulong.
> 
> Should we in fact disable ppc64abi32?
> I can't see how it could work enough to be useful as-is.

Yeah, I think so.  Last time we had a problem in this area, I couldn't
even figure out what ppc64abi32 was supposed to *be*, let alone what
the use case for it is.  Given that, it's hard to imagine it's been
working (whatever that means) any time recently.

-- 
David Gibson                    | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au  | minimalist, thank you.  NOT _the_ _other_
                                | _way_ _around_!
http://www.ozlabs.org/~dgibson

Attachment: signature.asc
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]