Re: [PATCH] sh: fix fallout from ZERO_PAGE consolidation
John Paul Adrian Glaubitz <[email protected]>
| Newsgroups | gmane.linux.ports.sh.devel,gmane.linux.kernel |
|---|---|
| Message-ID | <ef7d133aabff5ce58a91f0274f3ed05947c8aa48.camel@physik.fu-berlin.de> |
Hi Mike, On Fri, 2026-04-17 at 12:56 +0200, John Paul Adrian Glaubitz wrote: > On Fri, 2026-04-17 at 13:32 +0300, Mike Rapoport wrote: > > From: "Mike Rapoport (Microsoft)" <[email protected]> > > > > Consolidation of empty_zero_page declarations broke boot on sh. > > > > sh stores its initial boot parameters in a page reserved in > > arch/sh/kernel/head_32.S. Before commit 6215d9f4470f ("arch, mm: > > consolidate empty_zero_page") this page was referenced in C code as an > > array and after that commit it is referenced as a pointer. > > > > This causes wrong code generation and boot hang. > > > > Declare boot_params_page as an array to fix the issue. > > > > Reported-by: Thomas Weißschuh <[email protected]> > > Tested-by: Thomas Weißschuh <[email protected]> > > Fixes: 6215d9f4470f ("arch, mm: consolidate empty_zero_page") > > Signed-off-by: Mike Rapoport (Microsoft) <[email protected]> > > --- > > arch/sh/include/asm/setup.h | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/arch/sh/include/asm/setup.h b/arch/sh/include/asm/setup.h > > index 63c9efc06348..8488f76b48b4 100644 > > --- a/arch/sh/include/asm/setup.h > > +++ b/arch/sh/include/asm/setup.h > > @@ -7,7 +7,7 @@ > > /* > > * This is set up by the setup-routine at boot-time > > */ > > -extern unsigned char *boot_params_page; > > +extern unsigned char boot_params_page[]; > > #define PARAM boot_params_page > > > > #define MOUNT_ROOT_RDONLY (*(unsigned long *) (PARAM+0x000)) > > > > base-commit: 43cfbdda5af60ffc6272a7b8c5c37d1d0a181ca9 > > Thanks, I'll try to test this patch this weekend and will pick it up for v7.1. > I have already collected a number of patches for v7.1 with my Reviewed-by. I just realized that this patch actually depends on 6215d9f4470f ("arch, mm: consolidate empty_zero_page"), so I cannot take it directly into my tree now. Shall we wait for v7.0-rc1 then, so I can pick it up as a regression fix? Thanks, Adrian -- .''`. John Paul Adrian Glaubitz : :' : Debian Developer `. `' Physicist `- GPG: 62FF 8A75 84E0 2956 9546 0006 7426 3B37 F5B5 F913