Re: [REGRESSION] 32-bit ARM's BKPT instruction no longer works

Linus Walleij <[email protected]> Tue, 23 Jun 2026 15:35:05 +0200
Newsgroups dev.linux.lists.regressions,org.kernel.vger.linux-kernel,org.kernel.vger.stable
Message-ID <CAD++jL=C0mnn-PCqZB4zg7y1=u-W4mEOt+NR3OQFzpdwSR-9Og@mail.gmail.com>
On Tue, Jun 23, 2026 at 11:48 AM Russell King <[email protected]> wrote:

> Let me also be clear: I expect Linus W to fix this

I'll try!

I guess the offending commit is:
commit c3f89986fde7bb9ccc86a901bf28e1f7d69fc3b3
"ARM: 9391/2: hw_breakpoint: Handle CFI breakpoints"

> I suspect that the CFI fault code was a decision by compiler authors,
> but I can't say because I don't have a setup that generates the code
> for CFI.

Yep, the LLVM implementers chose breakpoint code 0x03:
I think it comes from here:
https://llvm.org/doxygen/ARMAsmPrinter_8cpp_source.html
Line 1536-37:
unsigned AddrIndex = TRI->getEncodingValue(AddrReg);
unsigned ESR = 0x8000 | (31 << 5) | (AddrIndex & 31);

Yours,
Linus Walleij