Thread (5 messages) 5 messages, 4 authors, 2024-01-09

Re: [PATCH] powerpc/ps3_defconfig: Disable PPC64_BIG_ENDIAN_ELF_ABI_V2

From: Geoff Levand <geoff@infradead.org>
Date: 2023-12-27 09:45:43

Hi Michael,

On 12/27/23 10:27, Michael Ellerman wrote:
Geoff Levand [off-list ref] writes:
quoted
Commit 8c5fa3b5c4df3d071dab42b04b971df370d99354 (powerpc/64: Make ELFv2 the
default for big-endian builds), merged in Linux-6.5-rc1 changes the calling ABI
in a way that is incompatible with the current code for the PS3's LV1 hypervisor
calls.
I'll take this for now.

But medium term we would like to switch to only using ELFv2, so it would
be good if we can work out what the actual problem is.
I've been looking into converting the LV1 hypercalls to v2.
quoted
This change just adds the line '# CONFIG_PPC64_BIG_ENDIAN_ELF_ABI_V2 is not set'
to the ps3_defconfig file so that the PPC64_ELF_ABI_V1 is used.

Fixes run time errors like these:

	BUG: Kernel NULL pointer dereference at 0x00000000
	Faulting instruction address: 0xc000000000047cf0
	Oops: Kernel access of bad area, sig: 11 [#1]

	Call Trace:
	[c0000000023039e0] [c00000000100ebfc] ps3_create_spu+0xc4/0x2b0 (unreliable)
	[c000000002303ab0] [c00000000100d4c4] create_spu+0xcc/0x3c4
	[c000000002303b40] [c00000000100eae4] ps3_enumerate_spus+0xa4/0xf8
That can't be the first hvcall we've done, there's one in
ps3_setup_arch(). So I guess only some hcalls are failing?
I guess because ps3_create_spu has 7 input parameters and returns
6 parameters, so it hits some difference between V1 and V2 that
the other LV1 calls up to that point have not hit.

-Geoff
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help