From: Tom Rini Date: Fri, 28 Jul 2017 10:33:14 -0400 Subject: [U-Boot] [PATCH][v2] ARMv8/sec_firmware : Update chosen/kaslr-seed with random number In-Reply-To: <1501259592-21298-1-git-send-email-ruchika.gupta@nxp.com> References: <1501259592-21298-1-git-send-email-ruchika.gupta@nxp.com> Message-ID: <20170728143314.GO26163@bill-the-cat> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Fri, Jul 28, 2017 at 10:03:12PM +0530, Ruchika Gupta wrote: > kASLR support in kernel requires a random number to be passed via > chosen/kaslr-seed propert. sec_firmware generates this random seed > which can then be passed in the device tree node. > > sec_firmware reserves JR3 for it's own usage. Node for JR3 is > removed from device-tree. > > Signed-off-by: Ruchika Gupta > --- > Changes from v1 > - Extra spaces removed from the patch > - Support added for LSCH3 devices in the patch > - of calls replaced with fdt calls to remove compilation error with latest uboot > > arch/arm/cpu/armv8/fsl-layerscape/fdt.c | 75 +++++++++++++++++++++++++++++-- > arch/arm/cpu/armv8/sec_firmware.c | 53 ++++++++++++++++++++++ > arch/arm/include/asm/armv8/sec_firmware.h | 8 ++++ > 3 files changed, 133 insertions(+), 3 deletions(-) > > diff --git a/arch/arm/cpu/armv8/fsl-layerscape/fdt.c b/arch/arm/cpu/armv8/fsl-layerscape/fdt.c > index f5f4840..8a21583 100644 > --- a/arch/arm/cpu/armv8/fsl-layerscape/fdt.c > +++ b/arch/arm/cpu/armv8/fsl-layerscape/fdt.c > @@ -345,11 +345,78 @@ static void fdt_fixup_msi(void *blob) > } > #endif > > +int fdt_fixup_kaslr(void *fdt) > +{ This looks like common, non-layerscape specific code to me, so it should be in sec_firmware.c so other platforms can set the property as well. -- Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: Digital signature URL: