https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86673
--- Comment #13 from Arnd Bergmann <arnd at linaro dot org> --- (In reply to Andreas Schwab from comment #12) > arch/h8300/kernel/sim-console.c: register const int fd __asm__("er0") = > 1; I found that too, and then noticed it is already fixed in linux-next: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=14cf9451be78f8a Ard points out that most of the other ones are pointers to const data, which are not a problem. This leaves the arm put_user bug as the only definite problem that needs to be addressed in older kernels. The three arch/riscv instances of 'const register unsigned long gp __asm__ ("gp")' are different because they are never passed into an inline assembly as far as I can tell. This seems to be unsupported for local register variables according to the gcc documentation, but if that's a problem, it's unrelated to this bug.