Re: [edk2] [RFC PATCH 2/4] BaseTools GCC: unify warning flags for all GCC versions

2015-08-10 Thread Ard Biesheuvel
Of Ard Biesheuvel Sent: Friday, August 7, 2015 11:05 PM To: edk2-devel@lists.01.org; Justen, Jordan L; Liu, Yingke D Cc: Ard Biesheuvel Subject: [edk2] [RFC PATCH 2/4] BaseTools GCC: unify warning flags for all GCC versions The warning flags -Wno-address -Wno-unused-but-set-variable are added

[edk2] [PATCH 0/2] AARCH64 tiny code model support

2015-08-10 Thread Ard Biesheuvel
reduced by 80% (see below for details) Ard Biesheuvel (2): ArmVirtPkg: build our DEBUG Shell using the small code model BaseTools AARCH64: use tiny code model by default ArmVirtPkg/ArmVirt.dsc.inc| 9 + BaseTools/Conf/tools_def.template | 2 +- 2 files changed, 10 insertions

[edk2] [PATCH 1/2] ArmVirtPkg: build our DEBUG Shell using the small code model

2015-08-10 Thread Ard Biesheuvel
The DEBUG build of the Shell exceeds 1 MB in size, which means that it cannot be built using the tiny code model. So force the use of the code model in this case. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- ArmVirtPkg

[edk2] [PATCH 2/2] BaseTools AARCH64: use tiny code model by default

2015-08-10 Thread Ard Biesheuvel
CC_FLAGS. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- BaseTools/Conf/tools_def.template | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/BaseTools/Conf/tools_def.template b/BaseTools/Conf/tools_def.template index

[edk2] [PATCH 5/5] BaseTools: remove ARMGCC and ARMLINUXGCC toolchains

2015-08-10 Thread Ard Biesheuvel
these different architectures aligned, remove the ARMGCC and ARMLINUXGCC toolchains entirely. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- BaseTools/Conf/build_rule.template | 16 +- BaseTools/Conf/tools_def.template | 200

Re: [edk2] [PATCH 3/5] ArmPlatformPkg: remove mention of ARMGCC and ARMLINUXGCC

2015-08-10 Thread Ard Biesheuvel
On 10 August 2015 at 15:45, Leif Lindholm leif.lindh...@linaro.org wrote: On Mon, Aug 10, 2015 at 03:07:41PM +0200, Ard Biesheuvel wrote: Remove the ARMGCC and ARMLINUXGCC from comments in the respective Makefiles of ArmPlatformPkg and ArmJunoPkg and from the [ancient] Versatile Express

[edk2] [PATCH 3/3] OvmfPkg/Xen: use lower case x in hex immediate value

2015-08-10 Thread Ard Biesheuvel
CLANG chokes on the value 0XEA1 since it expects the 0x prefix to use a lower case x. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- OvmfPkg/Include/IndustryStandard/Xen/arch-arm/xen.h | 2 +- 1 file changed, 1 insertion(+), 1

[edk2] [PATCH 1/3] ArmVirtPkg: avoid relocated immediates in AARCH64 asm

2015-08-10 Thread Ard Biesheuvel
Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- ArmVirtPkg/Library/ArmXenRelocatablePlatformLib/AARCH64/MemnodeParser.S | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ArmVirtPkg/Library/ArmXenRelocatablePlatformLib/AARCH64/MemnodeParser.S b/ArmVirtPkg

[edk2] [PATCH 2/3] ArmVirtPkg: use global section alignment in custom linker script

2015-08-10 Thread Ard Biesheuvel
add this to the linker script. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- ArmVirtPkg/PrePi/Scripts/PrePi-PIE.lds | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ArmVirtPkg/PrePi/Scripts/PrePi-PIE.lds b

[edk2] [PATCH 0/3] ArmVirtXen clang fixes

2015-08-10 Thread Ard Biesheuvel
These are some minor code changes to allow ArmVirtXen to be built using CLANG. Since the commercial ARM compiler suite is based on clang, we try and keep the EDK2 code clang-clean, hence these patches. Ard Biesheuvel (3): ArmVirtPkg: avoid relocated immediates in AARCH64 asm ArmVirtPkg: use

Re: [edk2] [PATCH 0/4] FFS/FV aligment optimization (was: [RFC] small C model and LLVM/clang support for AARCH64)

2015-07-27 Thread Ard Biesheuvel
the patches accordingly Thanks, Ard. -Original Message- From: Ard Biesheuvel [mailto:ard.biesheu...@linaro.org] Sent: Monday, July 27, 2015 7:24 PM To: Gao, Liming Cc: Leif Lindholm; Liu, Yingke D; edk2-devel@lists.01.org; eugene.co...@hp.com Subject: Re: [edk2] [PATCH 0/4] FFS/FV

[edk2] [PATCH v2 1/4] BaseTools/GenFw: move .debug contents to .data to save space

2015-07-27 Thread Ard Biesheuvel
-by: Ard Biesheuvel ard.biesheu...@linaro.org --- BaseTools/Source/C/GenFw/Elf32Convert.c | 56 ++-- BaseTools/Source/C/GenFw/Elf64Convert.c | 54 +-- 2 files changed, 53 insertions(+), 57 deletions(-) diff --git a/BaseTools/Source/C/GenFw/Elf32Convert.c b/BaseTools

Re: [edk2] [PATCH v2 0/4] FFS/FV aligment optimization (was: [RFC] small C model and LLVM/clang support for AARCH64)

2015-07-27 Thread Ard Biesheuvel
the responsibilities amongst yourselves, and Maintainers.txt is not always entirely accurate imo) Regards, Ard. -Original Message- From: Ard Biesheuvel [mailto:ard.biesheu...@linaro.org] Sent: Monday, July 27, 2015 8:32 PM To: Gao, Liming; Liu, Yingke D; edk2-devel@lists.01.org Cc: leif.lindh

Re: [edk2] [PATCH 0/4] FFS/FV aligment optimization (was: [RFC] small C model and LLVM/clang support for AARCH64)

2015-07-27 Thread Ard Biesheuvel
in the header cannot tell you how much padding was removed, and it only contains the global alignment, but does not know to which FFS sections it applies. Regards, Ard. -Original Message- From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of Ard Biesheuvel Sent: Monday, July

[edk2] [PATCH v2 0/4] FFS/FV aligment optimization (was: [RFC] small C model and LLVM/clang support for AARCH64)

2015-07-27 Thread Ard Biesheuvel
that the misalignment is calculated based on the first byte of the FFS payload, and not of the aligned section. Since all FFS sections are padded out relative to the first byte of the FFS payload, compensating its misalignment will shift all sections into place. Ard Biesheuvel (4): BaseTools/GenFw: move .debug

[edk2] [PATCH v2 2/4] BaseTools/GenFw: move PE/COFF header closer to payload

2015-07-27 Thread Ard Biesheuvel
. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- BaseTools/Source/C/GenFw/Elf32Convert.c | 10 ++ BaseTools/Source/C/GenFw/Elf64Convert.c | 10 ++ 2 files changed, 20 insertions(+) diff --git a/BaseTools/Source/C

[edk2] [PATCH v2 3/4] BaseTools: use GUID identifiable section for FFS alignment padding

2015-07-27 Thread Ard Biesheuvel
we will now be able to remove padding rather than add more, by shrinking the size of this section instead of padding out the start of the FFS image to file alignment. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- BaseTools

[edk2] [PATCH v2 4/4] BaseTools/GenFv: optimize away redundant padding

2015-07-27 Thread Ard Biesheuvel
Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- BaseTools/Source/C/GenFv/GenFvInternalLib.c | 169 +++- 1 file changed, 161 insertions(+), 8 deletions(-) diff --git a/BaseTools/Source/C/GenFv/GenFvInternalLib.c b/BaseTools/Source/C/GenFv/GenFvInternalLib.c index

Re: [edk2] [PATCH] ArmPlatformPkg: remove obsolete ARM and AARCH64 platforms

2015-07-27 Thread Ard Biesheuvel
On 27 July 2015 at 22:28, Leif Lindholm leif.lindh...@linaro.org wrote: On Mon, Jul 27, 2015 at 04:59:31PM +0200, Ard Biesheuvel wrote: Remove obsolete ARM and AARCH64 platforms so the maintainers can focus on the ones that are still supported: - TC2 (ArmVExpress-CTA15-A7.dsc) - Foundation

[edk2] [PATCH v3] arm64/efi: prefer AllocatePages() over efi_low_alloc() for vmlinux

2015-07-23 Thread Ard Biesheuvel
of 'dram_base + TEXT_OFFSET', and only revert to efi_low_alloc() if that fails. This is the only way to allocate at the base of DRAM if DRAM starts at 0x0, since efi_low_alloc() refuses to allocate at 0x0. Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- v3: - set *reserve_addr before calling

Re: [edk2] [PATCH] arm64/efi: prefer AllocatePages() over efi_low_alloc() for vmlinux

2015-07-23 Thread Ard Biesheuvel
On 23 July 2015 at 15:11, Ard Biesheuvel ard.biesheu...@linaro.org wrote: Hello Haojian, Could you please try this patch? Ehm, never mind, please wait for the v2. This patch is incorrect. -- Ard. ---8 When allocating memory for the kernel image, try the AllocatePages() boot

Re: [edk2] [PATCH v2 0/6] ArmPkg/ArmVirtPkg: GIC revision detection

2015-07-26 Thread Ard Biesheuvel
On 26 July 2015 at 13:46, Leif Lindholm leif.lindh...@linaro.org wrote: On Sun, Jul 26, 2015 at 01:08:20PM +0200, Ard Biesheuvel wrote: So ... had a look through, looks sane, have a couple of minor comments (will add inline). But what I don't have at home is a useful hardware platform

Re: [edk2] [PATCH v2 0/6] ArmPkg/ArmVirtPkg: GIC revision detection

2015-07-26 Thread Ard Biesheuvel
On 26 July 2015 at 11:50, Laszlo Ersek ler...@redhat.com wrote: On 07/26/15 11:40, Ard Biesheuvel wrote: The current GIC revision detection code infers the GIC revision from the AA64PFR0_EL1.GIC feature bit that tells us whether the GIC system register interface is implemented in the hardware

Re: [edk2] [PATCH v2 5/6] ArmVirtPkg: record GIC revision in dynamic PCD

2015-07-26 Thread Ard Biesheuvel
On 26 July 2015 at 11:40, Ard Biesheuvel ard.biesheu...@linaro.org wrote: In order to allow a ArmGicArchLib to be implemented that returns the supported GIC revision based on the device tree, add handling to VirtFdtDxe to record the GIC revision at DT parsing time. Contributed-under

Re: [edk2] [PATCH v2 2/6] ArmPkg: split off ArmGicArchLib from ArmGicLib

2015-07-26 Thread Ard Biesheuvel
On 26 July 2015 at 13:00, Leif Lindholm leif.lindh...@linaro.org wrote: On Sun, Jul 26, 2015 at 11:40:11AM +0200, Ard Biesheuvel wrote: ... diff --git a/ArmPkg/Library/ArmSmcLib/ArmSmcLib.inf b/ArmPkg/Library/ArmGicArchLib/ArmGicArchLib.inf similarity index 64% copy from ArmPkg/Library

[edk2] [PATCH v2 2/6] ArmPkg: split off ArmGicArchLib from ArmGicLib

2015-07-26 Thread Ard Biesheuvel
the existing ArmGicGetSupportedArchRevision () into it. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org Acked-by: Laszlo Ersek ler...@redhat.com --- ArmPkg/ArmPkg.dec | 1

[edk2] [PATCH v2 3/6] ArmPkg: copy ArmGicArchLib to ArmGicArchSecLib

2015-07-26 Thread Ard Biesheuvel
Clone ArmGicArchLib into a SEC phase specific ArmGicArchSecLib so that we can modify the former in a subsequent patch to cache the GIC revision in a global variable. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org Reviewed-by: Laszlo

[edk2] [PATCH v2 0/6] ArmPkg/ArmVirtPkg: GIC revision detection

2015-07-26 Thread Ard Biesheuvel
- added R-b's and acks from Laszlo Ard Biesheuvel (6): ArmPkg: merge ArmGicV[23]Lib.h into ArmGicLib.h ArmPkg: split off ArmGicArchLib from ArmGicLib ArmPkg: copy ArmGicArchLib to ArmGicArchSecLib ArmPkg: cache detected revision in ArmGicArchLib ArmVirtPkg: record GIC revision in dynamic

[edk2] [PATCH v2 6/6] ArmVirtPkg: implement DT-based ArmGicArchLib

2015-07-26 Thread Ard Biesheuvel
that is set based on the GIC DT node. This means this library can only execute post DXE core, but this is not a problem for any of the virt platforms. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org Reviewed-by: Laszlo Ersek ler...@redhat.com

[edk2] [PATCH v2 4/6] ArmPkg: cache detected revision in ArmGicArchLib

2015-07-26 Thread Ard Biesheuvel
Instead of inferring the GIC revision from the CPU id registers and the presence/availability of the system register interface upon each invocation, move the logic to a constructor and cache the result. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel

[edk2] [PATCH v2 5/6] ArmVirtPkg: record GIC revision in dynamic PCD

2015-07-26 Thread Ard Biesheuvel
In order to allow a ArmGicArchLib to be implemented that returns the supported GIC revision based on the device tree, add handling to VirtFdtDxe to record the GIC revision at DT parsing time. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu

Re: [edk2] [PATCH 0/4] FFS/FV aligment optimization (was: [RFC] small C model and LLVM/clang support for AARCH64)

2015-07-27 Thread Ard Biesheuvel
is to add a FV padding file. -- Ard. -Original Message- From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of Ard Biesheuvel Sent: Monday, July 27, 2015 15:41 To: Gao, Liming Cc: Liu, Yingke D; eugene.co...@hp.com; edk2-devel@lists.01.org; Leif Lindholm Subject: Re

Re: [edk2] [PATCH 0/4] FFS/FV aligment optimization (was: [RFC] small C model and LLVM/clang support for AARCH64)

2015-07-27 Thread Ard Biesheuvel
-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of Ard Biesheuvel Sent: Monday, July 27, 2015 16:34 To: Liu, Yingke D Cc: Leif Lindholm; edk2-devel@lists.01.org; eugene.co...@hp.com; Gao, Liming Subject: Re: [edk2] [PATCH 0/4] FFS/FV aligment optimization (was: [RFC] small C model

Re: [edk2] [PATCH v3] arm64/efi: prefer AllocatePages() over efi_low_alloc() for vmlinux

2015-07-23 Thread Ard Biesheuvel
On 23 July 2015 at 16:05, Haojian Zhuang haojian.zhu...@linaro.org wrote: On Thu, 2015-07-23 at 15:25 +0200, Ard Biesheuvel wrote: Hello Haojian, Apologies for the noise ... Could you please try *this* version v3 instead? v2 is just the same patch as before ... -- Ard. Hi Ard

Re: [edk2] [PATCH 1/6] BaseTools: add unified GCC linker script for all archs and versions

2015-07-23 Thread Ard Biesheuvel
On 22 July 2015 at 23:20, Ard Biesheuvel ard.biesheu...@linaro.org wrote: On 22 July 2015 at 21:12, Jordan Justen jordan.l.jus...@intel.com wrote: On 2015-07-22 06:56:45, Ard Biesheuvel wrote: After two recent changes have been applied to the ELF conversion routines in GenFw, i.e., PE/COFF

[edk2] [RFC PATCH 8/8] BaseTools: enable small C model for AARCH64/GCC

2015-07-17 Thread Ard Biesheuvel
This enables the use of the small C model for AARCH64. Since this requires 4 KB section alignment, the linker script is updated as well. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- BaseTools/Conf/tools_def.template | 2

[edk2] [PATCH v2 0/7] BaseTools: unify all GCC linker scripts

2015-07-24 Thread Ard Biesheuvel
and Ovmf/X64 Branch is here https://git.linaro.org/people/ard.biesheuvel/uefi-next.git/shortlog/refs/heads/unify-gcc-ld-scripts-v2 Ard Biesheuvel (7): BaseTools: add unified GCC linker script for all archs and versions BaseTools/GCC: move AutoGen.obj contents to .text section BaseTools/AARCH64

[edk2] [PATCH v2 5/7] ArmVirtPkg: move to unified GCC linker script

2015-07-24 Thread Ard Biesheuvel
Move to the parametrised generic GCC linker script and set 64 KB alignment, instead of using the AARCH64 specific incremental linker script for 64 KB alignment which is about to be removed. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu

Re: [edk2] [RFC PATCH] MdeModulePkg: account for disjoint code and data regions in runtime relocations

2015-07-17 Thread Ard Biesheuvel
On 16 July 2015 at 15:57, Matt Fleming m...@codeblueprint.co.uk wrote: On Fri, 10 Jul, at 04:23:58PM, Ard Biesheuvel wrote: Is there a reason to set strict permissions at all on the 1:1 mapping? Does it stick around after having called SVAM () ? My (naive) suggestion would be to apply

Re: [edk2] [PATCH] Maintainers.txt: ARM packages maintainer update

2015-07-17 Thread Ard Biesheuvel
On 17 July 2015 at 17:51, Leif Lindholm leif.lindh...@linaro.org wrote: Retire Olivier Martin as maintainer, and add in Ard Biesheuvel as a co-maintainer for the ARM packages. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Leif Lindholm leif.lindh...@linaro.org

[edk2] [PATCH] BaseTools/Common: fix heap overrun in ReadMemoryFileLine ()

2015-07-17 Thread Ard Biesheuvel
ReadMemoryFileLine () appends a NULL character to the string it returns, but it failed to account for it in the allocation. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel ard.biesheu...@linaro.org --- BaseTools/Source/C/Common/MemoryFile.c | 2 +- 1 file

Re: [edk2] [PATCH]: CorebootPayloadPkg: Remove data alignment restriction to support GCC49

2015-07-18 Thread Ard Biesheuvel
On 18 July 2015 at 06:23, Scott Duplichan sc...@notabs.org wrote: Gcc 4.9 produces data alignments of up to 64 bytes. Previous gcc versions align data at up to 32 bytes. With GCC49, this difference causes CorebootPayloadPkg to hang after PeCoffLoaderLoadImage() sets ImageError to

Re: [edk2] [RFC PATCH 0/8] small C model and LLVM/clang support for AARCH64

2015-07-20 Thread Ard Biesheuvel
On 20 July 2015 at 10:42, Ard Biesheuvel ard.biesheu...@linaro.org wrote: On 17 July 2015 at 21:07, Cohen, Eugene eug...@hp.com wrote: Ard, The bottom line is that we are still losing around 40 KB on padding in total, If I understand correctly you're saying because of limitations

[edk2] [PATCH] MdePkg: use less predictable values for the stack canaries

2015-10-23 Thread Ard Biesheuvel
on the module's load address. So initialize the __stack_chk_guard variable by taking its own address. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- Note that this is almost exactly what was there already in the code but comment

Re: [edk2] [PATCH] MdePkg/BaseSynchronizationLib: fix return value

2015-10-27 Thread Ard Biesheuvel
chronizationLib/AArch64/Synchronization.S > @@ -171,6 +171,7 @@ TryInternalSyncIncrement: >add w1, w1, #1 >stxrw2, w1, [x0] >cbnzw2, TryInternalSyncIncrement > + mov x0, x1 Thanks for fixing this. However, I prefer we use 'mov w0, w1' here, even though

Re: [edk2] [PATCH v2 0/8] serial and DEBUG output tweaks

2015-10-26 Thread Ard Biesheuvel
per patch. >>> >>> Testing on Xen and/or physical ARM|AARCH64 platforms would be >>> appreciated. (The patches should be easy to apply from the mailing list >>> -- no new files are created, so just use "git am --keep-cr".) >>> >>> Thanks! >>&

Re: [edk2] [PATCH 1/1] EmbeddedPkg: Add EFIAPI to several Ebl functions

2015-10-28 Thread Ard Biesheuvel
On 28 October 2015 at 14:35, Thomas Palmer wrote: > The EFIAPI function declaration is missing for several functions in the > EmbeddedPkg/Ebl directory. A few function pointer struct members expect > EFIAPI though and GCC46/X64 will fail to compile the directory without

Re: [edk2] [PATCH v2] EmbeddedPkg: Add EFIAPI to several Ebl functions

2015-10-29 Thread Ard Biesheuvel
rectory without them. > Please line wrap your commit messages the next time. > Contributed-under: TianoCore Contribution Agreement 1.0 > Signed-off-by: Thomas Palmer <thomas.pal...@hpe.com> Reviewed-by: Ard Biesheuvel <ard.biesheu...@linaro.org> Committed as SVN r18697 Than

Re: [edk2] [PATCH] MdeModulePkg SmbiosMeasurementDxe: Smbios3Table used as SmbiosTable wrongly

2015-10-27 Thread Ard Biesheuvel
On 28 October 2015 at 10:33, Star Zeng wrote: > This patch does below things. > 1. Smbios3Table used as SmbiosTable wrongly after SmbiosTable got from > configuration table. > 2. Correct the return comments of entrypoint function. > 3. Add parameters' comments for

Re: [edk2] [PATCH] MdeModulePkg SmbiosMeasurementDxe: Smbios3Table used as SmbiosTable wrongly

2015-10-27 Thread Ard Biesheuvel
On 28 October 2015 at 13:26, Zeng, Star <star.z...@intel.com> wrote: > On 2015/10/28 9:44, Ard Biesheuvel wrote: >> >> On 28 October 2015 at 10:33, Star Zeng <star.z...@intel.com> wrote: >>> >>> This patch does below things. >>> 1. Smbios3T

Re: [edk2] [PATCH 00/10] ARM cache maintenance cleanup

2015-11-09 Thread Ard Biesheuvel
On 9 November 2015 at 13:43, Leif Lindholm <leif.lindh...@linaro.org> wrote: > OK, so revisiting this after deciding ARM9 has already been broken for > months (at least, possibly always) without anyone complaining. > > On Tue, Nov 03, 2015 at 11:16:25AM +0100, Ar

[edk2] [PATCH] ArmPkg/ArmLib: mark all cached mappings as (inner) shareable

2015-11-09 Thread Ard Biesheuvel
the secure firmware and possibly a secure OS are already up and running, it is best to refrain from using any non-shareable mappings. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- ArmPkg/Include/Chipset/AArch6

Re: [edk2] Strange behavior of the DS-5 debugger on AARCH64 with step-by-step debugging in uefi

2015-11-10 Thread Ard Biesheuvel
On 10 November 2015 at 18:41, Vladimir Olovyannikov <volov...@broadcom.com> wrote: > Ard, > Many thanks for your help. It works. > Great! Thanks for reporting back. -- Ard. > -Original Message- > From: Ard Biesheuvel [mailto:ard.biesheu...@linaro.org] > Sent: M

Re: [edk2] [PATCH] ArmPlatformPkg: bring DS-5 scripts in line with linker script changes

2015-11-10 Thread Ard Biesheuvel
On 6 November 2015 at 08:25, Ard Biesheuvel <ard.biesheu...@linaro.org> wrote: > The ARM and AARCH64 linker scripts have recently been updated so that > the memory layouts of the ELF and PE/COFF versions of each module are > identical. In particular, this means that the ELF

Re: [edk2] Armv8 64bit: System error booting linux from the UEFI

2015-11-11 Thread Ard Biesheuvel
On 11 November 2015 at 01:20, Vladimir Olovyannikov wrote: > Hello, > > I am not sure this is the right forum to ask this question, so I am sorry in > advance if this is an offtopic here (please point me to the proper one). > > I brought up UEFI on the device and am trying

Re: [edk2] [PATCH 4/4] AppPkg/Python-2.7.10: AppPkg.dsc, pyconfig.h, PyMod-2.7.10 (resend)

2015-11-09 Thread Ard Biesheuvel
On 9 November 2015 at 17:09, Carsey, Jaben wrote: > Reviewed-by: Jaben Carsey > >> -Original Message- >> From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of >> Daryl McDaniel >> Sent: Saturday, November 07, 2015 11:46 AM

Re: [edk2] [PATCH 4/4] AppPkg/Python-2.7.10: AppPkg.dsc, pyconfig.h, PyMod-2.7.10 (resend)

2015-11-09 Thread Ard Biesheuvel
o git add (which lets you interactively select which changes to stage for the next commit), and git rebase -i, which lets you reorder and modify patches. Happy to help if you have more questions, Ard. > -Original Message- > From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org]

Re: [edk2] edk2 build failure on GCC44

2015-11-08 Thread Ard Biesheuvel
On 9 November 2015 at 06:51, Hao, Xudong <xudong@intel.com> wrote: >> -Original Message----- >> From: Ard Biesheuvel [mailto:ard.biesheu...@linaro.org] >> Sent: Monday, November 9, 2015 1:43 PM >> To: Hao, Xudong <xudong@intel.com> >> Cc: edk

Re: [edk2] Strange behavior of the DS-5 debugger on AARCH64 with step-by-step debugging in uefi

2015-11-08 Thread Ard Biesheuvel
On 6 November 2015 at 21:32, Vladimir Olovyannikov wrote: > Hello Ard, Eugene, > Thank you for explanation. > > Ard, I tried the patch, but it cannot be applied to the latest (pulled a > minute ago, git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@18732 >

Re: [edk2] edk2 build failure on GCC44

2015-11-08 Thread Ard Biesheuvel
On 9 November 2015 at 02:34, Hao, Xudong wrote: > Hi, all > > I'm using edk2 as Xen HVM guest firmware, but the edk2 build fail with GCC > 4.4.7 (RHEL6.5). I clone the edk2 source from > git://git.code.sf.net/p/tianocore/edk2, and the commit is >

Re: [edk2] [PATCH] ArmPlatformPkg: bring DS-5 scripts in line with linker script changes

2015-11-11 Thread Ard Biesheuvel
On 10 November 2015 at 20:06, Leif Lindholm <leif.lindh...@linaro.org> wrote: > On 10 November 2015 at 18:10, Ard Biesheuvel <ard.biesheu...@linaro.org> > wrote: >> On 6 November 2015 at 08:25, Ard Biesheuvel <ard.biesheu...@linaro.org> >> wrote: >>

Re: [edk2] [PATCH] ArmPkg/ArmLib: mark all cached mappings as (inner) shareable

2015-11-12 Thread Ard Biesheuvel
On 12 November 2015 at 12:35, Leif Lindholm <leif.lindh...@linaro.org> wrote: > Hi Ard, > > On Mon, Nov 09, 2015 at 02:18:58PM +0100, Ard Biesheuvel wrote: >> Mark all cached memory mappings as shareable (or inner shareable on >> AArch64) so that our view of memory is ke

[edk2] [PATCH 1/2] ArmPkg/AArch64Mmu: remove unused GcdAttributeToArmAttribute()

2015-11-12 Thread Ard Biesheuvel
Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- ArmPkg/Include/Chipset/AArch64.h | 5 --- ArmPkg/Library/ArmLib/AArch64/AArch64Mmu.c | 42 2 files changed, 47 deletions(-) diff --git a/ArmPkg/Include/Chipset/AArch64.h b/ArmPkg/I

[edk2] [PATCH 2/2] ArmPkg/AArch64Mmu: set required XN attributes for device mappings

2015-11-12 Thread Ard Biesheuvel
aro.org> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- ArmPkg/Library/ArmLib/AArch64/AArch64Mmu.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ArmPkg/Library/ArmLib/AArch64/AArch64Mmu.c b/ArmPkg/Librar

Re: [edk2] Armv8 64bit: System error booting linux from the UEFI

2015-11-13 Thread Ard Biesheuvel
On 12 November 2015 at 03:41, Vladimir Olovyannikov <volov...@broadcom.com> wrote: >> -Original Message----- >> From: Ard Biesheuvel [mailto:ard.biesheu...@linaro.org] >> Sent: Wednesday, November 11, 2015 1:08 AM >> To: Vladimir Olovyannikov >> Cc: ed

[edk2] [PATCH v2 1/4] ArmPkg/AArch64Mmu: remove unused GcdAttributeToArmAttribute()

2015-11-13 Thread Ard Biesheuvel
Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- ArmPkg/Include/Chipset/AArch64.h | 5 --- ArmPkg/Library/ArmLib/AArch64/AArch64Mmu.c | 42 2 files changed, 47 deletions(-) diff --git a/ArmPkg/Include/Chipset/AArch64.h b/ArmPkg/I

[edk2] [PATCH v2 0/4] improve handling of device attributes on ARM/AARCH64

2015-11-13 Thread Ard Biesheuvel
the XN bit set. The v2 version now covers ARM as well. Ard Biesheuvel (4): ArmPkg/AArch64Mmu: remove unused GcdAttributeToArmAttribute() ArmVirtPkg/ArmVirtPlatformLib: do not map executable NOR region as device ArmVExpressPkg/ArmVExpressLibRTSM: map NOR flash as cached ArmPkg/Mmu: set

[edk2] [PATCH v2 2/4] ArmVirtPkg/ArmVirtPlatformLib: do not map executable NOR region as device

2015-11-13 Thread Ard Biesheuvel
that contains our FD image should be mapped as normal memory instead. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- ArmVirtPkg/Library/ArmVirtPlatformLib/VirtMem.c | 58 1 file changed, 47 insertions(+), 11 del

Re: [edk2] [PATCH v2 2/4] ArmVirtPkg/ArmVirtPlatformLib: do not map executable NOR region as device

2015-11-13 Thread Ard Biesheuvel
On 13 November 2015 at 17:55, Ard Biesheuvel <ard.biesheu...@linaro.org> wrote: > On 13 November 2015 at 17:40, Laszlo Ersek <ler...@redhat.com> wrote: >> On 11/13/15 15:55, Ard Biesheuvel wrote: >>> The ARM architecture version 7 and later mandates that device

[edk2] [PATCH v2 3/4] ArmVExpressPkg/ArmVExpressLibRTSM: map NOR flash as cached

2015-11-13 Thread Ard Biesheuvel
DXE driver is perfectly capable of setting the correct attributes for the region it needs to write to, and since we will be executing from DRAM by that time anyway, we can simply map the NOR flash as normal memory initially. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard

Re: [edk2] [PATCH v2 2/4] ArmVirtPkg/ArmVirtPlatformLib: do not map executable NOR region as device

2015-11-13 Thread Ard Biesheuvel
On 13 November 2015 at 17:40, Laszlo Ersek <ler...@redhat.com> wrote: > On 11/13/15 15:55, Ard Biesheuvel wrote: >> The ARM architecture version 7 and later mandates that device mappings >> have the XN (non-executable) bit set, to prevent speculative instruction >>

Re: [edk2] [PATCH v2 2/4] ArmVirtPkg/ArmVirtPlatformLib: do not map executable NOR region as device

2015-11-13 Thread Ard Biesheuvel
On 13 November 2015 at 18:33, Laszlo Ersek <ler...@redhat.com> wrote: > On 11/13/15 18:16, Ard Biesheuvel wrote: >> On 13 November 2015 at 17:55, Ard Biesheuvel <ard.biesheu...@linaro.org> >> wrote: >>> On 13 November 2015 at 17:40, Laszlo Ersek <ler...@re

Re: [edk2] Entering shell without a startup.nsh

2015-11-15 Thread Ard Biesheuvel
On 15 November 2015 at 11:24, Michael Zimmermann wrote: > Hi, > > I just noticed that when the file startup.nsh is missing and you don't > press ESC during the countdown that shell just hangs forever. > > Is that the expected behavior? > No, it is not. You should simply

Re: [edk2] Entering shell without a startup.nsh

2015-11-15 Thread Ard Biesheuvel
y you would get a hit on that file: it smells like a bug to me. Can you just remove the module from your build? > On Sun, Nov 15, 2015 at 11:27 AM, Ard Biesheuvel <ard.biesheu...@linaro.org> > wrote: >> >> On 15 November 2015 at 11:24, Michael Zimmermann >> <sigm

Re: [edk2] [PATCH] ArmPkg/ArmLib: mark all cached mappings as (inner) shareable

2015-11-14 Thread Ard Biesheuvel
1 > 000F > Available C000-0000FFFF 0004 > 000F > > On Thu, Nov 12, 2015 at 3:03 PM, Mark Rutland <mark.rutl...@arm.com> wrote: >> >> On Thu, Nov 12, 2015 at 11:35:28AM +, Leif Lindholm wrote: >> > Hi Ard,

[edk2] [PATCH] ArmPkg/ArmV7Mmu: introduce feature PCD to map normal memory non-shareable

2015-11-16 Thread Ard Biesheuvel
introduce a PCD PcdNormalMemoryNonshareableOverride that makes cacheable mappings of normal memory non-shareable. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- ArmPkg/ArmPkg.dec | 6 ++

Re: [edk2] [PATCH] ArmPkg/ArmV7Mmu: introduce feature PCD to map normal memory non-shareable

2015-11-16 Thread Ard Biesheuvel
On 16 November 2015 at 17:56, Leif Lindholm <leif.lindh...@linaro.org> wrote: > On Mon, Nov 16, 2015 at 05:29:42PM +0100, Ard Biesheuvel wrote: >> Even though mapping normal memory (inner) shareable is usually the >> correct choice on coherent systems, it may be desirable in

Re: [edk2] [PATCH] ArmPkg/ArmLib: mark all cached mappings as (inner) shareable

2015-11-16 Thread Ard Biesheuvel
000-BFFF 0001 > 000F > Available C000-0000FFFF 0004 > 000F > > On Thu, Nov 12, 2015 at 3:03 PM, Mark Rutland <mark.rutl...@arm.com> wrote: >> >> On Thu, Nov 12, 2015 at 11:35:28AM +

Re: [edk2] [PATCH] ArmPkg/ArmLib: mark all cached mappings as (inner) shareable

2015-11-16 Thread Ard Biesheuvel
b8ae589a98d2d3b81 > OK. Thanks for clearing that up. Are you using an external L2 (e.g., a PL220), and if so, can you configure it to ignore the S bit? >> On Mon, Nov 16, 2015 at 1:11 PM, Ard Biesheuvel <ard.biesheu...@linaro.org> >> wrote: >> On 14 Novembe

Re: [edk2] Armv8 64bit: System error booting linux from the UEFI

2015-11-16 Thread Ard Biesheuvel
On 16 November 2015 at 19:41, Vladimir Olovyannikov <volov...@broadcom.com> wrote: >> -Original Message----- >> From: Ard Biesheuvel [mailto:ard.biesheu...@linaro.org] >> Sent: Monday, November 16, 2015 10:28 AM >> To: Vladimir Olovyannikov >> Cc: M

Re: [edk2] Armv8 64bit: System error booting linux from the UEFI

2015-11-16 Thread Ard Biesheuvel
On 16 November 2015 at 20:13, Mark Rutland <mark.rutl...@arm.com> wrote: > On Mon, Nov 16, 2015 at 08:08:18PM +0100, Ard Biesheuvel wrote: >> On 16 November 2015 at 19:41, Vladimir Olovyannikov >> <volov...@broadcom.com> wrote: >> >> -----Original

[edk2] [PATCH v2] ArmPkg/ArmV7Mmu: introduce feature PCD to map normal memory non-shareable

2015-11-16 Thread Ard Biesheuvel
introduce a PCD PcdNormalMemoryNonshareableOverride that makes cacheable mappings of normal memory non-shareable. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- v2: just clear the TT_DESCRIPTOR_[PAGE|SECTION]_S_SHARED bit f

Re: [edk2] Armv8 64bit: System error booting linux from the UEFI

2015-11-16 Thread Ard Biesheuvel
On 16 November 2015 at 19:23, Vladimir Olovyannikov <volov...@broadcom.com> wrote: >> -Original Message- >> From: Mark Rutland [mailto:mark.rutl...@arm.com] >> Sent: Friday, November 13, 2015 5:18 PM >> To: Vladimir Olovyannikov >> Cc: Ard Biesheuvel; ed

Re: [edk2] Strange behavior of the DS-5 debugger on AARCH64 with step-by-step debugging in uefi

2015-11-09 Thread Ard Biesheuvel
On 9 November 2015 at 19:01, Vladimir Olovyannikov <volov...@broadcom.com> wrote: > -Original Message- > From: Ard Biesheuvel [mailto:ard.biesheu...@linaro.org] > Sent: Sunday, November 08, 2015 10:52 PM > To: Vladimir Olovyannikov > Cc: Cohen, Eugene; edk2-devel@lists

Re: [edk2] [PATCH] ArmPkg: ensure DebugAgentVectorTable is 2K-aligned

2015-11-17 Thread Ard Biesheuvel
h...@linaro.org> This is not causing any actual problems, since the minimum alignment is propagated to the entire .text section of the object file, and there is nothing that takes up space between the two symbols. But that does not make it correct, so Reviewed-by: Ard Biesheuvel &l

[edk2] [PATCH v3 3/3] ArmPkg/ArmV7Mmu: introduce feature PCD to map normal memory non-shareable

2015-11-17 Thread Ard Biesheuvel
introduce a PCD PcdNormalMemoryNonshareableOverride that makes cacheable mappings of normal memory non-shareable. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> Reviewed-by: Leif Lindholm <leif.lindh...@linaro.org>

[edk2] [PATCH v3 2/3] ArmPkg/ArmV7Mmu: make cached translation table accesses shareable

2015-11-17 Thread Ard Biesheuvel
To align with the way normal cacheable memory is mapped, set the shareable bit for cached accesses performed by the page table walker. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- ArmPkg/Include/Chipset/ArmV7Mmu

[edk2] [PATCH v3 0/3] ArmPkg: ARMv7 MMU fixes

2015-11-17 Thread Ard Biesheuvel
that page table accesses to cached memory are shareable. Patch #3 is yesterday's patch, updated with Leif's R-b, and an additional override of the shareable bit added in patch #2 Ard Biesheuvel (3): ArmPkg/ArmV7Mmu: fix write-through translation table accesses ArmPkg/ArmV7Mmu: make cached

[edk2] [PATCH v3 1/3] ArmPkg/ArmV7Mmu: fix write-through translation table accesses

2015-11-17 Thread Ard Biesheuvel
it to TTBR_WRITE_THROUGH and update the definition to reflect the name. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- ArmPkg/Include/Chipset/ArmV7Mmu.h | 2 +- ArmPkg/Library/ArmLib/ArmV7/ArmV7Mmu.c | 2 +- 2 files changed, 2 inse

Re: [edk2] [PATCH] ArmPkg: ensure DebugAgentVectorTable is 2K-aligned

2015-11-17 Thread Ard Biesheuvel
On 17 November 2015 at 13:15, Ard Biesheuvel <ard.biesheu...@linaro.org> wrote: > On 17 November 2015 at 12:39, Mark Rutland <mark.rutl...@arm.com> wrote: >> We force alignment to 2K after generating the DebugAgentVectorTable >> symbol, and hence DebugAgentVectorTable i

[edk2] [PATCH] BaseTools GCC: move PECOFF_HEADER_SIZE definition before LD script

2015-11-09 Thread Ard Biesheuvel
-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- BaseTools/Conf/tools_def.template | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/BaseTools/Conf/tools_def.template b/BaseTools/Conf/tools_def.template index 1fef6af5464a..db08e252d2b9 100644 --- a/BaseTool

Re: [edk2] AARCH64 MMU TCR configuration questions

2015-11-09 Thread Ard Biesheuvel
On 9 November 2015 at 09:00, Heyi Guo wrote: > Hi All, > > In AARCH64 MMU configuration code, sharable attribute will be set to inner > sharable when memory attribute is write back. However, I have 2 questions > about this code: > 1. Why is it set to inner sharable only when

Re: [edk2] [PATCH] ArmVirtPkg: fix barriers in ArmEnableMmu

2015-11-02 Thread Ard Biesheuvel
ntribution Agreement 1.0 > Signed-off-by: Mark Rutland <mark.rutl...@arm.com> > Cc: Ard Biesheuvel <ard.biesheu...@linaro.org> > Cc: Laszlo Ersek <ler...@redhat.com> > Cc: Leif Lindholm <leif.lindh...@linaro.org> Reviewed-by: Ard Biesheuvel <ard.biesheu...@l

Re: [edk2] [PATCH 03/10] ArmPkg/ArmLib: remove unused ARM9 support

2015-11-03 Thread Ard Biesheuvel
On 3 November 2015 at 12:56, Leif Lindholm <leif.lindh...@linaro.org> wrote: > On Tue, Nov 03, 2015 at 11:16:28AM +0100, Ard Biesheuvel wrote: >> The ARM9 ArmLib implementation is not referenced anywhere in the >> tree, and unlikely to be useful going forward, considering

[edk2] [PATCH 08/10] ArmCacheMaintenanceLib: disallow whole D-cache maintenance operations

2015-11-03 Thread Ard Biesheuvel
entirely. So ASSERT () when any of the CacheMaintenanceLib whole data cache routines are invoked rather than pretending we can do anything meaningful here. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- ArmPkg/L

[edk2] [PATCH 10/10] ArmPlatformPkg: do not invalidate the entire data cache at startup

2015-11-03 Thread Ard Biesheuvel
Drop the call to ArmInvalidateDataCache () from the PrePi and PrePeiCore startup sequences. This kind of data cache maintenance should not be performed at the UEFI firmware level. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.

[edk2] [PATCH 09/10] ArmVirtPkg/PrePi: do not invalidate the entire data cache at startup

2015-11-03 Thread Ard Biesheuvel
Drop the call to ArmInvalidateDataCache () from the PrePi startup sequence. This kind of data cache maintenance should not be performed at the UEFI firmware level. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- ArmV

[edk2] [PATCH 01/10] ArmPkg/ArmLib: fix barriers in AArch64 ArmEnableMmu

2015-11-03 Thread Ard Biesheuvel
ronise the new context with any subsequent instructions. This patch adds missing DSBs to complete TLB maintenance, and removes the unnecessary trailing DSB. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Mark Rutland <mark.rutl...@arm.com> Reviewed-by: Ard Biesheuvel

[edk2] [PATCH 04/10] ArmPkg/ArmLib: remove unused ArmCleanDataCacheToPoU()

2015-11-03 Thread Ard Biesheuvel
Signed-off-by: Ard Biesheuvel <ard.biesheu...@linaro.org> --- ArmPkg/Include/Library/ArmLib.h| 6 --- ArmPkg/Library/ArmLib/AArch64/AArch64Lib.c | 30 ArmPkg/Library/ArmLib/AArch64/AArch64Lib.h | 6 --- ArmPkg/Library/ArmLib/AArch64/AArch64Support.

Re: [edk2] [PATCH v2 00/16] unify GCC command line options

2015-11-01 Thread Ard Biesheuvel
On 8 October 2015 at 21:56, Bill Paul <wp...@windriver.com> wrote: > Of all the gin joints in all the towns in all the world, Bill Paul had to walk > into mine at 10:30:26 on Monday 24 August 2015 and say: > >> Of all the gin joints in all the towns in all the worl

<    1   2   3   4   5   6   7   8   9   10   >