Message ID | 1392168805-14200-3-git-send-email-lauraa@codeaurora.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On Tue, 11 Feb 2014 17:33:24 -0800, Laura Abbott <lauraa@codeaurora.org> wrote: > The stack canary for ARM is currently the same across reboots > due to lack of randomness early enough. Add ARCH_WANT_OF_RANDOMNESS > to allow devices to add whatever randomness they need. > > Signed-off-by: Laura Abbott <lauraa@codeaurora.org> Do you have a draft patch for a user of this yet? g. > --- > arch/arm/Kconfig | 3 +++ > arch/arm/kernel/vmlinux.lds.S | 1 + > 2 files changed, 4 insertions(+), 0 deletions(-) > > diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig > index e254198..7ab0db1 100644 > --- a/arch/arm/Kconfig > +++ b/arch/arm/Kconfig > @@ -222,6 +222,9 @@ config NEED_RET_TO_USER > config ARCH_MTD_XIP > bool > > +config ARCH_WANT_OF_RANDOMNESS > + def_bool n > + > config VECTORS_BASE > hex > default 0xffff0000 if MMU || CPU_HIGH_VECTOR > diff --git a/arch/arm/kernel/vmlinux.lds.S b/arch/arm/kernel/vmlinux.lds.S > index 7bcee5c..2198258 100644 > --- a/arch/arm/kernel/vmlinux.lds.S > +++ b/arch/arm/kernel/vmlinux.lds.S > @@ -202,6 +202,7 @@ SECTIONS > INIT_SETUP(16) > INIT_CALLS > CON_INITCALL > + EARLY_RANDOM_FUNCS > SECURITY_INITCALL > INIT_RAM_FS > } > -- > The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, > hosted by The Linux Foundation >
On 2/12/2014 8:49 AM, Grant Likely wrote: > On Tue, 11 Feb 2014 17:33:24 -0800, Laura Abbott <lauraa@codeaurora.org> wrote: >> The stack canary for ARM is currently the same across reboots >> due to lack of randomness early enough. Add ARCH_WANT_OF_RANDOMNESS >> to allow devices to add whatever randomness they need. >> >> Signed-off-by: Laura Abbott <lauraa@codeaurora.org> > > Do you have a draft patch for a user of this yet? > I had a particular patch in mind but I need to re-work it to work with the upstream tree. I wanted to at least send out the infrastructure to see how open people were to the idea. After reading the comments, I have a couple more ideas of users as well. I'll see if I can work that in for v2. > g. > Thanks, Laura
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index e254198..7ab0db1 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -222,6 +222,9 @@ config NEED_RET_TO_USER config ARCH_MTD_XIP bool +config ARCH_WANT_OF_RANDOMNESS + def_bool n + config VECTORS_BASE hex default 0xffff0000 if MMU || CPU_HIGH_VECTOR diff --git a/arch/arm/kernel/vmlinux.lds.S b/arch/arm/kernel/vmlinux.lds.S index 7bcee5c..2198258 100644 --- a/arch/arm/kernel/vmlinux.lds.S +++ b/arch/arm/kernel/vmlinux.lds.S @@ -202,6 +202,7 @@ SECTIONS INIT_SETUP(16) INIT_CALLS CON_INITCALL + EARLY_RANDOM_FUNCS SECURITY_INITCALL INIT_RAM_FS }
The stack canary for ARM is currently the same across reboots due to lack of randomness early enough. Add ARCH_WANT_OF_RANDOMNESS to allow devices to add whatever randomness they need. Signed-off-by: Laura Abbott <lauraa@codeaurora.org> --- arch/arm/Kconfig | 3 +++ arch/arm/kernel/vmlinux.lds.S | 1 + 2 files changed, 4 insertions(+), 0 deletions(-)