[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <198e1080c142048ce6c8705a569fe0a0461e3682.camel@buserror.net>
Date: Sat, 04 Jun 2022 20:43:53 -0500
From: Scott Wood <oss@...error.net>
To: Masahiro Yamada <masahiroy@...nel.org>,
Michael Ellerman <mpe@...erman.id.au>,
linuxppc-dev@...ts.ozlabs.org
Cc: Benjamin Herrenschmidt <benh@...nel.crashing.org>,
Paul Mackerras <paulus@...ba.org>,
Christophe Leroy <christophe.leroy@...roup.eu>,
Diana Craciun <diana.craciun@....com>,
Frank Rowand <frank.rowand@...y.com>,
Jason Yan <yanaijie@...wei.com>, Rob Herring <robh@...nel.org>,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH] powerpc: get rid of #include <generated/compile.h>
On Sat, 2022-06-04 at 17:50 +0900, Masahiro Yamada wrote:
> You cannot include <generated/compile.h> here because it is generated
> in init/Makefile but there is no guarantee that it happens before
> arch/powerpc/mm/nohash/kaslr_booke.c is compiled for parallel builds.
>
> The places where you can reliably include <generated/compile.h> are:
>
> - init/ (because init/Makefile can specify the dependency)
> - arch/*/boot/ (because it is compiled after vmlinux)
>
> Commit f231e4333312 ("hexagon: get rid of #include <generated/compile.h>")
> fixed the last breakage at that time, but powerpc re-added this.
>
> <genearated/compile.h> was unneeded because 'build_str' is almost the
> same as 'linux_banner' defined in init/version.c
>
> Let's copy the solution from MIPS.
> (get_random_boot() in arch/mips/kernel/relocate.c)
>
> Fixes: 6a38ea1d7b94 ("powerpc/fsl_booke/32: randomize the kernel image
> offset")
> Signed-off-by: Masahiro Yamada <masahiroy@...nel.org>
> ---
>
> If this gets into the mainline before -rc2 or -rc3,
> I will base my kbuild work on top of this.
>
>
> arch/powerpc/mm/nohash/kaslr_booke.c | 8 ++------
> 1 file changed, 2 insertions(+), 6 deletions(-)
Acked-by: Scott Wood <oss@...error.net>
-Scott
Powered by blists - more mailing lists