Hi Ard,
The KASLR is backported to LSK v4.4 on git://git.linaro.org/kernel/linux-linaro-stable.git v4.4/topic/mm-kaslr
from v4.4.9 to 5dd612e parisc: Use generic extable search and sort .. Could you like help to review the backporting commits, especially on the 'Conflicts' commits: 44b9620 arm64: kvm: deal with kernel symbols outside of linear mapping 2894f32 arm64: prevent potential circular header dependencies in asm/bug.h d277954 Eliminate the .eh_frame sections from the aarch64 vmlinux and kernel modules 358e3c8 arm64: Use PoU cache instr for I/D coherency
Thanks Alex
On 12 May 2016 at 04:10, Alex Shi alex.shi@linaro.org wrote:
Hi Ard,
The KASLR is backported to LSK v4.4 on git://git.linaro.org/kernel/linux-linaro-stable.git v4.4/topic/mm-kaslr
from v4.4.9 to 5dd612e parisc: Use generic extable search and sort ..
You can drop this one, I think? I don't suppose anyone is running LSK on the PA-risc architecture?
Could you like help to review the backporting commits, especially on the 'Conflicts' commits: 44b9620 arm64: kvm: deal with kernel symbols outside of linear mapping
Looks fine to me
2894f32 arm64: prevent potential circular header dependencies in asm/bug.h
Looks fine. You will notice fairly quickly since it works around a build problem
d277954 Eliminate the .eh_frame sections from the aarch64 vmlinux and kernel modules 358e3c8 arm64: Use PoU cache instr for I/D coherency
Both look fine as well.
Once you have managed to build this with CONFIG_RANDOMIZE_BASE=y, you can check if it works by getting a firmware here:
http://snapshots.linaro.org/components/kernel/leg-virt-tianocore-edk2-upstre...
and running it in qemu as below
qemu-system-aarch64 -M virt -cpu cortex-a57 -m 512 -nographic -bios QEMU_EFI.fd -kernel xxxx -append 'earlycon console=ttyAMA0' -device virtio-rng-pci
and you should see different values for the entries below at every boot
[ 0.000000] .text : 0xffffff8691ef0000 - 0xffffff8692620000 ( 7360 KB) [ 0.000000] .rodata : 0xffffff8692620000 - 0xffffff8692940000 ( 3200 KB) [ 0.000000] .init : 0xffffff8692940000 - 0xffffff8692be0000 ( 2688 KB) [ 0.000000] .data : 0xffffff8692be0000 - 0xffffff8692c8d400 ( 693 KB) [ 0.000000] .bss : 0xffffff8692c8d400 - 0xffffff8692ccbbac ( 250 KB)
Thanks, Ard.
Thanks for Ard help.
After figuring out and fix a 'undefined instr' issue in my qemu, this feature was tested good in LSK 4.4.
Thanks
On 05/12/2016 03:51 PM, Ard Biesheuvel wrote:
Both look fine as well.
Once you have managed to build this with CONFIG_RANDOMIZE_BASE=y, you can check if it works by getting a firmware here:
http://snapshots.linaro.org/components/kernel/leg-virt-tianocore-edk2-upstre...
and running it in qemu as below
qemu-system-aarch64 -M virt -cpu cortex-a57 -m 512 -nographic -bios QEMU_EFI.fd -kernel xxxx -append 'earlycon console=ttyAMA0' -device virtio-rng-pci
and you should see different values for the entries below at every bo
On 13 mei 2016, at 16:16, Alex Shi alex.shi@linaro.org wrote:
Thanks for Ard help.
After figuring out and fix a 'undefined instr' issue in my qemu, this feature was tested good in LSK 4.4.
Very nice work! 3.18 will be a lot more difficult though :-)
Thanks
On 05/12/2016 03:51 PM, Ard Biesheuvel wrote:
Both look fine as well.
Once you have managed to build this with CONFIG_RANDOMIZE_BASE=y, you can check if it works by getting a firmware here:
http://snapshots.linaro.org/components/kernel/leg-virt-tianocore-edk2-upstre...
and running it in qemu as below
qemu-system-aarch64 -M virt -cpu cortex-a57 -m 512 -nographic -bios QEMU_EFI.fd -kernel xxxx -append 'earlycon console=ttyAMA0' -device virtio-rng-pci
and you should see different values for the entries below at every bo
On 05/13/2016 11:37 PM, Ard Biesheuvel wrote:
On 13 mei 2016, at 16:16, Alex Shi alex.shi@linaro.org wrote:
Thanks for Ard help.
After figuring out and fix a 'undefined instr' issue in my qemu, this feature was tested good in LSK 4.4.
Very nice work! 3.18 will be a lot more difficult though :-)
Thanks! Yes, it's a far big gap from 3.18 to 4.6 ... :)
On 16 May 2016 at 09:17, Alex Shi alex.shi@linaro.org wrote:
On 05/13/2016 11:37 PM, Ard Biesheuvel wrote:
On 13 mei 2016, at 16:16, Alex Shi alex.shi@linaro.org wrote:
Thanks for Ard help.
After figuring out and fix a 'undefined instr' issue in my qemu, this feature was tested good in LSK 4.4.
Very nice work! 3.18 will be a lot more difficult though :-)
Thanks! Yes, it's a far big gap from 3.18 to 4.6 ... :)
Hi Alex,
The 4.7 release contains some updates and improvements to the KASLR code. I pushed them onto a lsk-v4.4 branch here: https://git.linaro.org/people/ard.biesheuvel/linux-arm.git/shortlog/refs/hea...
On 28 July 2016 at 11:24, Ard Biesheuvel ard.biesheuvel@linaro.org wrote:
The 4.7 release contains some updates and improvements to the KASLR code. I pushed them onto a lsk-v4.4 branch here:
https://git.linaro.org/people/ard.biesheuvel/linux-arm.git/shortlog/refs/hea...
That appears to be directly on top of the latest LSK rather than the KASLR topic branch v4.4/topic/mm-kaslr - can you rebase on top of the topic branch please or are there other dependencies that make that problematic?
Please when pointing to git repositories post references that are usable with git rather than something that requires a bunch of manual fiddling - usually that's repo and tag so for this:
https://git.linaro.org/people/ard.biesheuvel/linux-arm.git arm64-kaslr-v4.4
Please also provide a diffstat and log, that's really helpful when pulling changes as it provides a quick way to check that what's being pulled is what was expected in case things didn't get pushed that should've been or similar. Using "git request-pull" to generate the request is a good way to cover all these bases.
On 29 July 2016 at 18:40, Mark Brown broonie@linaro.org wrote:
On 28 July 2016 at 11:24, Ard Biesheuvel ard.biesheuvel@linaro.org wrote:
The 4.7 release contains some updates and improvements to the KASLR code. I pushed them onto a lsk-v4.4 branch here:
https://git.linaro.org/people/ard.biesheuvel/linux-arm.git/shortlog/refs/hea...
That appears to be directly on top of the latest LSK rather than the KASLR topic branch v4.4/topic/mm-kaslr - can you rebase on top of the topic branch please or are there other dependencies that make that problematic?
No, everything applies cleanly onto that branch as well.
Please when pointing to git repositories post references that are usable with git rather than something that requires a bunch of manual fiddling - usually that's repo and tag so for this:
https://git.linaro.org/people/ard.biesheuvel/linux-arm.git arm64-kaslr-v4.4
Please also provide a diffstat and log, that's really helpful when pulling changes as it provides a quick way to check that what's being pulled is what was expected in case things didn't get pushed that should've been or similar. Using "git request-pull" to generate the request is a good way to cover all these bases.
The following changes since commit 5dd612ebfad71f5463d89ff92d1bc307cd286b5d:
parisc: Use generic extable search and sort routines (2016-05-12 09:05:25 +0800)
are available in the git repository at:
git://git.linaro.org/people/ard.biesheuvel/linux-arm.git arm64-kaslr-v4.4
for you to fetch changes up to 5808d4c65215bcb6a3fa145965fa9ed0bb3d8f5f:
arm64: kaslr: increase randomization granularity (2016-07-29 18:59:49 +0200)
---------------------------------------------------------------- Ard Biesheuvel (12): arm64: use 'segment' rather than 'chunk' to describe mapped kernel regions arm64: move early boot code to the .init segment arm64: cover the .head.text section in the .text segment mapping arm64: simplify kernel segment mapping granularity arm64: kernel: don't export local symbols from head.S arm64: kernel: use literal for relocated address of __secondary_switched arm64: kernel: perform relocation processing from ID map arm64: introduce mov_q macro to move a constant into a 64-bit register arm64: kernel: replace early 64-bit literal loads with move-immediates arm64: don't map TEXT_OFFSET bytes below the kernel if we can avoid it arm64: relocatable: deal with physically misaligned kernel images arm64: kaslr: increase randomization granularity
Jeremy Linton (1): arm64: mm: Mark .rodata as RO
arch/arm64/Kconfig.debug | 2 +- arch/arm64/include/asm/assembler.h | 20 +++ arch/arm64/kernel/efi-entry.S | 2 +- arch/arm64/kernel/head.S | 160 ++++++++++++---------- arch/arm64/kernel/image.h | 2 + arch/arm64/kernel/kaslr.c | 6 +- arch/arm64/kernel/vmlinux.lds.S | 36 +++-- arch/arm64/mm/init.c | 4 +- arch/arm64/mm/mmu.c | 35 +++-- drivers/firmware/efi/libstub/arm64-stub.c | 15 +- 10 files changed, 168 insertions(+), 114 deletions(-)
On 29 July 2016 at 18:09, Ard Biesheuvel ard.biesheuvel@linaro.org wrote:
The following changes since commit 5dd612ebfad71f5463d89ff92d1bc307cd286b5d:
parisc: Use generic extable search and sort routines (2016-05-12 09:05:25 +0800)
are available in the git repository at:
git://git.linaro.org/people/ard.biesheuvel/linux-arm.git arm64-kaslr-v4.4
for you to fetch changes up to 5808d4c65215bcb6a3fa145965fa9ed0bb3d8f5f:
arm64: kaslr: increase randomization granularity (2016-07-29 18:59:49 +0200)
Thanks, pulled & pushed.
On 29 July 2016 at 22:38, Mark Brown broonie@linaro.org wrote:
On 29 July 2016 at 18:09, Ard Biesheuvel ard.biesheuvel@linaro.org wrote:
The following changes since commit 5dd612ebfad71f5463d89ff92d1bc307cd286b5d:
parisc: Use generic extable search and sort routines (2016-05-12 09:05:25 +0800)
are available in the git repository at:
git://git.linaro.org/people/ard.biesheuvel/linux-arm.git arm64-kaslr-v4.4
for you to fetch changes up to 5808d4c65215bcb6a3fa145965fa9ed0bb3d8f5f:
arm64: kaslr: increase randomization granularity (2016-07-29 18:59:49 +0200)
Thanks, pulled & pushed.
Hi,
Another two cleanup patches related to KASLR that were pulled into v4.8-rc1. The first one fixes a potential build failure with newer (as yet unreleased) binutils. The second one gets rid of some absolute symbol based relocations, which actually don't hurt in this case (unlike in the EFI stub case), but removing them results in a cleaner binary and simpler relocation code in the early boot path.
Thanks for notice. Could you like to send me pull for the new fixes?
Regards Alex
On 08/14/2016 11:00 PM, Ard Biesheuvel wrote:
Thanks, pulled & pushed.
Hi,
Another two cleanup patches related to KASLR that were pulled into v4.8-rc1. The first one fixes a potential build failure with newer (as yet unreleased) binutils. The second one gets rid of some absolute symbol based relocations, which actually don't hurt in this case (unlike in the EFI stub case), but removing them results in a cleaner binary and simpler relocation code in the early boot path.
On 15 August 2016 at 03:49, Alex Shi alex.shi@linaro.org wrote:
Thanks for notice. Could you like to send me pull for the new fixes?
I already did, It is the part of the email that you removed before replying.
Got and pushed.
The '-- Ard' make following contents' color lighter in Thunderbird. That's easy to be ignored...
Thanks!
On 08/14/2016 11:00 PM, Ard Biesheuvel wrote:
-- Ard. The following changes since commit 5808d4c65215bcb6a3fa145965fa9ed0bb3d8f5f: arm64: kaslr: increase randomization granularity (2016-07-29 18:59:49 +0200) are available in the git repository at: git://git.linaro.org/people/ard.biesheuvel/linux-arm.git \ tags/lsk-v4.4-arm64-v4.8-kaslr-updates for you to fetch changes up to f56fa8cba132fbf27e2339d52679cb8c48dabc50: arm64: relocatable: suppress R_AARCH64_ABS64 relocations in vmlinux \ (2016-08-14 15:27:05 +0200)
On 15 August 2016 at 11:47, Alex Shi alex.shi@linaro.org wrote:
Got and pushed.
The '-- Ard' make following contents' color lighter in Thunderbird. That's easy to be ignored...
Right, that's actually a good point.
/me makes mental note not to put relevant stuff after the --
linaro-kernel@lists.linaro.org