From: Christophe Leroy <christophe.leroy@csgroup.eu>
To: Mike <michael.heltne@gmail.com>
Cc: "linuxppc-dev@lists.ozlabs.org" <linuxppc-dev@lists.ozlabs.org>
Subject: Re: [5.16.0] build error on unrecognized opcode: ptesync
Date: Tue, 11 Jan 2022 09:51:29 +0000 [thread overview]
Message-ID: <3b039cad-be82-3376-144c-bdee09c7adbf@csgroup.eu> (raw)
In-Reply-To: <CANtoAtOVjnvvti1rnrwpR9ybvpQJzjq48tdQbhsqJWncgoTmbw@mail.gmail.com>
Le 11/01/2022 à 10:32, Mike a écrit :
> I managed to fix it in the end, patch attached, though i should have
> done a $(call cc-option-, -maltivec, -mabi=altivec) in the
> arch/powerpc/mm/Makefile
> I wrongly assumed that the manual i had downloaded at 4.44am was for
> 32bit ppc only and found ptesync to be ppc64 only.
>
> binutils-2.37.50 - GNU assembler version 2.37.50 (powerpc-linux-gnu)
> using BFD version (GNU Binutils for Debian) 2.37.50.20220106
> gcc version 11.2.0 (Debian 11.2.0-13)
> ld.lld is missing but with LLVM/CLANG and LD=ld.bfd
> arch/powerpc/kernel/vdso32/gettimeofday.S:72:8:
> error: unsupported directive '.stabs' .stabs
> "_restgpr_31_x:F-1",36,0,0,_restgpr_31_x; .globl _restgpr_31_x;
> _restgpr_31_x:
>
> Attached the config i'm using, and the debian config 5.15.0-2. It's
> still building.
Ok, I tried with your config on my Fedora Core 35 where I have:
powerpc64-linux-gnu-gcc (GCC) 11.2.1 20210728 (Red Hat Cross 11.2.1-1)
GNU ld version 2.37-3.fc35
From packages:
- binutils-powerpc64-linux-gnu-2.37-3.fc35.x86_64
- gcc-powerpc64-linux-gnu-11.2.1-1.fc35.x86_64
And I don't have the problems you mention, so it must be something
special with Debian GCC.
Your change regarding ptesync is probably OK but is fragile I think,
because for instance there is also a 'ptesync' in
arch/powerpc/mm/pageattr.c and probably many other places.
Also please prefer CONFIG_PPC64 to __powerpc64__
Regarding the DSSALL issue, the following commit will probably help:
d51f86cfd8e3 ("powerpc/mm: Switch obsolete dssall to .long")
Regarding the .stabs with LLVM there is a patch at
https://patchwork.ozlabs.org/project/linuxppc-dev/patch/68932ec2ba6b868d35006b96e90f0890f3da3c05.1638273868.git.christophe.leroy@csgroup.eu/
Thanks
Christophe
>
> Cheers
> Michael
>
> On Tue, 11 Jan 2022 at 07:20, Christophe Leroy
> <christophe.leroy@csgroup.eu> wrote:
>>
>>
>>
>> Le 10/01/2022 à 13:32, Mike a écrit :
>>> Hey, so I originally sat down to compile the fast headers V2 patch, but
>>> quickly discovered other things at play, and grabbed 5.16.0 a few hours
>>> after it lifted off, arch/powerpc/mm/mmu_context.c I had to
>>> specifically say had to include -maltivec or it barfed on a 'dssall',
>>> I'm fine with that, I've spent years in kernel land, I can deal with
>>> that, then came arch/powerpc/lib/step.c with the ptesync. This seems
>>> like a totally normal instruction that shouldn't need any extra flags or
>>> anything, yet the assembler throws up, and no flag I can think of fixes
>>> it. This is a G4 7447. I reverted back to the Debian 5.15. defconfig
>>> before dropping this mail as I had tweaked my config to be more G4.
>>>
>>
>> Hi Mike,
>>
>> Can you provide a bit more details about your setup and config ?
>>
>> Are you using GCC or LLVM ?
>> What version of GCC and BINUTILS or what version of LLVM ?
>>
>> What is DEBIAN defconfig ? Does it correspond to one of the standard
>> mainline kernel defconfigs ? If not can you provide it ?
>>
>> Thanks
>> Christophe
next prev parent reply other threads:[~2022-01-11 9:52 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-10 12:32 [5.16.0] build error on unrecognized opcode: ptesync Mike
2022-01-11 6:20 ` Christophe Leroy
2022-01-11 9:32 ` Mike
2022-01-11 9:51 ` Christophe Leroy [this message]
2022-01-13 3:12 ` Mike
2022-01-17 11:20 ` Mike
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=3b039cad-be82-3376-144c-bdee09c7adbf@csgroup.eu \
--to=christophe.leroy@csgroup.eu \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=michael.heltne@gmail.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).