* [PATCH v2 0/1] BaseTools/tools_def: Add GCC49xASL Toolchain support
@ 2018-06-23 0:57 Chris Co
2018-06-23 0:57 ` [PATCH v2 1/1] " Chris Co
0 siblings, 1 reply; 15+ messages in thread
From: Chris Co @ 2018-06-23 0:57 UTC (permalink / raw)
To: edk2-devel@lists.01.org
REF: https://github.com/christopherco/edk2/tree/gcc49xasl_build_v2
This patch adds a build option for invoking GCC49 ARM cross compiler
in the Windows environment to build firmware for Windows 10 IoT
devices using NXP i.MX6 and i.MX7 SoCs.
In addition, this build option targets the Microsoft ASL
compiler instead of iasl. The Microsoft ASL compiler is
necessary to expose Windows-specific Pin Function Config
Descriptors on Windows IoT devices.
Chris Co (1):
BaseTools/tools_def: Add GCC49xASL Toolchain support
BaseTools/Conf/tools_def.template | 61 ++++++++++++++++++++
1 file changed, 61 insertions(+)
--
2.16.2.gvfs.1.33.gf5370f1
^ permalink raw reply [flat|nested] 15+ messages in thread
* [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain support
2018-06-23 0:57 [PATCH v2 0/1] BaseTools/tools_def: Add GCC49xASL Toolchain support Chris Co
@ 2018-06-23 0:57 ` Chris Co
2018-06-25 1:38 ` Gao, Liming
0 siblings, 1 reply; 15+ messages in thread
From: Chris Co @ 2018-06-23 0:57 UTC (permalink / raw)
To: edk2-devel@lists.01.org; +Cc: Yonghong Zhu, Liming Gao, Leif Lindholm
From: Chris Co <chrco@microsoft.com>
This patch adds a build option for invoking GCC49 ARM cross
compiler in the Windows environment to build firmware for
Windows 10 IoT devices using NXP i.MX6 and i.MX7 SoCs.
In addition, this build option targets the Microsoft ASL
compiler instead of iasl. The Microsoft ASL compiler is
necessary to expose Windows-specific Pin Function Config
Descriptors on Windows IoT devices.
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Christopher Co <christopher.co@microsoft.com>
Cc: Yonghong Zhu <yonghong.zhu@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Cc: Leif Lindholm <leif.lindholm@linaro.org>
---
BaseTools/Conf/tools_def.template | 61 ++++++++++++++++++++
1 file changed, 61 insertions(+)
diff --git a/BaseTools/Conf/tools_def.template b/BaseTools/Conf/tools_def.template
index 11a79029b890..f7a375ebaf1e 100755
--- a/BaseTools/Conf/tools_def.template
+++ b/BaseTools/Conf/tools_def.template
@@ -393,6 +393,12 @@ DEFINE DTC_BIN = ENV(DTC_PREFIX)dtc
# Required to build platforms or ACPI tables:
# Intel(r) ACPI Compiler from
# https://acpica.org/downloads
+# GCC49xASL -Windows- Requires:
+# GCC 4.9 targeting arm-none-eabi
+# Optional:
+# Required to build platforms or ACPI tables:
+# Microsoft ASL ACPI Compiler (asl.exe) from Windows WDK
+# https://docs.microsoft.com/en-us/windows-hardware/drivers/download-the-wdk
# GCC5 -Linux,Windows- Requires:
# GCC 5 with LTO support, targeting x86_64-linux-gnu, aarch64-linux-gnu, or arm-linux-gnueabi
# Optional:
@@ -5466,6 +5472,61 @@ RELEASE_GCC49_AARCH64_DLINK_FLAGS = DEF(GCC49_AARCH64_DLINK_FLAGS)
NOOPT_GCC49_AARCH64_DLINK_FLAGS = DEF(GCC49_AARCH64_DLINK_FLAGS) -z common-page-size=0x1000 -O0
NOOPT_GCC49_AARCH64_DLINK_XIPFLAGS = -z common-page-size=0x20 -O0
+####################################################################################
+#
+# GCC49xASL - This configuration is used to compile under Windows to produce
+# PE/COFF binaries using GCC 4.9.
+#
+####################################################################################
+*_GCC49xASL_*_*_FAMILY = GCC
+
+*_GCC49xASL_*_MAKE_PATH = DEF(GCC_HOST_PREFIX)make
+*_GCC49xASL_*_*_DLL = ENV(GCC49_DLL)
+*_GCC49xASL_*_ASL_PATH = DEF(WIN_ASL_BIN)
+
+*_GCC49xASL_*_PP_FLAGS = DEF(GCC_PP_FLAGS)
+*_GCC49xASL_*_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS)
+*_GCC49xASL_*_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
+*_GCC49xASL_*_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS)
+*_GCC49xASL_*_APP_FLAGS =
+*_GCC49xASL_*_ASL_FLAGS = /MsftInternal
+*_GCC49xASL_*_ASL_OUTFLAGS = DEF(MS_ASL_OUTFLAGS)
+
+##################
+# GCC49xASL ARM definitions
+##################
+*_GCC49xASL_ARM_OBJCOPY_PATH = noop
+*_GCC49xASL_ARM_CC_PATH = ENV(GCC49_ARM_PREFIX)gcc
+*_GCC49xASL_ARM_SLINK_PATH = ENV(GCC49_ARM_PREFIX)ar
+*_GCC49xASL_ARM_DLINK_PATH = ENV(GCC49_ARM_PREFIX)gcc
+*_GCC49xASL_ARM_ASLDLINK_PATH = ENV(GCC49_ARM_PREFIX)gcc
+*_GCC49xASL_ARM_ASM_PATH = ENV(GCC49_ARM_PREFIX)gcc
+*_GCC49xASL_ARM_PP_PATH = ENV(GCC49_ARM_PREFIX)gcc
+*_GCC49xASL_ARM_VFRPP_PATH = ENV(GCC49_ARM_PREFIX)gcc
+*_GCC49xASL_ARM_ASLCC_PATH = ENV(GCC49_ARM_PREFIX)gcc
+*_GCC49xASL_ARM_ASLPP_PATH = ENV(GCC49_ARM_PREFIX)gcc
+*_GCC49xASL_ARM_RC_PATH = ENV(GCC49_ARM_PREFIX)objcopy
+*_GCC49xASL_ARM_SYMRENAME_PATH = noop
+
+*_GCC49xASL_ARM_ARCHCC_FLAGS = -mthumb
+*_GCC49xASL_ARM_PLATFORM_FLAGS = -march=armv7-a
+
+*_GCC49xASL_ARM_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
+*_GCC49xASL_ARM_ASLDLINK_FLAGS = DEF(GCC49_ARM_ASLDLINK_FLAGS)
+*_GCC49xASL_ARM_ASM_FLAGS = DEF(GCC49_ARM_ASM_FLAGS)
+*_GCC49xASL_ARM_DLINK_FLAGS = DEF(GCC49_ARM_DLINK_FLAGS)
+*_GCC49xASL_ARM_DLINK2_FLAGS = DEF(GCC49_ARM_DLINK2_FLAGS)
+*_GCC49xASL_ARM_DTCPP_FLAGS = DEF(GCC_DTCPP_FLAGS)
+*_GCC49xASL_ARM_PLATFORM_FLAGS = -march=armv7-a
+*_GCC49xASL_ARM_PP_FLAGS = $(ARCHCC_FLAGS) $(PLATFORM_FLAGS) DEF(GCC_PP_FLAGS)
+*_GCC49xASL_ARM_RC_FLAGS = DEF(GCC_ARM_RC_FLAGS)
+*_GCC49xASL_ARM_VFRPP_FLAGS = $(ARCHCC_FLAGS) $(PLATFORM_FLAGS) DEF(GCC_VFRPP_FLAGS)
+*_GCC49xASL_ARM_CC_XIPFLAGS = DEF(GCC49_ARM_CC_XIPFLAGS)
+
+ DEBUG_GCC49xASL_ARM_CC_FLAGS = DEF(GCC49_ARM_CC_FLAGS) -O0
+RELEASE_GCC49xASL_ARM_CC_FLAGS = DEF(GCC49_ARM_CC_FLAGS) -Wno-unused-but-set-variable -Wno-unused-const-variable
+ NOOPT_GCC49xASL_ARM_CC_FLAGS = DEF(GCC49_ARM_CC_FLAGS) -O0
+
####################################################################################
#
# GCC 5 - This configuration is used to compile under Linux to produce
--
2.16.2.gvfs.1.33.gf5370f1
^ permalink raw reply related [flat|nested] 15+ messages in thread
* Re: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain support
2018-06-23 0:57 ` [PATCH v2 1/1] " Chris Co
@ 2018-06-25 1:38 ` Gao, Liming
2018-06-25 7:33 ` Ard Biesheuvel
0 siblings, 1 reply; 15+ messages in thread
From: Gao, Liming @ 2018-06-25 1:38 UTC (permalink / raw)
To: Chris Co, edk2-devel@lists.01.org; +Cc: Zhu, Yonghong, Leif Lindholm
Chris:
GCC 4.9 targeting arm-none-eabi. This GCC4.9 should run in Windows OS. So, could you give some info where windows GCC49 is from.
Thanks
Liming
>-----Original Message-----
>From: Chris Co [mailto:Christopher.Co@microsoft.com]
>Sent: Saturday, June 23, 2018 8:58 AM
>To: edk2-devel@lists.01.org
>Cc: Zhu, Yonghong <yonghong.zhu@intel.com>; Gao, Liming
><liming.gao@intel.com>; Leif Lindholm <leif.lindholm@linaro.org>
>Subject: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain
>support
>
>From: Chris Co <chrco@microsoft.com>
>
>This patch adds a build option for invoking GCC49 ARM cross
>compiler in the Windows environment to build firmware for
>Windows 10 IoT devices using NXP i.MX6 and i.MX7 SoCs.
>
>In addition, this build option targets the Microsoft ASL
>compiler instead of iasl. The Microsoft ASL compiler is
>necessary to expose Windows-specific Pin Function Config
>Descriptors on Windows IoT devices.
>
>Contributed-under: TianoCore Contribution Agreement 1.1
>Signed-off-by: Christopher Co <christopher.co@microsoft.com>
>Cc: Yonghong Zhu <yonghong.zhu@intel.com>
>Cc: Liming Gao <liming.gao@intel.com>
>Cc: Leif Lindholm <leif.lindholm@linaro.org>
>---
> BaseTools/Conf/tools_def.template | 61 ++++++++++++++++++++
> 1 file changed, 61 insertions(+)
>
>diff --git a/BaseTools/Conf/tools_def.template
>b/BaseTools/Conf/tools_def.template
>index 11a79029b890..f7a375ebaf1e 100755
>--- a/BaseTools/Conf/tools_def.template
>+++ b/BaseTools/Conf/tools_def.template
>@@ -393,6 +393,12 @@ DEFINE DTC_BIN = ENV(DTC_PREFIX)dtc
> # Required to build platforms or ACPI tables:
> # Intel(r) ACPI Compiler from
> # https://acpica.org/downloads
>+# GCC49xASL -Windows- Requires:
>+# GCC 4.9 targeting arm-none-eabi
>+# Optional:
>+# Required to build platforms or ACPI tables:
>+# Microsoft ASL ACPI Compiler (asl.exe) from Windows WDK
>+# https://docs.microsoft.com/en-us/windows-
>hardware/drivers/download-the-wdk
> # GCC5 -Linux,Windows- Requires:
> # GCC 5 with LTO support, targeting x86_64-linux-gnu, aarch64-
>linux-gnu, or arm-linux-gnueabi
> # Optional:
>@@ -5466,6 +5472,61 @@ RELEASE_GCC49_AARCH64_DLINK_FLAGS =
>DEF(GCC49_AARCH64_DLINK_FLAGS)
> NOOPT_GCC49_AARCH64_DLINK_FLAGS =
>DEF(GCC49_AARCH64_DLINK_FLAGS) -z common-page-size=0x1000 -O0
> NOOPT_GCC49_AARCH64_DLINK_XIPFLAGS = -z common-page-size=0x20 -
>O0
>
>+##########################################################
>##########################
>+#
>+# GCC49xASL - This configuration is used to compile under Windows to
>produce
>+# PE/COFF binaries using GCC 4.9.
>+#
>+##########################################################
>##########################
>+*_GCC49xASL_*_*_FAMILY = GCC
>+
>+*_GCC49xASL_*_MAKE_PATH = DEF(GCC_HOST_PREFIX)make
>+*_GCC49xASL_*_*_DLL = ENV(GCC49_DLL)
>+*_GCC49xASL_*_ASL_PATH = DEF(WIN_ASL_BIN)
>+
>+*_GCC49xASL_*_PP_FLAGS = DEF(GCC_PP_FLAGS)
>+*_GCC49xASL_*_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS)
>+*_GCC49xASL_*_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
>+*_GCC49xASL_*_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS)
>+*_GCC49xASL_*_APP_FLAGS =
>+*_GCC49xASL_*_ASL_FLAGS = /MsftInternal
>+*_GCC49xASL_*_ASL_OUTFLAGS = DEF(MS_ASL_OUTFLAGS)
>+
>+##################
>+# GCC49xASL ARM definitions
>+##################
>+*_GCC49xASL_ARM_OBJCOPY_PATH = noop
>+*_GCC49xASL_ARM_CC_PATH = ENV(GCC49_ARM_PREFIX)gcc
>+*_GCC49xASL_ARM_SLINK_PATH = ENV(GCC49_ARM_PREFIX)ar
>+*_GCC49xASL_ARM_DLINK_PATH = ENV(GCC49_ARM_PREFIX)gcc
>+*_GCC49xASL_ARM_ASLDLINK_PATH = ENV(GCC49_ARM_PREFIX)gcc
>+*_GCC49xASL_ARM_ASM_PATH = ENV(GCC49_ARM_PREFIX)gcc
>+*_GCC49xASL_ARM_PP_PATH = ENV(GCC49_ARM_PREFIX)gcc
>+*_GCC49xASL_ARM_VFRPP_PATH = ENV(GCC49_ARM_PREFIX)gcc
>+*_GCC49xASL_ARM_ASLCC_PATH = ENV(GCC49_ARM_PREFIX)gcc
>+*_GCC49xASL_ARM_ASLPP_PATH = ENV(GCC49_ARM_PREFIX)gcc
>+*_GCC49xASL_ARM_RC_PATH = ENV(GCC49_ARM_PREFIX)objcopy
>+*_GCC49xASL_ARM_SYMRENAME_PATH = noop
>+
>+*_GCC49xASL_ARM_ARCHCC_FLAGS = -mthumb
>+*_GCC49xASL_ARM_PLATFORM_FLAGS = -march=armv7-a
>+
>+*_GCC49xASL_ARM_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
>+*_GCC49xASL_ARM_ASLDLINK_FLAGS =
>DEF(GCC49_ARM_ASLDLINK_FLAGS)
>+*_GCC49xASL_ARM_ASM_FLAGS = DEF(GCC49_ARM_ASM_FLAGS)
>+*_GCC49xASL_ARM_DLINK_FLAGS = DEF(GCC49_ARM_DLINK_FLAGS)
>+*_GCC49xASL_ARM_DLINK2_FLAGS = DEF(GCC49_ARM_DLINK2_FLAGS)
>+*_GCC49xASL_ARM_DTCPP_FLAGS = DEF(GCC_DTCPP_FLAGS)
>+*_GCC49xASL_ARM_PLATFORM_FLAGS = -march=armv7-a
>+*_GCC49xASL_ARM_PP_FLAGS = $(ARCHCC_FLAGS)
>$(PLATFORM_FLAGS) DEF(GCC_PP_FLAGS)
>+*_GCC49xASL_ARM_RC_FLAGS = DEF(GCC_ARM_RC_FLAGS)
>+*_GCC49xASL_ARM_VFRPP_FLAGS = $(ARCHCC_FLAGS)
>$(PLATFORM_FLAGS) DEF(GCC_VFRPP_FLAGS)
>+*_GCC49xASL_ARM_CC_XIPFLAGS = DEF(GCC49_ARM_CC_XIPFLAGS)
>+
>+ DEBUG_GCC49xASL_ARM_CC_FLAGS = DEF(GCC49_ARM_CC_FLAGS) -
>O0
>+RELEASE_GCC49xASL_ARM_CC_FLAGS = DEF(GCC49_ARM_CC_FLAGS) -
>Wno-unused-but-set-variable -Wno-unused-const-variable
>+ NOOPT_GCC49xASL_ARM_CC_FLAGS = DEF(GCC49_ARM_CC_FLAGS) -
>O0
>+
>
>###########################################################
>#########################
> #
> # GCC 5 - This configuration is used to compile under Linux to produce
>--
>2.16.2.gvfs.1.33.gf5370f1
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain support
2018-06-25 1:38 ` Gao, Liming
@ 2018-06-25 7:33 ` Ard Biesheuvel
2018-06-25 8:15 ` Gao, Liming
0 siblings, 1 reply; 15+ messages in thread
From: Ard Biesheuvel @ 2018-06-25 7:33 UTC (permalink / raw)
To: Gao, Liming
Cc: Chris Co, edk2-devel@lists.01.org, Leif Lindholm,
Charles Garcia-Tobin
(+ Charles)
On 25 June 2018 at 03:38, Gao, Liming <liming.gao@intel.com> wrote:
> Chris:
> GCC 4.9 targeting arm-none-eabi. This GCC4.9 should run in Windows OS. So, could you give some info where windows GCC49 is from.
>
OK, so first of all, could you elaborate on why we need a different
ASL compiler? We have spent the past 5 years in conference calls and
meeting rooms to standardize ACPI on ARM, so I am rather disappointed
that we have this discrepancy.
Then, could you explain why you chose GCC49? We have GCC5 now as well,
which enables LTO and generally results in smaller code. Also, is
there any way we could parameterize the existing GCCx toolchains to
allow a different ASL compiler to be selected?
Thanks,
Ard.
>>-----Original Message-----
>>From: Chris Co [mailto:Christopher.Co@microsoft.com]
>>Sent: Saturday, June 23, 2018 8:58 AM
>>To: edk2-devel@lists.01.org
>>Cc: Zhu, Yonghong <yonghong.zhu@intel.com>; Gao, Liming
>><liming.gao@intel.com>; Leif Lindholm <leif.lindholm@linaro.org>
>>Subject: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain
>>support
>>
>>From: Chris Co <chrco@microsoft.com>
>>
>>This patch adds a build option for invoking GCC49 ARM cross
>>compiler in the Windows environment to build firmware for
>>Windows 10 IoT devices using NXP i.MX6 and i.MX7 SoCs.
>>
>>In addition, this build option targets the Microsoft ASL
>>compiler instead of iasl. The Microsoft ASL compiler is
>>necessary to expose Windows-specific Pin Function Config
>>Descriptors on Windows IoT devices.
>>
>>Contributed-under: TianoCore Contribution Agreement 1.1
>>Signed-off-by: Christopher Co <christopher.co@microsoft.com>
>>Cc: Yonghong Zhu <yonghong.zhu@intel.com>
>>Cc: Liming Gao <liming.gao@intel.com>
>>Cc: Leif Lindholm <leif.lindholm@linaro.org>
>>---
>> BaseTools/Conf/tools_def.template | 61 ++++++++++++++++++++
>> 1 file changed, 61 insertions(+)
>>
>>diff --git a/BaseTools/Conf/tools_def.template
>>b/BaseTools/Conf/tools_def.template
>>index 11a79029b890..f7a375ebaf1e 100755
>>--- a/BaseTools/Conf/tools_def.template
>>+++ b/BaseTools/Conf/tools_def.template
>>@@ -393,6 +393,12 @@ DEFINE DTC_BIN = ENV(DTC_PREFIX)dtc
>> # Required to build platforms or ACPI tables:
>> # Intel(r) ACPI Compiler from
>> # https://acpica.org/downloads
>>+# GCC49xASL -Windows- Requires:
>>+# GCC 4.9 targeting arm-none-eabi
>>+# Optional:
>>+# Required to build platforms or ACPI tables:
>>+# Microsoft ASL ACPI Compiler (asl.exe) from Windows WDK
>>+# https://docs.microsoft.com/en-us/windows-
>>hardware/drivers/download-the-wdk
>> # GCC5 -Linux,Windows- Requires:
>> # GCC 5 with LTO support, targeting x86_64-linux-gnu, aarch64-
>>linux-gnu, or arm-linux-gnueabi
>> # Optional:
>>@@ -5466,6 +5472,61 @@ RELEASE_GCC49_AARCH64_DLINK_FLAGS =
>>DEF(GCC49_AARCH64_DLINK_FLAGS)
>> NOOPT_GCC49_AARCH64_DLINK_FLAGS =
>>DEF(GCC49_AARCH64_DLINK_FLAGS) -z common-page-size=0x1000 -O0
>> NOOPT_GCC49_AARCH64_DLINK_XIPFLAGS = -z common-page-size=0x20 -
>>O0
>>
>>+##########################################################
>>##########################
>>+#
>>+# GCC49xASL - This configuration is used to compile under Windows to
>>produce
>>+# PE/COFF binaries using GCC 4.9.
>>+#
>>+##########################################################
>>##########################
>>+*_GCC49xASL_*_*_FAMILY = GCC
>>+
>>+*_GCC49xASL_*_MAKE_PATH = DEF(GCC_HOST_PREFIX)make
>>+*_GCC49xASL_*_*_DLL = ENV(GCC49_DLL)
>>+*_GCC49xASL_*_ASL_PATH = DEF(WIN_ASL_BIN)
>>+
>>+*_GCC49xASL_*_PP_FLAGS = DEF(GCC_PP_FLAGS)
>>+*_GCC49xASL_*_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS)
>>+*_GCC49xASL_*_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
>>+*_GCC49xASL_*_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS)
>>+*_GCC49xASL_*_APP_FLAGS =
>>+*_GCC49xASL_*_ASL_FLAGS = /MsftInternal
>>+*_GCC49xASL_*_ASL_OUTFLAGS = DEF(MS_ASL_OUTFLAGS)
>>+
>>+##################
>>+# GCC49xASL ARM definitions
>>+##################
>>+*_GCC49xASL_ARM_OBJCOPY_PATH = noop
>>+*_GCC49xASL_ARM_CC_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>+*_GCC49xASL_ARM_SLINK_PATH = ENV(GCC49_ARM_PREFIX)ar
>>+*_GCC49xASL_ARM_DLINK_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>+*_GCC49xASL_ARM_ASLDLINK_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>+*_GCC49xASL_ARM_ASM_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>+*_GCC49xASL_ARM_PP_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>+*_GCC49xASL_ARM_VFRPP_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>+*_GCC49xASL_ARM_ASLCC_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>+*_GCC49xASL_ARM_ASLPP_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>+*_GCC49xASL_ARM_RC_PATH = ENV(GCC49_ARM_PREFIX)objcopy
>>+*_GCC49xASL_ARM_SYMRENAME_PATH = noop
>>+
>>+*_GCC49xASL_ARM_ARCHCC_FLAGS = -mthumb
>>+*_GCC49xASL_ARM_PLATFORM_FLAGS = -march=armv7-a
>>+
>>+*_GCC49xASL_ARM_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
>>+*_GCC49xASL_ARM_ASLDLINK_FLAGS =
>>DEF(GCC49_ARM_ASLDLINK_FLAGS)
>>+*_GCC49xASL_ARM_ASM_FLAGS = DEF(GCC49_ARM_ASM_FLAGS)
>>+*_GCC49xASL_ARM_DLINK_FLAGS = DEF(GCC49_ARM_DLINK_FLAGS)
>>+*_GCC49xASL_ARM_DLINK2_FLAGS = DEF(GCC49_ARM_DLINK2_FLAGS)
>>+*_GCC49xASL_ARM_DTCPP_FLAGS = DEF(GCC_DTCPP_FLAGS)
>>+*_GCC49xASL_ARM_PLATFORM_FLAGS = -march=armv7-a
>>+*_GCC49xASL_ARM_PP_FLAGS = $(ARCHCC_FLAGS)
>>$(PLATFORM_FLAGS) DEF(GCC_PP_FLAGS)
>>+*_GCC49xASL_ARM_RC_FLAGS = DEF(GCC_ARM_RC_FLAGS)
>>+*_GCC49xASL_ARM_VFRPP_FLAGS = $(ARCHCC_FLAGS)
>>$(PLATFORM_FLAGS) DEF(GCC_VFRPP_FLAGS)
>>+*_GCC49xASL_ARM_CC_XIPFLAGS = DEF(GCC49_ARM_CC_XIPFLAGS)
>>+
>>+ DEBUG_GCC49xASL_ARM_CC_FLAGS = DEF(GCC49_ARM_CC_FLAGS) -
>>O0
>>+RELEASE_GCC49xASL_ARM_CC_FLAGS = DEF(GCC49_ARM_CC_FLAGS) -
>>Wno-unused-but-set-variable -Wno-unused-const-variable
>>+ NOOPT_GCC49xASL_ARM_CC_FLAGS = DEF(GCC49_ARM_CC_FLAGS) -
>>O0
>>+
>>
>>###########################################################
>>#########################
>> #
>> # GCC 5 - This configuration is used to compile under Linux to produce
>>--
>>2.16.2.gvfs.1.33.gf5370f1
>
> _______________________________________________
> edk2-devel mailing list
> edk2-devel@lists.01.org
> https://lists.01.org/mailman/listinfo/edk2-devel
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain support
2018-06-25 7:33 ` Ard Biesheuvel
@ 2018-06-25 8:15 ` Gao, Liming
2018-06-25 18:21 ` Chris Co
0 siblings, 1 reply; 15+ messages in thread
From: Gao, Liming @ 2018-06-25 8:15 UTC (permalink / raw)
To: Ard Biesheuvel
Cc: Chris Co, edk2-devel@lists.01.org, Leif Lindholm,
Charles Garcia-Tobin
Ard:
The commit log message says that the Microsoft ASL compiler is necessary to expose Windows-specific Pin Function Config Descriptors on Windows IoT devices.
Besides, there is no ways to configure tool chain with the parameter in build command. But, tool chain ASL path and flag can be overridden in [BuildOptions] of platform DSC file. Another way is to provide the generic DSC file to include MS ASL option setting in [BuildOptions] section. Platform DSC can decide to include it or not.
Thanks
Liming
>-----Original Message-----
>From: Ard Biesheuvel [mailto:ard.biesheuvel@linaro.org]
>Sent: Monday, June 25, 2018 3:34 PM
>To: Gao, Liming <liming.gao@intel.com>
>Cc: Chris Co <Christopher.Co@microsoft.com>; edk2-devel@lists.01.org; Leif
>Lindholm <leif.lindholm@linaro.org>; Charles Garcia-Tobin <Charles.Garcia-
>Tobin@arm.com>
>Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
>Toolchain support
>
>(+ Charles)
>
>On 25 June 2018 at 03:38, Gao, Liming <liming.gao@intel.com> wrote:
>> Chris:
>> GCC 4.9 targeting arm-none-eabi. This GCC4.9 should run in Windows OS.
>So, could you give some info where windows GCC49 is from.
>>
>
>OK, so first of all, could you elaborate on why we need a different
>ASL compiler? We have spent the past 5 years in conference calls and
>meeting rooms to standardize ACPI on ARM, so I am rather disappointed
>that we have this discrepancy.
>
>Then, could you explain why you chose GCC49? We have GCC5 now as well,
>which enables LTO and generally results in smaller code. Also, is
>there any way we could parameterize the existing GCCx toolchains to
>allow a different ASL compiler to be selected?
>
>Thanks,
>Ard.
>
>
>>>-----Original Message-----
>>>From: Chris Co [mailto:Christopher.Co@microsoft.com]
>>>Sent: Saturday, June 23, 2018 8:58 AM
>>>To: edk2-devel@lists.01.org
>>>Cc: Zhu, Yonghong <yonghong.zhu@intel.com>; Gao, Liming
>>><liming.gao@intel.com>; Leif Lindholm <leif.lindholm@linaro.org>
>>>Subject: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain
>>>support
>>>
>>>From: Chris Co <chrco@microsoft.com>
>>>
>>>This patch adds a build option for invoking GCC49 ARM cross
>>>compiler in the Windows environment to build firmware for
>>>Windows 10 IoT devices using NXP i.MX6 and i.MX7 SoCs.
>>>
>>>In addition, this build option targets the Microsoft ASL
>>>compiler instead of iasl. The Microsoft ASL compiler is
>>>necessary to expose Windows-specific Pin Function Config
>>>Descriptors on Windows IoT devices.
>>>
>>>Contributed-under: TianoCore Contribution Agreement 1.1
>>>Signed-off-by: Christopher Co <christopher.co@microsoft.com>
>>>Cc: Yonghong Zhu <yonghong.zhu@intel.com>
>>>Cc: Liming Gao <liming.gao@intel.com>
>>>Cc: Leif Lindholm <leif.lindholm@linaro.org>
>>>---
>>> BaseTools/Conf/tools_def.template | 61 ++++++++++++++++++++
>>> 1 file changed, 61 insertions(+)
>>>
>>>diff --git a/BaseTools/Conf/tools_def.template
>>>b/BaseTools/Conf/tools_def.template
>>>index 11a79029b890..f7a375ebaf1e 100755
>>>--- a/BaseTools/Conf/tools_def.template
>>>+++ b/BaseTools/Conf/tools_def.template
>>>@@ -393,6 +393,12 @@ DEFINE DTC_BIN = ENV(DTC_PREFIX)dtc
>>> # Required to build platforms or ACPI tables:
>>> # Intel(r) ACPI Compiler from
>>> # https://acpica.org/downloads
>>>+# GCC49xASL -Windows- Requires:
>>>+# GCC 4.9 targeting arm-none-eabi
>>>+# Optional:
>>>+# Required to build platforms or ACPI tables:
>>>+# Microsoft ASL ACPI Compiler (asl.exe) from Windows
>WDK
>>>+# https://docs.microsoft.com/en-us/windows-
>>>hardware/drivers/download-the-wdk
>>> # GCC5 -Linux,Windows- Requires:
>>> # GCC 5 with LTO support, targeting x86_64-linux-gnu,
>aarch64-
>>>linux-gnu, or arm-linux-gnueabi
>>> # Optional:
>>>@@ -5466,6 +5472,61 @@ RELEASE_GCC49_AARCH64_DLINK_FLAGS =
>>>DEF(GCC49_AARCH64_DLINK_FLAGS)
>>> NOOPT_GCC49_AARCH64_DLINK_FLAGS =
>>>DEF(GCC49_AARCH64_DLINK_FLAGS) -z common-page-size=0x1000 -O0
>>> NOOPT_GCC49_AARCH64_DLINK_XIPFLAGS = -z common-page-size=0x20
>-
>>>O0
>>>
>>>+########################################################
>##
>>>##########################
>>>+#
>>>+# GCC49xASL - This configuration is used to compile under Windows to
>>>produce
>>>+# PE/COFF binaries using GCC 4.9.
>>>+#
>>>+########################################################
>##
>>>##########################
>>>+*_GCC49xASL_*_*_FAMILY = GCC
>>>+
>>>+*_GCC49xASL_*_MAKE_PATH = DEF(GCC_HOST_PREFIX)make
>>>+*_GCC49xASL_*_*_DLL = ENV(GCC49_DLL)
>>>+*_GCC49xASL_*_ASL_PATH = DEF(WIN_ASL_BIN)
>>>+
>>>+*_GCC49xASL_*_PP_FLAGS = DEF(GCC_PP_FLAGS)
>>>+*_GCC49xASL_*_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS)
>>>+*_GCC49xASL_*_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
>>>+*_GCC49xASL_*_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS)
>>>+*_GCC49xASL_*_APP_FLAGS =
>>>+*_GCC49xASL_*_ASL_FLAGS = /MsftInternal
>>>+*_GCC49xASL_*_ASL_OUTFLAGS = DEF(MS_ASL_OUTFLAGS)
>>>+
>>>+##################
>>>+# GCC49xASL ARM definitions
>>>+##################
>>>+*_GCC49xASL_ARM_OBJCOPY_PATH = noop
>>>+*_GCC49xASL_ARM_CC_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>>+*_GCC49xASL_ARM_SLINK_PATH = ENV(GCC49_ARM_PREFIX)ar
>>>+*_GCC49xASL_ARM_DLINK_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>>+*_GCC49xASL_ARM_ASLDLINK_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>>+*_GCC49xASL_ARM_ASM_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>>+*_GCC49xASL_ARM_PP_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>>+*_GCC49xASL_ARM_VFRPP_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>>+*_GCC49xASL_ARM_ASLCC_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>>+*_GCC49xASL_ARM_ASLPP_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>>+*_GCC49xASL_ARM_RC_PATH =
>ENV(GCC49_ARM_PREFIX)objcopy
>>>+*_GCC49xASL_ARM_SYMRENAME_PATH = noop
>>>+
>>>+*_GCC49xASL_ARM_ARCHCC_FLAGS = -mthumb
>>>+*_GCC49xASL_ARM_PLATFORM_FLAGS = -march=armv7-a
>>>+
>>>+*_GCC49xASL_ARM_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
>>>+*_GCC49xASL_ARM_ASLDLINK_FLAGS =
>>>DEF(GCC49_ARM_ASLDLINK_FLAGS)
>>>+*_GCC49xASL_ARM_ASM_FLAGS = DEF(GCC49_ARM_ASM_FLAGS)
>>>+*_GCC49xASL_ARM_DLINK_FLAGS =
>DEF(GCC49_ARM_DLINK_FLAGS)
>>>+*_GCC49xASL_ARM_DLINK2_FLAGS =
>DEF(GCC49_ARM_DLINK2_FLAGS)
>>>+*_GCC49xASL_ARM_DTCPP_FLAGS = DEF(GCC_DTCPP_FLAGS)
>>>+*_GCC49xASL_ARM_PLATFORM_FLAGS = -march=armv7-a
>>>+*_GCC49xASL_ARM_PP_FLAGS = $(ARCHCC_FLAGS)
>>>$(PLATFORM_FLAGS) DEF(GCC_PP_FLAGS)
>>>+*_GCC49xASL_ARM_RC_FLAGS = DEF(GCC_ARM_RC_FLAGS)
>>>+*_GCC49xASL_ARM_VFRPP_FLAGS = $(ARCHCC_FLAGS)
>>>$(PLATFORM_FLAGS) DEF(GCC_VFRPP_FLAGS)
>>>+*_GCC49xASL_ARM_CC_XIPFLAGS = DEF(GCC49_ARM_CC_XIPFLAGS)
>>>+
>>>+ DEBUG_GCC49xASL_ARM_CC_FLAGS = DEF(GCC49_ARM_CC_FLAGS)
>-
>>>O0
>>>+RELEASE_GCC49xASL_ARM_CC_FLAGS = DEF(GCC49_ARM_CC_FLAGS)
>-
>>>Wno-unused-but-set-variable -Wno-unused-const-variable
>>>+ NOOPT_GCC49xASL_ARM_CC_FLAGS = DEF(GCC49_ARM_CC_FLAGS)
>-
>>>O0
>>>+
>>>
>>>#########################################################
>##
>>>#########################
>>> #
>>> # GCC 5 - This configuration is used to compile under Linux to produce
>>>--
>>>2.16.2.gvfs.1.33.gf5370f1
>>
>> _______________________________________________
>> edk2-devel mailing list
>> edk2-devel@lists.01.org
>> https://lists.01.org/mailman/listinfo/edk2-devel
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain support
2018-06-25 8:15 ` Gao, Liming
@ 2018-06-25 18:21 ` Chris Co
2018-06-25 19:10 ` Leif Lindholm
2018-06-26 4:40 ` Gao, Liming
0 siblings, 2 replies; 15+ messages in thread
From: Chris Co @ 2018-06-25 18:21 UTC (permalink / raw)
To: Gao, Liming, Ard Biesheuvel
Cc: edk2-devel@lists.01.org, Leif Lindholm, Charles Garcia-Tobin
> -----Original Message-----
> From: Gao, Liming <liming.gao@intel.com>
> Sent: Monday, June 25, 2018 1:15 AM
> To: Ard Biesheuvel <ard.biesheuvel@linaro.org>
> Cc: Chris Co <Christopher.Co@microsoft.com>; edk2-devel@lists.01.org; Leif
> Lindholm <leif.lindholm@linaro.org>; Charles Garcia-Tobin <Charles.Garcia-
> Tobin@arm.com>
> Subject: RE: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
> Toolchain support
>
> Ard:
> The commit log message says that the Microsoft ASL compiler is necessary
> to expose Windows-specific Pin Function Config Descriptors on Windows IoT
> devices.
>
I'll add a bit more detail here. Prior to the inclusion of Pin Function Descriptors in the 6.2 spec, we added a vendor-specific descriptor through the MSFT ASL compiler with /MsftInternal flag which essentially implemented the functionality of the proposed Pin Function Config Descriptors so that pins could be exposed to user-mode applications. Now that the spec is updated and the standard ASL compiler supports the new descriptors, I wanted to move us to the standardized ASL compiler but was disappointed to find out that Windows has not been enlightened to process the Pin Function Config Descriptor yet. So we still need this fall back to the MSFT ASL compiler with /MsftInternal flag while I work with the ACPI team here to implement these descriptors. My hope is that in the next year I can move us back to the standard ASL compiler.
> Besides, there is no ways to configure tool chain with the parameter in build
> command. But, tool chain ASL path and flag can be overridden in
> [BuildOptions] of platform DSC file. Another way is to provide the generic
> DSC file to include MS ASL option setting in [BuildOptions] section. Platform
> DSC can decide to include it or not.
>
Since the MS ASL really only impacts Windows IoT boards, platform dsc overrides on the Windows IoT ARM boards might be a better option here.
> Thanks
> Liming
> >-----Original Message-----
> >From: Ard Biesheuvel [mailto:ard.biesheuvel@linaro.org]
> >Sent: Monday, June 25, 2018 3:34 PM
> >To: Gao, Liming <liming.gao@intel.com>
> >Cc: Chris Co <Christopher.Co@microsoft.com>; edk2-devel@lists.01.org;
> >Leif Lindholm <leif.lindholm@linaro.org>; Charles Garcia-Tobin
> ><Charles.Garcia- Tobin@arm.com>
> >Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
> >Toolchain support
> >
> >(+ Charles)
> >
> >On 25 June 2018 at 03:38, Gao, Liming <liming.gao@intel.com> wrote:
> >> Chris:
> >> GCC 4.9 targeting arm-none-eabi. This GCC4.9 should run in Windows
> OS.
> >So, could you give some info where windows GCC49 is from.
> >>
We get Windows GCC49 from linaro: https://releases.linaro.org/archive/14.09/components/toolchain/binaries/gcc-linaro-arm-none-eabi-4.9-2014.09_win32.zip
Make comes from MinGW
> >
> >OK, so first of all, could you elaborate on why we need a different ASL
> >compiler? We have spent the past 5 years in conference calls and
> >meeting rooms to standardize ACPI on ARM, so I am rather disappointed
> >that we have this discrepancy.
> >
> >Then, could you explain why you chose GCC49? We have GCC5 now as well,
> >which enables LTO and generally results in smaller code. Also, is there
> >any way we could parameterize the existing GCCx toolchains to allow a
> >different ASL compiler to be selected?
> >
We are using GCC49 because this was the last GCC build for Windows as exe we could find. We use these tools to build using GCC on Windows: https://releases.linaro.org/archive/14.09/components/toolchain/binaries/gcc-linaro-arm-none-eabi-4.9-2014.09_win32.zip
I would love to use GCC5 if toolchain exes are readily available for Windows.
There are two main deltas between existing GCCx toolchains and the one I am adding here: ASL compiler delta and echo/noop delta.
The ASL delta was discussed above. We have one more delta: (*_GCC49xASL_ARM_OBJCOPY_PATH = noop, *_GCC49xASL_ARM_SYMRENAME_PATH = noop). On Linux, these are set to `echo` which effectively no-ops them. On Windows, echo behaves differently and unfortunately there's no clean Windows command to noop, so we made a noop.exe program and added it to our build tools. If we can find a way to parameterize the existing GCCx toolchain to select command based on build environment, then I think this patch can be dropped in favor of reusing the existing GCCx chain.
> >Thanks,
> >Ard.
> >
> >
> >>>-----Original Message-----
> >>>From: Chris Co [mailto:Christopher.Co@microsoft.com]
> >>>Sent: Saturday, June 23, 2018 8:58 AM
> >>>To: edk2-devel@lists.01.org
> >>>Cc: Zhu, Yonghong <yonghong.zhu@intel.com>; Gao, Liming
> >>><liming.gao@intel.com>; Leif Lindholm <leif.lindholm@linaro.org>
> >>>Subject: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain
> >>>support
> >>>
> >>>From: Chris Co <chrco@microsoft.com>
> >>>
> >>>This patch adds a build option for invoking GCC49 ARM cross compiler
> >>>in the Windows environment to build firmware for Windows 10 IoT
> >>>devices using NXP i.MX6 and i.MX7 SoCs.
> >>>
> >>>In addition, this build option targets the Microsoft ASL compiler
> >>>instead of iasl. The Microsoft ASL compiler is necessary to expose
> >>>Windows-specific Pin Function Config Descriptors on Windows IoT
> >>>devices.
> >>>
> >>>Contributed-under: TianoCore Contribution Agreement 1.1
> >>>Signed-off-by: Christopher Co <christopher.co@microsoft.com>
> >>>Cc: Yonghong Zhu <yonghong.zhu@intel.com>
> >>>Cc: Liming Gao <liming.gao@intel.com>
> >>>Cc: Leif Lindholm <leif.lindholm@linaro.org>
> >>>---
> >>> BaseTools/Conf/tools_def.template | 61 ++++++++++++++++++++
> >>> 1 file changed, 61 insertions(+)
> >>>
> >>>diff --git a/BaseTools/Conf/tools_def.template
> >>>b/BaseTools/Conf/tools_def.template
> >>>index 11a79029b890..f7a375ebaf1e 100755
> >>>--- a/BaseTools/Conf/tools_def.template
> >>>+++ b/BaseTools/Conf/tools_def.template
> >>>@@ -393,6 +393,12 @@ DEFINE DTC_BIN = ENV(DTC_PREFIX)dtc
> >>> # Required to build platforms or ACPI tables:
> >>> # Intel(r) ACPI Compiler from
> >>> #
> https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Facpica.
> org%2Fdownloads&data=02%7C01%7CChristopher.Co%40microsoft.co
> m%7C04783c7442e045028b6b08d5da73c590%7C72f988bf86f141af91ab2d7cd0
> 11db47%7C1%7C0%7C636655113127087911&sdata=rekWKjfTCvj%2FCv
> mXi%2FtAcEOw7ooGMYGo6uyKoNCL0os%3D&reserved=0
> >>>+# GCC49xASL -Windows- Requires:
> >>>+# GCC 4.9 targeting arm-none-eabi
> >>>+# Optional:
> >>>+# Required to build platforms or ACPI tables:
> >>>+# Microsoft ASL ACPI Compiler (asl.exe) from Windows
> >WDK
> >>>+#
> https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdocs.
> microsoft.com%2Fen-us%2Fwindows-
> &data=02%7C01%7CChristopher.Co%40microsoft.com%7C04783c7442e
> 045028b6b08d5da73c590%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0
> %7C636655113127087911&sdata=OEHhpxkYbIqRmALJeMDjp4RekTgVKG
> 6dlmdmYa3HNOg%3D&reserved=0
> >>>hardware/drivers/download-the-wdk
> >>> # GCC5 -Linux,Windows- Requires:
> >>> # GCC 5 with LTO support, targeting x86_64-linux-gnu,
> >aarch64-
> >>>linux-gnu, or arm-linux-gnueabi
> >>> # Optional:
> >>>@@ -5466,6 +5472,61 @@ RELEASE_GCC49_AARCH64_DLINK_FLAGS =
> >>>DEF(GCC49_AARCH64_DLINK_FLAGS)
> >>> NOOPT_GCC49_AARCH64_DLINK_FLAGS =
> >>>DEF(GCC49_AARCH64_DLINK_FLAGS) -z common-page-size=0x1000 -O0
> >>> NOOPT_GCC49_AARCH64_DLINK_XIPFLAGS = -z common-page-
> size=0x20
> >-
> >>>O0
> >>>
> >>>+######################################################
> ##
> >##
> >>>##########################
> >>>+#
> >>>+# GCC49xASL - This configuration is used to compile under Windows to
> >>>produce
> >>>+# PE/COFF binaries using GCC 4.9.
> >>>+#
> >>>+######################################################
> ##
> >##
> >>>##########################
> >>>+*_GCC49xASL_*_*_FAMILY = GCC
> >>>+
> >>>+*_GCC49xASL_*_MAKE_PATH =
> DEF(GCC_HOST_PREFIX)make
> >>>+*_GCC49xASL_*_*_DLL = ENV(GCC49_DLL)
> >>>+*_GCC49xASL_*_ASL_PATH = DEF(WIN_ASL_BIN)
> >>>+
> >>>+*_GCC49xASL_*_PP_FLAGS = DEF(GCC_PP_FLAGS)
> >>>+*_GCC49xASL_*_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS)
> >>>+*_GCC49xASL_*_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
> >>>+*_GCC49xASL_*_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS)
> >>>+*_GCC49xASL_*_APP_FLAGS =
> >>>+*_GCC49xASL_*_ASL_FLAGS = /MsftInternal
> >>>+*_GCC49xASL_*_ASL_OUTFLAGS = DEF(MS_ASL_OUTFLAGS)
> >>>+
> >>>+##################
> >>>+# GCC49xASL ARM definitions
> >>>+##################
> >>>+*_GCC49xASL_ARM_OBJCOPY_PATH = noop
> >>>+*_GCC49xASL_ARM_CC_PATH = ENV(GCC49_ARM_PREFIX)gcc
> >>>+*_GCC49xASL_ARM_SLINK_PATH = ENV(GCC49_ARM_PREFIX)ar
> >>>+*_GCC49xASL_ARM_DLINK_PATH = ENV(GCC49_ARM_PREFIX)gcc
> >>>+*_GCC49xASL_ARM_ASLDLINK_PATH =
> ENV(GCC49_ARM_PREFIX)gcc
> >>>+*_GCC49xASL_ARM_ASM_PATH = ENV(GCC49_ARM_PREFIX)gcc
> >>>+*_GCC49xASL_ARM_PP_PATH = ENV(GCC49_ARM_PREFIX)gcc
> >>>+*_GCC49xASL_ARM_VFRPP_PATH =
> ENV(GCC49_ARM_PREFIX)gcc
> >>>+*_GCC49xASL_ARM_ASLCC_PATH = ENV(GCC49_ARM_PREFIX)gcc
> >>>+*_GCC49xASL_ARM_ASLPP_PATH = ENV(GCC49_ARM_PREFIX)gcc
> >>>+*_GCC49xASL_ARM_RC_PATH =
> >ENV(GCC49_ARM_PREFIX)objcopy
> >>>+*_GCC49xASL_ARM_SYMRENAME_PATH = noop
> >>>+
> >>>+*_GCC49xASL_ARM_ARCHCC_FLAGS = -mthumb
> >>>+*_GCC49xASL_ARM_PLATFORM_FLAGS = -march=armv7-a
> >>>+
> >>>+*_GCC49xASL_ARM_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
> >>>+*_GCC49xASL_ARM_ASLDLINK_FLAGS =
> >>>DEF(GCC49_ARM_ASLDLINK_FLAGS)
> >>>+*_GCC49xASL_ARM_ASM_FLAGS =
> DEF(GCC49_ARM_ASM_FLAGS)
> >>>+*_GCC49xASL_ARM_DLINK_FLAGS =
> >DEF(GCC49_ARM_DLINK_FLAGS)
> >>>+*_GCC49xASL_ARM_DLINK2_FLAGS =
> >DEF(GCC49_ARM_DLINK2_FLAGS)
> >>>+*_GCC49xASL_ARM_DTCPP_FLAGS = DEF(GCC_DTCPP_FLAGS)
> >>>+*_GCC49xASL_ARM_PLATFORM_FLAGS = -march=armv7-a
> >>>+*_GCC49xASL_ARM_PP_FLAGS = $(ARCHCC_FLAGS)
> >>>$(PLATFORM_FLAGS) DEF(GCC_PP_FLAGS)
> >>>+*_GCC49xASL_ARM_RC_FLAGS = DEF(GCC_ARM_RC_FLAGS)
> >>>+*_GCC49xASL_ARM_VFRPP_FLAGS = $(ARCHCC_FLAGS)
> >>>$(PLATFORM_FLAGS) DEF(GCC_VFRPP_FLAGS)
> >>>+*_GCC49xASL_ARM_CC_XIPFLAGS =
> DEF(GCC49_ARM_CC_XIPFLAGS)
> >>>+
> >>>+ DEBUG_GCC49xASL_ARM_CC_FLAGS =
> DEF(GCC49_ARM_CC_FLAGS)
> >-
> >>>O0
> >>>+RELEASE_GCC49xASL_ARM_CC_FLAGS =
> DEF(GCC49_ARM_CC_FLAGS)
> >-
> >>>Wno-unused-but-set-variable -Wno-unused-const-variable
> >>>+ NOOPT_GCC49xASL_ARM_CC_FLAGS =
> DEF(GCC49_ARM_CC_FLAGS)
> >-
> >>>O0
> >>>+
> >>>
> >>>#######################################################
> ##
> >##
> >>>#########################
> >>> #
> >>> # GCC 5 - This configuration is used to compile under Linux to
> >>>produce
> >>>--
> >>>2.16.2.gvfs.1.33.gf5370f1
> >>
> >> _______________________________________________
> >> edk2-devel mailing list
> >> edk2-devel@lists.01.org
> >> https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flist
> >> s.01.org%2Fmailman%2Flistinfo%2Fedk2-
> devel&data=02%7C01%7CChristo
> >>
> pher.Co%40microsoft.com%7C04783c7442e045028b6b08d5da73c590%7C72f9
> 88bf
> >>
> 86f141af91ab2d7cd011db47%7C1%7C0%7C636655113127087911&sdata=
> WLQCR
> >> O6Olja0J14OBnX1PSsdXnTYEXDMki9fN7CuAHs%3D&reserved=0
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain support
2018-06-25 18:21 ` Chris Co
@ 2018-06-25 19:10 ` Leif Lindholm
2018-06-25 19:50 ` Chris Co
2018-06-26 4:40 ` Gao, Liming
1 sibling, 1 reply; 15+ messages in thread
From: Leif Lindholm @ 2018-06-25 19:10 UTC (permalink / raw)
To: Chris Co; +Cc: Ard Biesheuvel, edk2-devel@lists.01.org, Charles Garcia-Tobin
On Mon, Jun 25, 2018 at 06:21:27PM +0000, Chris Co wrote:
> > >-----Original Message-----
> > >From: Ard Biesheuvel [mailto:ard.biesheuvel@linaro.org]
> > >Sent: Monday, June 25, 2018 3:34 PM
> > >To: Gao, Liming <liming.gao@intel.com>
> > >Cc: Chris Co <Christopher.Co@microsoft.com>; edk2-devel@lists.01.org;
> > >Leif Lindholm <leif.lindholm@linaro.org>; Charles Garcia-Tobin
> > ><Charles.Garcia- Tobin@arm.com>
> > >Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
> > >Toolchain support
> > >
> > >(+ Charles)
> > >
> > >On 25 June 2018 at 03:38, Gao, Liming <liming.gao@intel.com> wrote:
> > >> Chris:
> > >> GCC 4.9 targeting arm-none-eabi. This GCC4.9 should run in Windows
> > OS.
> > >So, could you give some info where windows GCC49 is from.
> > >>
>
> We get Windows GCC49 from linaro: https://releases.linaro.org/archive/14.09/components/toolchain/binaries/gcc-linaro-arm-none-eabi-4.9-2014.09_win32.zip
> Make comes from MinGW
>
> > >
> > >OK, so first of all, could you elaborate on why we need a different ASL
> > >compiler? We have spent the past 5 years in conference calls and
> > >meeting rooms to standardize ACPI on ARM, so I am rather disappointed
> > >that we have this discrepancy.
> > >
> > >Then, could you explain why you chose GCC49? We have GCC5 now as well,
> > >which enables LTO and generally results in smaller code. Also, is there
> > >any way we could parameterize the existing GCCx toolchains to allow a
> > >different ASL compiler to be selected?
> > >
>
> We are using GCC49 because this was the last GCC build for Windows as exe we could find. We use these tools to build using GCC on Windows: https://releases.linaro.org/archive/14.09/components/toolchain/binaries/gcc-linaro-arm-none-eabi-4.9-2014.09_win32.zip
> I would love to use GCC5 if toolchain exes are readily available for Windows.
We can do better than that:
https://releases.linaro.org/components/toolchain/binaries/7.3-2018.05/arm-eabi/gcc-linaro-7.3.1-2018.05-i686-mingw32_arm-eabi.tar.xz
Should build with GCC5 profile.
/
Leif
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain support
2018-06-25 19:10 ` Leif Lindholm
@ 2018-06-25 19:50 ` Chris Co
0 siblings, 0 replies; 15+ messages in thread
From: Chris Co @ 2018-06-25 19:50 UTC (permalink / raw)
To: Leif Lindholm
Cc: Ard Biesheuvel, edk2-devel@lists.01.org, Charles Garcia-Tobin
> -----Original Message-----
> From: Leif Lindholm <leif.lindholm@linaro.org>
> Sent: Monday, June 25, 2018 12:10 PM
> To: Chris Co <Christopher.Co@microsoft.com>
> Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org>; edk2-devel@lists.01.org;
> Charles Garcia-Tobin <Charles.Garcia-Tobin@arm.com>
> Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
> Toolchain support
>
> On Mon, Jun 25, 2018 at 06:21:27PM +0000, Chris Co wrote:
> > > >-----Original Message-----
> > > >From: Ard Biesheuvel [mailto:ard.biesheuvel@linaro.org]
> > > >Sent: Monday, June 25, 2018 3:34 PM
> > > >To: Gao, Liming <liming.gao@intel.com>
> > > >Cc: Chris Co <Christopher.Co@microsoft.com>;
> > > >edk2-devel@lists.01.org; Leif Lindholm <leif.lindholm@linaro.org>;
> > > >Charles Garcia-Tobin
> > > ><Charles.Garcia- Tobin@arm.com>
> > > >Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add
> > > >GCC49xASL Toolchain support
> > > >
> > > >(+ Charles)
> > > >
> > > >On 25 June 2018 at 03:38, Gao, Liming <liming.gao@intel.com> wrote:
> > > >> Chris:
> > > >> GCC 4.9 targeting arm-none-eabi. This GCC4.9 should run in
> > > >> Windows
> > > OS.
> > > >So, could you give some info where windows GCC49 is from.
> > > >>
> >
> > We get Windows GCC49 from linaro:
> >
> https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Frelea
> >
> ses.linaro.org%2Farchive%2F14.09%2Fcomponents%2Ftoolchain%2Fbinaries
> %2
> > Fgcc-linaro-arm-none-eabi-4.9-
> 2014.09_win32.zip&data=02%7C01%7CChr
> >
> istopher.Co%40microsoft.com%7Ca9d03e6d31b549abfc2808d5dacf49f1%7C7
> 2f98
> >
> 8bf86f141af91ab2d7cd011db47%7C1%7C0%7C636655506193987833&sda
> ta=ZCa
> >
> 5y37luGBu2wG%2FUWUG2ZQ4Npts0JlXqS1AAZjgbZE%3D&reserved=0
> > Make comes from MinGW
> >
> > > >
> > > >OK, so first of all, could you elaborate on why we need a different
> > > >ASL compiler? We have spent the past 5 years in conference calls
> > > >and meeting rooms to standardize ACPI on ARM, so I am rather
> > > >disappointed that we have this discrepancy.
> > > >
> > > >Then, could you explain why you chose GCC49? We have GCC5 now as
> > > >well, which enables LTO and generally results in smaller code.
> > > >Also, is there any way we could parameterize the existing GCCx
> > > >toolchains to allow a different ASL compiler to be selected?
> > > >
> >
> > We are using GCC49 because this was the last GCC build for Windows as
> > exe we could find. We use these tools to build using GCC on Windows:
> >
> https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Frelea
> >
> ses.linaro.org%2Farchive%2F14.09%2Fcomponents%2Ftoolchain%2Fbinaries
> %2
> > Fgcc-linaro-arm-none-eabi-4.9-
> 2014.09_win32.zip&data=02%7C01%7CChr
> >
> istopher.Co%40microsoft.com%7Ca9d03e6d31b549abfc2808d5dacf49f1%7C7
> 2f98
> >
> 8bf86f141af91ab2d7cd011db47%7C1%7C0%7C636655506193987833&sda
> ta=ZCa
> >
> 5y37luGBu2wG%2FUWUG2ZQ4Npts0JlXqS1AAZjgbZE%3D&reserved=0
> > I would love to use GCC5 if toolchain exes are readily available for
> Windows.
>
> We can do better than that:
> https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Freleas
> es.linaro.org%2Fcomponents%2Ftoolchain%2Fbinaries%2F7.3-
> 2018.05%2Farm-eabi%2Fgcc-linaro-7.3.1-2018.05-i686-mingw32_arm-
> eabi.tar.xz&data=02%7C01%7CChristopher.Co%40microsoft.com%7Ca9
> d03e6d31b549abfc2808d5dacf49f1%7C72f988bf86f141af91ab2d7cd011db47%
> 7C1%7C0%7C636655506193987833&sdata=Xzo1HRrUAqyovKFyWCVXDa
> nTwaA7hKBhkFo14UzslGc%3D&reserved=0
> Should build with GCC5 profile.
>
Thanks Leif for the pointer! There was some trepidation on using MinGW in the past, though admittedly I wasn't around when those decisions were made and it always confused me... Anyways, I will try out the GCC7.3 toolchain with the GCC5 profile.
> /
> Leif
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain support
2018-06-25 18:21 ` Chris Co
2018-06-25 19:10 ` Leif Lindholm
@ 2018-06-26 4:40 ` Gao, Liming
2018-06-26 8:22 ` Ard Biesheuvel
1 sibling, 1 reply; 15+ messages in thread
From: Gao, Liming @ 2018-06-26 4:40 UTC (permalink / raw)
To: Chris Co, Ard Biesheuvel
Cc: edk2-devel@lists.01.org, Leif Lindholm, Charles Garcia-Tobin
Chris:
Here is the example usage. You can add below [BuildOptions] in your platform DSC. Then, it will use override ASL path and flag.
[BuildOptions]
*_*_*_ASL_PATH == C:\Asl\asl.exe
*_*_*_ASL_FLAGS == /MsftInternal
*_*_*_ASL_OUTFLAGS == /Fo=
Thanks
Liming
>-----Original Message-----
>From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of
>Chris Co
>Sent: Tuesday, June 26, 2018 2:21 AM
>To: Gao, Liming <liming.gao@intel.com>; Ard Biesheuvel
><ard.biesheuvel@linaro.org>
>Cc: edk2-devel@lists.01.org; Leif Lindholm <leif.lindholm@linaro.org>; Charles
>Garcia-Tobin <Charles.Garcia-Tobin@arm.com>
>Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
>Toolchain support
>
>
>
>> -----Original Message-----
>> From: Gao, Liming <liming.gao@intel.com>
>> Sent: Monday, June 25, 2018 1:15 AM
>> To: Ard Biesheuvel <ard.biesheuvel@linaro.org>
>> Cc: Chris Co <Christopher.Co@microsoft.com>; edk2-devel@lists.01.org; Leif
>> Lindholm <leif.lindholm@linaro.org>; Charles Garcia-Tobin <Charles.Garcia-
>> Tobin@arm.com>
>> Subject: RE: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
>> Toolchain support
>>
>> Ard:
>> The commit log message says that the Microsoft ASL compiler is necessary
>> to expose Windows-specific Pin Function Config Descriptors on Windows IoT
>> devices.
>>
>
>I'll add a bit more detail here. Prior to the inclusion of Pin Function Descriptors
>in the 6.2 spec, we added a vendor-specific descriptor through the MSFT ASL
>compiler with /MsftInternal flag which essentially implemented the
>functionality of the proposed Pin Function Config Descriptors so that pins
>could be exposed to user-mode applications. Now that the spec is updated
>and the standard ASL compiler supports the new descriptors, I wanted to
>move us to the standardized ASL compiler but was disappointed to find out
>that Windows has not been enlightened to process the Pin Function Config
>Descriptor yet. So we still need this fall back to the MSFT ASL compiler with
>/MsftInternal flag while I work with the ACPI team here to implement these
>descriptors. My hope is that in the next year I can move us back to the
>standard ASL compiler.
>
>> Besides, there is no ways to configure tool chain with the parameter in
>build
>> command. But, tool chain ASL path and flag can be overridden in
>> [BuildOptions] of platform DSC file. Another way is to provide the generic
>> DSC file to include MS ASL option setting in [BuildOptions] section. Platform
>> DSC can decide to include it or not.
>>
>
>Since the MS ASL really only impacts Windows IoT boards, platform dsc
>overrides on the Windows IoT ARM boards might be a better option here.
>
>> Thanks
>> Liming
>> >-----Original Message-----
>> >From: Ard Biesheuvel [mailto:ard.biesheuvel@linaro.org]
>> >Sent: Monday, June 25, 2018 3:34 PM
>> >To: Gao, Liming <liming.gao@intel.com>
>> >Cc: Chris Co <Christopher.Co@microsoft.com>; edk2-devel@lists.01.org;
>> >Leif Lindholm <leif.lindholm@linaro.org>; Charles Garcia-Tobin
>> ><Charles.Garcia- Tobin@arm.com>
>> >Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
>> >Toolchain support
>> >
>> >(+ Charles)
>> >
>> >On 25 June 2018 at 03:38, Gao, Liming <liming.gao@intel.com> wrote:
>> >> Chris:
>> >> GCC 4.9 targeting arm-none-eabi. This GCC4.9 should run in Windows
>> OS.
>> >So, could you give some info where windows GCC49 is from.
>> >>
>
>We get Windows GCC49 from linaro:
>https://releases.linaro.org/archive/14.09/components/toolchain/binaries/gcc
>-linaro-arm-none-eabi-4.9-2014.09_win32.zip
>Make comes from MinGW
>
>> >
>> >OK, so first of all, could you elaborate on why we need a different ASL
>> >compiler? We have spent the past 5 years in conference calls and
>> >meeting rooms to standardize ACPI on ARM, so I am rather disappointed
>> >that we have this discrepancy.
>> >
>> >Then, could you explain why you chose GCC49? We have GCC5 now as well,
>> >which enables LTO and generally results in smaller code. Also, is there
>> >any way we could parameterize the existing GCCx toolchains to allow a
>> >different ASL compiler to be selected?
>> >
>
>We are using GCC49 because this was the last GCC build for Windows as exe
>we could find. We use these tools to build using GCC on Windows:
>https://releases.linaro.org/archive/14.09/components/toolchain/binaries/gcc
>-linaro-arm-none-eabi-4.9-2014.09_win32.zip
>I would love to use GCC5 if toolchain exes are readily available for Windows.
>
>There are two main deltas between existing GCCx toolchains and the one I am
>adding here: ASL compiler delta and echo/noop delta.
>The ASL delta was discussed above. We have one more delta:
>(*_GCC49xASL_ARM_OBJCOPY_PATH = noop,
>*_GCC49xASL_ARM_SYMRENAME_PATH = noop). On Linux, these are set
>to `echo` which effectively no-ops them. On Windows, echo behaves
>differently and unfortunately there's no clean Windows command to noop, so
>we made a noop.exe program and added it to our build tools. If we can find a
>way to parameterize the existing GCCx toolchain to select command based on
>build environment, then I think this patch can be dropped in favor of reusing
>the existing GCCx chain.
>
>> >Thanks,
>> >Ard.
>> >
>> >
>> >>>-----Original Message-----
>> >>>From: Chris Co [mailto:Christopher.Co@microsoft.com]
>> >>>Sent: Saturday, June 23, 2018 8:58 AM
>> >>>To: edk2-devel@lists.01.org
>> >>>Cc: Zhu, Yonghong <yonghong.zhu@intel.com>; Gao, Liming
>> >>><liming.gao@intel.com>; Leif Lindholm <leif.lindholm@linaro.org>
>> >>>Subject: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain
>> >>>support
>> >>>
>> >>>From: Chris Co <chrco@microsoft.com>
>> >>>
>> >>>This patch adds a build option for invoking GCC49 ARM cross compiler
>> >>>in the Windows environment to build firmware for Windows 10 IoT
>> >>>devices using NXP i.MX6 and i.MX7 SoCs.
>> >>>
>> >>>In addition, this build option targets the Microsoft ASL compiler
>> >>>instead of iasl. The Microsoft ASL compiler is necessary to expose
>> >>>Windows-specific Pin Function Config Descriptors on Windows IoT
>> >>>devices.
>> >>>
>> >>>Contributed-under: TianoCore Contribution Agreement 1.1
>> >>>Signed-off-by: Christopher Co <christopher.co@microsoft.com>
>> >>>Cc: Yonghong Zhu <yonghong.zhu@intel.com>
>> >>>Cc: Liming Gao <liming.gao@intel.com>
>> >>>Cc: Leif Lindholm <leif.lindholm@linaro.org>
>> >>>---
>> >>> BaseTools/Conf/tools_def.template | 61 ++++++++++++++++++++
>> >>> 1 file changed, 61 insertions(+)
>> >>>
>> >>>diff --git a/BaseTools/Conf/tools_def.template
>> >>>b/BaseTools/Conf/tools_def.template
>> >>>index 11a79029b890..f7a375ebaf1e 100755
>> >>>--- a/BaseTools/Conf/tools_def.template
>> >>>+++ b/BaseTools/Conf/tools_def.template
>> >>>@@ -393,6 +393,12 @@ DEFINE DTC_BIN = ENV(DTC_PREFIX)dtc
>> >>> # Required to build platforms or ACPI tables:
>> >>> # Intel(r) ACPI Compiler from
>> >>> #
>>
>https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Facpica.
>> org%2Fdownloads&data=02%7C01%7CChristopher.Co%40microsoft.co
>>
>m%7C04783c7442e045028b6b08d5da73c590%7C72f988bf86f141af91ab2d7cd0
>> 11db47%7C1%7C0%7C636655113127087911&sdata=rekWKjfTCvj%2FCv
>> mXi%2FtAcEOw7ooGMYGo6uyKoNCL0os%3D&reserved=0
>> >>>+# GCC49xASL -Windows- Requires:
>> >>>+# GCC 4.9 targeting arm-none-eabi
>> >>>+# Optional:
>> >>>+# Required to build platforms or ACPI tables:
>> >>>+# Microsoft ASL ACPI Compiler (asl.exe) from Windows
>> >WDK
>> >>>+#
>> https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdocs.
>> microsoft.com%2Fen-us%2Fwindows-
>> &data=02%7C01%7CChristopher.Co%40microsoft.com%7C04783c7442e
>> 045028b6b08d5da73c590%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0
>> %7C636655113127087911&sdata=OEHhpxkYbIqRmALJeMDjp4RekTgVK
>G
>> 6dlmdmYa3HNOg%3D&reserved=0
>> >>>hardware/drivers/download-the-wdk
>> >>> # GCC5 -Linux,Windows- Requires:
>> >>> # GCC 5 with LTO support, targeting x86_64-linux-gnu,
>> >aarch64-
>> >>>linux-gnu, or arm-linux-gnueabi
>> >>> # Optional:
>> >>>@@ -5466,6 +5472,61 @@ RELEASE_GCC49_AARCH64_DLINK_FLAGS =
>> >>>DEF(GCC49_AARCH64_DLINK_FLAGS)
>> >>> NOOPT_GCC49_AARCH64_DLINK_FLAGS =
>> >>>DEF(GCC49_AARCH64_DLINK_FLAGS) -z common-page-size=0x1000 -O0
>> >>> NOOPT_GCC49_AARCH64_DLINK_XIPFLAGS = -z common-page-
>> size=0x20
>> >-
>> >>>O0
>> >>>
>> >>>+######################################################
>> ##
>> >##
>> >>>##########################
>> >>>+#
>> >>>+# GCC49xASL - This configuration is used to compile under Windows to
>> >>>produce
>> >>>+# PE/COFF binaries using GCC 4.9.
>> >>>+#
>> >>>+######################################################
>> ##
>> >##
>> >>>##########################
>> >>>+*_GCC49xASL_*_*_FAMILY = GCC
>> >>>+
>> >>>+*_GCC49xASL_*_MAKE_PATH =
>> DEF(GCC_HOST_PREFIX)make
>> >>>+*_GCC49xASL_*_*_DLL = ENV(GCC49_DLL)
>> >>>+*_GCC49xASL_*_ASL_PATH = DEF(WIN_ASL_BIN)
>> >>>+
>> >>>+*_GCC49xASL_*_PP_FLAGS = DEF(GCC_PP_FLAGS)
>> >>>+*_GCC49xASL_*_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS)
>> >>>+*_GCC49xASL_*_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
>> >>>+*_GCC49xASL_*_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS)
>> >>>+*_GCC49xASL_*_APP_FLAGS =
>> >>>+*_GCC49xASL_*_ASL_FLAGS = /MsftInternal
>> >>>+*_GCC49xASL_*_ASL_OUTFLAGS = DEF(MS_ASL_OUTFLAGS)
>> >>>+
>> >>>+##################
>> >>>+# GCC49xASL ARM definitions
>> >>>+##################
>> >>>+*_GCC49xASL_ARM_OBJCOPY_PATH = noop
>> >>>+*_GCC49xASL_ARM_CC_PATH = ENV(GCC49_ARM_PREFIX)gcc
>> >>>+*_GCC49xASL_ARM_SLINK_PATH = ENV(GCC49_ARM_PREFIX)ar
>> >>>+*_GCC49xASL_ARM_DLINK_PATH =
>ENV(GCC49_ARM_PREFIX)gcc
>> >>>+*_GCC49xASL_ARM_ASLDLINK_PATH =
>> ENV(GCC49_ARM_PREFIX)gcc
>> >>>+*_GCC49xASL_ARM_ASM_PATH =
>ENV(GCC49_ARM_PREFIX)gcc
>> >>>+*_GCC49xASL_ARM_PP_PATH = ENV(GCC49_ARM_PREFIX)gcc
>> >>>+*_GCC49xASL_ARM_VFRPP_PATH =
>> ENV(GCC49_ARM_PREFIX)gcc
>> >>>+*_GCC49xASL_ARM_ASLCC_PATH =
>ENV(GCC49_ARM_PREFIX)gcc
>> >>>+*_GCC49xASL_ARM_ASLPP_PATH =
>ENV(GCC49_ARM_PREFIX)gcc
>> >>>+*_GCC49xASL_ARM_RC_PATH =
>> >ENV(GCC49_ARM_PREFIX)objcopy
>> >>>+*_GCC49xASL_ARM_SYMRENAME_PATH = noop
>> >>>+
>> >>>+*_GCC49xASL_ARM_ARCHCC_FLAGS = -mthumb
>> >>>+*_GCC49xASL_ARM_PLATFORM_FLAGS = -march=armv7-a
>> >>>+
>> >>>+*_GCC49xASL_ARM_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
>> >>>+*_GCC49xASL_ARM_ASLDLINK_FLAGS =
>> >>>DEF(GCC49_ARM_ASLDLINK_FLAGS)
>> >>>+*_GCC49xASL_ARM_ASM_FLAGS =
>> DEF(GCC49_ARM_ASM_FLAGS)
>> >>>+*_GCC49xASL_ARM_DLINK_FLAGS =
>> >DEF(GCC49_ARM_DLINK_FLAGS)
>> >>>+*_GCC49xASL_ARM_DLINK2_FLAGS =
>> >DEF(GCC49_ARM_DLINK2_FLAGS)
>> >>>+*_GCC49xASL_ARM_DTCPP_FLAGS = DEF(GCC_DTCPP_FLAGS)
>> >>>+*_GCC49xASL_ARM_PLATFORM_FLAGS = -march=armv7-a
>> >>>+*_GCC49xASL_ARM_PP_FLAGS = $(ARCHCC_FLAGS)
>> >>>$(PLATFORM_FLAGS) DEF(GCC_PP_FLAGS)
>> >>>+*_GCC49xASL_ARM_RC_FLAGS = DEF(GCC_ARM_RC_FLAGS)
>> >>>+*_GCC49xASL_ARM_VFRPP_FLAGS = $(ARCHCC_FLAGS)
>> >>>$(PLATFORM_FLAGS) DEF(GCC_VFRPP_FLAGS)
>> >>>+*_GCC49xASL_ARM_CC_XIPFLAGS =
>> DEF(GCC49_ARM_CC_XIPFLAGS)
>> >>>+
>> >>>+ DEBUG_GCC49xASL_ARM_CC_FLAGS =
>> DEF(GCC49_ARM_CC_FLAGS)
>> >-
>> >>>O0
>> >>>+RELEASE_GCC49xASL_ARM_CC_FLAGS =
>> DEF(GCC49_ARM_CC_FLAGS)
>> >-
>> >>>Wno-unused-but-set-variable -Wno-unused-const-variable
>> >>>+ NOOPT_GCC49xASL_ARM_CC_FLAGS =
>> DEF(GCC49_ARM_CC_FLAGS)
>> >-
>> >>>O0
>> >>>+
>> >>>
>> >>>#######################################################
>> ##
>> >##
>> >>>#########################
>> >>> #
>> >>> # GCC 5 - This configuration is used to compile under Linux to
>> >>>produce
>> >>>--
>> >>>2.16.2.gvfs.1.33.gf5370f1
>> >>
>> >> _______________________________________________
>> >> edk2-devel mailing list
>> >> edk2-devel@lists.01.org
>> >> https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flist
>> >> s.01.org%2Fmailman%2Flistinfo%2Fedk2-
>> devel&data=02%7C01%7CChristo
>> >>
>>
>pher.Co%40microsoft.com%7C04783c7442e045028b6b08d5da73c590%7C72f9
>> 88bf
>> >>
>>
>86f141af91ab2d7cd011db47%7C1%7C0%7C636655113127087911&sdata=
>> WLQCR
>> >> O6Olja0J14OBnX1PSsdXnTYEXDMki9fN7CuAHs%3D&reserved=0
>_______________________________________________
>edk2-devel mailing list
>edk2-devel@lists.01.org
>https://lists.01.org/mailman/listinfo/edk2-devel
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain support
2018-06-26 4:40 ` Gao, Liming
@ 2018-06-26 8:22 ` Ard Biesheuvel
2018-06-26 18:42 ` Chris Co
0 siblings, 1 reply; 15+ messages in thread
From: Ard Biesheuvel @ 2018-06-26 8:22 UTC (permalink / raw)
To: Gao, Liming
Cc: Chris Co, edk2-devel@lists.01.org, Leif Lindholm,
Charles Garcia-Tobin
On 26 June 2018 at 06:40, Gao, Liming <liming.gao@intel.com> wrote:
> Chris:
> Here is the example usage. You can add below [BuildOptions] in your platform DSC. Then, it will use override ASL path and flag.
>
> [BuildOptions]
> *_*_*_ASL_PATH == C:\Asl\asl.exe
> *_*_*_ASL_FLAGS == /MsftInternal
> *_*_*_ASL_OUTFLAGS == /Fo=
>
I strongly prefer this over adding a new MS specific toolchain definition.
>>-----Original Message-----
>>From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of
>>Chris Co
>>Sent: Tuesday, June 26, 2018 2:21 AM
>>To: Gao, Liming <liming.gao@intel.com>; Ard Biesheuvel
>><ard.biesheuvel@linaro.org>
>>Cc: edk2-devel@lists.01.org; Leif Lindholm <leif.lindholm@linaro.org>; Charles
>>Garcia-Tobin <Charles.Garcia-Tobin@arm.com>
>>Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
>>Toolchain support
>>
>>
>>
>>> -----Original Message-----
>>> From: Gao, Liming <liming.gao@intel.com>
>>> Sent: Monday, June 25, 2018 1:15 AM
>>> To: Ard Biesheuvel <ard.biesheuvel@linaro.org>
>>> Cc: Chris Co <Christopher.Co@microsoft.com>; edk2-devel@lists.01.org; Leif
>>> Lindholm <leif.lindholm@linaro.org>; Charles Garcia-Tobin <Charles.Garcia-
>>> Tobin@arm.com>
>>> Subject: RE: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
>>> Toolchain support
>>>
>>> Ard:
>>> The commit log message says that the Microsoft ASL compiler is necessary
>>> to expose Windows-specific Pin Function Config Descriptors on Windows IoT
>>> devices.
>>>
>>
>>I'll add a bit more detail here. Prior to the inclusion of Pin Function Descriptors
>>in the 6.2 spec, we added a vendor-specific descriptor through the MSFT ASL
>>compiler with /MsftInternal flag which essentially implemented the
>>functionality of the proposed Pin Function Config Descriptors so that pins
>>could be exposed to user-mode applications. Now that the spec is updated
>>and the standard ASL compiler supports the new descriptors, I wanted to
>>move us to the standardized ASL compiler but was disappointed to find out
>>that Windows has not been enlightened to process the Pin Function Config
>>Descriptor yet. So we still need this fall back to the MSFT ASL compiler with
>>/MsftInternal flag while I work with the ACPI team here to implement these
>>descriptors. My hope is that in the next year I can move us back to the
>>standard ASL compiler.
>>
>>> Besides, there is no ways to configure tool chain with the parameter in
>>build
>>> command. But, tool chain ASL path and flag can be overridden in
>>> [BuildOptions] of platform DSC file. Another way is to provide the generic
>>> DSC file to include MS ASL option setting in [BuildOptions] section. Platform
>>> DSC can decide to include it or not.
>>>
>>
>>Since the MS ASL really only impacts Windows IoT boards, platform dsc
>>overrides on the Windows IoT ARM boards might be a better option here.
>>
>>> Thanks
>>> Liming
>>> >-----Original Message-----
>>> >From: Ard Biesheuvel [mailto:ard.biesheuvel@linaro.org]
>>> >Sent: Monday, June 25, 2018 3:34 PM
>>> >To: Gao, Liming <liming.gao@intel.com>
>>> >Cc: Chris Co <Christopher.Co@microsoft.com>; edk2-devel@lists.01.org;
>>> >Leif Lindholm <leif.lindholm@linaro.org>; Charles Garcia-Tobin
>>> ><Charles.Garcia- Tobin@arm.com>
>>> >Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
>>> >Toolchain support
>>> >
>>> >(+ Charles)
>>> >
>>> >On 25 June 2018 at 03:38, Gao, Liming <liming.gao@intel.com> wrote:
>>> >> Chris:
>>> >> GCC 4.9 targeting arm-none-eabi. This GCC4.9 should run in Windows
>>> OS.
>>> >So, could you give some info where windows GCC49 is from.
>>> >>
>>
>>We get Windows GCC49 from linaro:
>>https://releases.linaro.org/archive/14.09/components/toolchain/binaries/gcc
>>-linaro-arm-none-eabi-4.9-2014.09_win32.zip
>>Make comes from MinGW
>>
>>> >
>>> >OK, so first of all, could you elaborate on why we need a different ASL
>>> >compiler? We have spent the past 5 years in conference calls and
>>> >meeting rooms to standardize ACPI on ARM, so I am rather disappointed
>>> >that we have this discrepancy.
>>> >
>>> >Then, could you explain why you chose GCC49? We have GCC5 now as well,
>>> >which enables LTO and generally results in smaller code. Also, is there
>>> >any way we could parameterize the existing GCCx toolchains to allow a
>>> >different ASL compiler to be selected?
>>> >
>>
>>We are using GCC49 because this was the last GCC build for Windows as exe
>>we could find. We use these tools to build using GCC on Windows:
>>https://releases.linaro.org/archive/14.09/components/toolchain/binaries/gcc
>>-linaro-arm-none-eabi-4.9-2014.09_win32.zip
>>I would love to use GCC5 if toolchain exes are readily available for Windows.
>>
>>There are two main deltas between existing GCCx toolchains and the one I am
>>adding here: ASL compiler delta and echo/noop delta.
>>The ASL delta was discussed above. We have one more delta:
>>(*_GCC49xASL_ARM_OBJCOPY_PATH = noop,
>>*_GCC49xASL_ARM_SYMRENAME_PATH = noop). On Linux, these are set
>>to `echo` which effectively no-ops them. On Windows, echo behaves
>>differently and unfortunately there's no clean Windows command to noop, so
>>we made a noop.exe program and added it to our build tools. If we can find a
>>way to parameterize the existing GCCx toolchain to select command based on
>>build environment, then I think this patch can be dropped in favor of reusing
>>the existing GCCx chain.
>>
>>> >Thanks,
>>> >Ard.
>>> >
>>> >
>>> >>>-----Original Message-----
>>> >>>From: Chris Co [mailto:Christopher.Co@microsoft.com]
>>> >>>Sent: Saturday, June 23, 2018 8:58 AM
>>> >>>To: edk2-devel@lists.01.org
>>> >>>Cc: Zhu, Yonghong <yonghong.zhu@intel.com>; Gao, Liming
>>> >>><liming.gao@intel.com>; Leif Lindholm <leif.lindholm@linaro.org>
>>> >>>Subject: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain
>>> >>>support
>>> >>>
>>> >>>From: Chris Co <chrco@microsoft.com>
>>> >>>
>>> >>>This patch adds a build option for invoking GCC49 ARM cross compiler
>>> >>>in the Windows environment to build firmware for Windows 10 IoT
>>> >>>devices using NXP i.MX6 and i.MX7 SoCs.
>>> >>>
>>> >>>In addition, this build option targets the Microsoft ASL compiler
>>> >>>instead of iasl. The Microsoft ASL compiler is necessary to expose
>>> >>>Windows-specific Pin Function Config Descriptors on Windows IoT
>>> >>>devices.
>>> >>>
>>> >>>Contributed-under: TianoCore Contribution Agreement 1.1
>>> >>>Signed-off-by: Christopher Co <christopher.co@microsoft.com>
>>> >>>Cc: Yonghong Zhu <yonghong.zhu@intel.com>
>>> >>>Cc: Liming Gao <liming.gao@intel.com>
>>> >>>Cc: Leif Lindholm <leif.lindholm@linaro.org>
>>> >>>---
>>> >>> BaseTools/Conf/tools_def.template | 61 ++++++++++++++++++++
>>> >>> 1 file changed, 61 insertions(+)
>>> >>>
>>> >>>diff --git a/BaseTools/Conf/tools_def.template
>>> >>>b/BaseTools/Conf/tools_def.template
>>> >>>index 11a79029b890..f7a375ebaf1e 100755
>>> >>>--- a/BaseTools/Conf/tools_def.template
>>> >>>+++ b/BaseTools/Conf/tools_def.template
>>> >>>@@ -393,6 +393,12 @@ DEFINE DTC_BIN = ENV(DTC_PREFIX)dtc
>>> >>> # Required to build platforms or ACPI tables:
>>> >>> # Intel(r) ACPI Compiler from
>>> >>> #
>>>
>>https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Facpica.
>>> org%2Fdownloads&data=02%7C01%7CChristopher.Co%40microsoft.co
>>>
>>m%7C04783c7442e045028b6b08d5da73c590%7C72f988bf86f141af91ab2d7cd0
>>> 11db47%7C1%7C0%7C636655113127087911&sdata=rekWKjfTCvj%2FCv
>>> mXi%2FtAcEOw7ooGMYGo6uyKoNCL0os%3D&reserved=0
>>> >>>+# GCC49xASL -Windows- Requires:
>>> >>>+# GCC 4.9 targeting arm-none-eabi
>>> >>>+# Optional:
>>> >>>+# Required to build platforms or ACPI tables:
>>> >>>+# Microsoft ASL ACPI Compiler (asl.exe) from Windows
>>> >WDK
>>> >>>+#
>>> https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdocs.
>>> microsoft.com%2Fen-us%2Fwindows-
>>> &data=02%7C01%7CChristopher.Co%40microsoft.com%7C04783c7442e
>>> 045028b6b08d5da73c590%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0
>>> %7C636655113127087911&sdata=OEHhpxkYbIqRmALJeMDjp4RekTgVK
>>G
>>> 6dlmdmYa3HNOg%3D&reserved=0
>>> >>>hardware/drivers/download-the-wdk
>>> >>> # GCC5 -Linux,Windows- Requires:
>>> >>> # GCC 5 with LTO support, targeting x86_64-linux-gnu,
>>> >aarch64-
>>> >>>linux-gnu, or arm-linux-gnueabi
>>> >>> # Optional:
>>> >>>@@ -5466,6 +5472,61 @@ RELEASE_GCC49_AARCH64_DLINK_FLAGS =
>>> >>>DEF(GCC49_AARCH64_DLINK_FLAGS)
>>> >>> NOOPT_GCC49_AARCH64_DLINK_FLAGS =
>>> >>>DEF(GCC49_AARCH64_DLINK_FLAGS) -z common-page-size=0x1000 -O0
>>> >>> NOOPT_GCC49_AARCH64_DLINK_XIPFLAGS = -z common-page-
>>> size=0x20
>>> >-
>>> >>>O0
>>> >>>
>>> >>>+######################################################
>>> ##
>>> >##
>>> >>>##########################
>>> >>>+#
>>> >>>+# GCC49xASL - This configuration is used to compile under Windows to
>>> >>>produce
>>> >>>+# PE/COFF binaries using GCC 4.9.
>>> >>>+#
>>> >>>+######################################################
>>> ##
>>> >##
>>> >>>##########################
>>> >>>+*_GCC49xASL_*_*_FAMILY = GCC
>>> >>>+
>>> >>>+*_GCC49xASL_*_MAKE_PATH =
>>> DEF(GCC_HOST_PREFIX)make
>>> >>>+*_GCC49xASL_*_*_DLL = ENV(GCC49_DLL)
>>> >>>+*_GCC49xASL_*_ASL_PATH = DEF(WIN_ASL_BIN)
>>> >>>+
>>> >>>+*_GCC49xASL_*_PP_FLAGS = DEF(GCC_PP_FLAGS)
>>> >>>+*_GCC49xASL_*_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS)
>>> >>>+*_GCC49xASL_*_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
>>> >>>+*_GCC49xASL_*_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS)
>>> >>>+*_GCC49xASL_*_APP_FLAGS =
>>> >>>+*_GCC49xASL_*_ASL_FLAGS = /MsftInternal
>>> >>>+*_GCC49xASL_*_ASL_OUTFLAGS = DEF(MS_ASL_OUTFLAGS)
>>> >>>+
>>> >>>+##################
>>> >>>+# GCC49xASL ARM definitions
>>> >>>+##################
>>> >>>+*_GCC49xASL_ARM_OBJCOPY_PATH = noop
>>> >>>+*_GCC49xASL_ARM_CC_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>> >>>+*_GCC49xASL_ARM_SLINK_PATH = ENV(GCC49_ARM_PREFIX)ar
>>> >>>+*_GCC49xASL_ARM_DLINK_PATH =
>>ENV(GCC49_ARM_PREFIX)gcc
>>> >>>+*_GCC49xASL_ARM_ASLDLINK_PATH =
>>> ENV(GCC49_ARM_PREFIX)gcc
>>> >>>+*_GCC49xASL_ARM_ASM_PATH =
>>ENV(GCC49_ARM_PREFIX)gcc
>>> >>>+*_GCC49xASL_ARM_PP_PATH = ENV(GCC49_ARM_PREFIX)gcc
>>> >>>+*_GCC49xASL_ARM_VFRPP_PATH =
>>> ENV(GCC49_ARM_PREFIX)gcc
>>> >>>+*_GCC49xASL_ARM_ASLCC_PATH =
>>ENV(GCC49_ARM_PREFIX)gcc
>>> >>>+*_GCC49xASL_ARM_ASLPP_PATH =
>>ENV(GCC49_ARM_PREFIX)gcc
>>> >>>+*_GCC49xASL_ARM_RC_PATH =
>>> >ENV(GCC49_ARM_PREFIX)objcopy
>>> >>>+*_GCC49xASL_ARM_SYMRENAME_PATH = noop
>>> >>>+
>>> >>>+*_GCC49xASL_ARM_ARCHCC_FLAGS = -mthumb
>>> >>>+*_GCC49xASL_ARM_PLATFORM_FLAGS = -march=armv7-a
>>> >>>+
>>> >>>+*_GCC49xASL_ARM_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
>>> >>>+*_GCC49xASL_ARM_ASLDLINK_FLAGS =
>>> >>>DEF(GCC49_ARM_ASLDLINK_FLAGS)
>>> >>>+*_GCC49xASL_ARM_ASM_FLAGS =
>>> DEF(GCC49_ARM_ASM_FLAGS)
>>> >>>+*_GCC49xASL_ARM_DLINK_FLAGS =
>>> >DEF(GCC49_ARM_DLINK_FLAGS)
>>> >>>+*_GCC49xASL_ARM_DLINK2_FLAGS =
>>> >DEF(GCC49_ARM_DLINK2_FLAGS)
>>> >>>+*_GCC49xASL_ARM_DTCPP_FLAGS = DEF(GCC_DTCPP_FLAGS)
>>> >>>+*_GCC49xASL_ARM_PLATFORM_FLAGS = -march=armv7-a
>>> >>>+*_GCC49xASL_ARM_PP_FLAGS = $(ARCHCC_FLAGS)
>>> >>>$(PLATFORM_FLAGS) DEF(GCC_PP_FLAGS)
>>> >>>+*_GCC49xASL_ARM_RC_FLAGS = DEF(GCC_ARM_RC_FLAGS)
>>> >>>+*_GCC49xASL_ARM_VFRPP_FLAGS = $(ARCHCC_FLAGS)
>>> >>>$(PLATFORM_FLAGS) DEF(GCC_VFRPP_FLAGS)
>>> >>>+*_GCC49xASL_ARM_CC_XIPFLAGS =
>>> DEF(GCC49_ARM_CC_XIPFLAGS)
>>> >>>+
>>> >>>+ DEBUG_GCC49xASL_ARM_CC_FLAGS =
>>> DEF(GCC49_ARM_CC_FLAGS)
>>> >-
>>> >>>O0
>>> >>>+RELEASE_GCC49xASL_ARM_CC_FLAGS =
>>> DEF(GCC49_ARM_CC_FLAGS)
>>> >-
>>> >>>Wno-unused-but-set-variable -Wno-unused-const-variable
>>> >>>+ NOOPT_GCC49xASL_ARM_CC_FLAGS =
>>> DEF(GCC49_ARM_CC_FLAGS)
>>> >-
>>> >>>O0
>>> >>>+
>>> >>>
>>> >>>#######################################################
>>> ##
>>> >##
>>> >>>#########################
>>> >>> #
>>> >>> # GCC 5 - This configuration is used to compile under Linux to
>>> >>>produce
>>> >>>--
>>> >>>2.16.2.gvfs.1.33.gf5370f1
>>> >>
>>> >> _______________________________________________
>>> >> edk2-devel mailing list
>>> >> edk2-devel@lists.01.org
>>> >> https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flist
>>> >> s.01.org%2Fmailman%2Flistinfo%2Fedk2-
>>> devel&data=02%7C01%7CChristo
>>> >>
>>>
>>pher.Co%40microsoft.com%7C04783c7442e045028b6b08d5da73c590%7C72f9
>>> 88bf
>>> >>
>>>
>>86f141af91ab2d7cd011db47%7C1%7C0%7C636655113127087911&sdata=
>>> WLQCR
>>> >> O6Olja0J14OBnX1PSsdXnTYEXDMki9fN7CuAHs%3D&reserved=0
>>_______________________________________________
>>edk2-devel mailing list
>>edk2-devel@lists.01.org
>>https://lists.01.org/mailman/listinfo/edk2-devel
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain support
2018-06-26 8:22 ` Ard Biesheuvel
@ 2018-06-26 18:42 ` Chris Co
2018-06-26 18:51 ` Ard Biesheuvel
0 siblings, 1 reply; 15+ messages in thread
From: Chris Co @ 2018-06-26 18:42 UTC (permalink / raw)
To: Ard Biesheuvel, Gao, Liming, Leif Lindholm
Cc: edk2-devel@lists.01.org, Charles Garcia-Tobin
> -----Original Message-----
> From: Ard Biesheuvel <ard.biesheuvel@linaro.org>
> Sent: Tuesday, June 26, 2018 1:22 AM
> To: Gao, Liming <liming.gao@intel.com>
> Cc: Chris Co <Christopher.Co@microsoft.com>; edk2-devel@lists.01.org; Leif
> Lindholm <leif.lindholm@linaro.org>; Charles Garcia-Tobin <Charles.Garcia-
> Tobin@arm.com>
> Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
> Toolchain support
>
> On 26 June 2018 at 06:40, Gao, Liming <liming.gao@intel.com> wrote:
> > Chris:
> > Here is the example usage. You can add below [BuildOptions] in your
> platform DSC. Then, it will use override ASL path and flag.
> >
> > [BuildOptions]
> > *_*_*_ASL_PATH == C:\Asl\asl.exe
> > *_*_*_ASL_FLAGS == /MsftInternal
> > *_*_*_ASL_OUTFLAGS == /Fo=
> >
>
> I strongly prefer this over adding a new MS specific toolchain definition.
>
Thanks Liming! I added these overrides and they works great. Since we can do platform dsc overrides, I also used it to override the objcopy_path and symrename_path which was the other change we needed for building on Windows.
GCC:*_*_*_OBJCOPY_PATH = noop
GCC:*_*_*_SYMRENAME_PATH = noop
Ard, I agree this is the better method. We can drop this patch in favor of the platform dsc overrides.
Leif, I tested GCC7.3 arm-eabi and ran into build errors. Found out this was an issue encountered before: https://bugs.linaro.org/show_bug.cgi?id=2909
I made a couple modifications to Trim.py to fix the errors and was able to successfully build and test. Will submit the fix for review and update our toolchain to use GCC7.3 with GCC5 profile.
Thanks,
Chris
> >>-----Original Message-----
> >>From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of
> >>Chris Co
> >>Sent: Tuesday, June 26, 2018 2:21 AM
> >>To: Gao, Liming <liming.gao@intel.com>; Ard Biesheuvel
> >><ard.biesheuvel@linaro.org>
> >>Cc: edk2-devel@lists.01.org; Leif Lindholm <leif.lindholm@linaro.org>;
> >>Charles Garcia-Tobin <Charles.Garcia-Tobin@arm.com>
> >>Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
> >>Toolchain support
> >>
> >>
> >>
> >>> -----Original Message-----
> >>> From: Gao, Liming <liming.gao@intel.com>
> >>> Sent: Monday, June 25, 2018 1:15 AM
> >>> To: Ard Biesheuvel <ard.biesheuvel@linaro.org>
> >>> Cc: Chris Co <Christopher.Co@microsoft.com>;
> >>> edk2-devel@lists.01.org; Leif Lindholm <leif.lindholm@linaro.org>;
> >>> Charles Garcia-Tobin <Charles.Garcia- Tobin@arm.com>
> >>> Subject: RE: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add
> >>> GCC49xASL Toolchain support
> >>>
> >>> Ard:
> >>> The commit log message says that the Microsoft ASL compiler is
> >>> necessary to expose Windows-specific Pin Function Config Descriptors
> >>> on Windows IoT devices.
> >>>
> >>
> >>I'll add a bit more detail here. Prior to the inclusion of Pin
> >>Function Descriptors in the 6.2 spec, we added a vendor-specific
> >>descriptor through the MSFT ASL compiler with /MsftInternal flag which
> >>essentially implemented the functionality of the proposed Pin Function
> >>Config Descriptors so that pins could be exposed to user-mode
> >>applications. Now that the spec is updated and the standard ASL
> >>compiler supports the new descriptors, I wanted to move us to the
> >>standardized ASL compiler but was disappointed to find out that
> >>Windows has not been enlightened to process the Pin Function Config
> >>Descriptor yet. So we still need this fall back to the MSFT ASL
> >>compiler with /MsftInternal flag while I work with the ACPI team here
> >>to implement these descriptors. My hope is that in the next year I can
> move us back to the standard ASL compiler.
> >>
> >>> Besides, there is no ways to configure tool chain with the
> >>> parameter in
> >>build
> >>> command. But, tool chain ASL path and flag can be overridden in
> >>> [BuildOptions] of platform DSC file. Another way is to provide the
> >>> generic DSC file to include MS ASL option setting in [BuildOptions]
> >>> section. Platform DSC can decide to include it or not.
> >>>
> >>
> >>Since the MS ASL really only impacts Windows IoT boards, platform dsc
> >>overrides on the Windows IoT ARM boards might be a better option here.
> >>
> >>> Thanks
> >>> Liming
> >>> >-----Original Message-----
> >>> >From: Ard Biesheuvel [mailto:ard.biesheuvel@linaro.org]
> >>> >Sent: Monday, June 25, 2018 3:34 PM
> >>> >To: Gao, Liming <liming.gao@intel.com>
> >>> >Cc: Chris Co <Christopher.Co@microsoft.com>;
> >>> >edk2-devel@lists.01.org; Leif Lindholm <leif.lindholm@linaro.org>;
> >>> >Charles Garcia-Tobin
> >>> ><Charles.Garcia- Tobin@arm.com>
> >>> >Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add
> >>> >GCC49xASL Toolchain support
> >>> >
> >>> >(+ Charles)
> >>> >
> >>> >On 25 June 2018 at 03:38, Gao, Liming <liming.gao@intel.com> wrote:
> >>> >> Chris:
> >>> >> GCC 4.9 targeting arm-none-eabi. This GCC4.9 should run in
> >>> >> Windows
> >>> OS.
> >>> >So, could you give some info where windows GCC49 is from.
> >>> >>
> >>
> >>We get Windows GCC49 from linaro:
> >>https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Frele
> a
> >>ses.linaro.org%2Farchive%2F14.09%2Fcomponents%2Ftoolchain%2Fbinari
> es%2
> >>Fgcc&data=02%7C01%7CChristopher.Co%40microsoft.com%7Cad0a4
> 7af8e704
> >>9a47a0008d5db3df07f%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0
> %7C63665
> >>5981433557180&sdata=JjAbrfgJWZPw4rFnoaMFTZFsMgfQMXF%2Fb
> %2FARXQr%2F
> >>7hE%3D&reserved=0 -linaro-arm-none-eabi-4.9-2014.09_win32.zip
> >>Make comes from MinGW
> >>
> >>> >
> >>> >OK, so first of all, could you elaborate on why we need a different
> >>> >ASL compiler? We have spent the past 5 years in conference calls
> >>> >and meeting rooms to standardize ACPI on ARM, so I am rather
> >>> >disappointed that we have this discrepancy.
> >>> >
> >>> >Then, could you explain why you chose GCC49? We have GCC5 now as
> >>> >well, which enables LTO and generally results in smaller code.
> >>> >Also, is there any way we could parameterize the existing GCCx
> >>> >toolchains to allow a different ASL compiler to be selected?
> >>> >
> >>
> >>We are using GCC49 because this was the last GCC build for Windows as
> >>exe we could find. We use these tools to build using GCC on Windows:
> >>https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Frele
> a
> >>ses.linaro.org%2Farchive%2F14.09%2Fcomponents%2Ftoolchain%2Fbinari
> es%2
> >>Fgcc&data=02%7C01%7CChristopher.Co%40microsoft.com%7Cad0a4
> 7af8e704
> >>9a47a0008d5db3df07f%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0
> %7C63665
> >>5981433557180&sdata=JjAbrfgJWZPw4rFnoaMFTZFsMgfQMXF%2Fb
> %2FARXQr%2F
> >>7hE%3D&reserved=0 -linaro-arm-none-eabi-4.9-2014.09_win32.zip
> >>I would love to use GCC5 if toolchain exes are readily available for
> Windows.
> >>
> >>There are two main deltas between existing GCCx toolchains and the one
> >>I am adding here: ASL compiler delta and echo/noop delta.
> >>The ASL delta was discussed above. We have one more delta:
> >>(*_GCC49xASL_ARM_OBJCOPY_PATH = noop,
> >>*_GCC49xASL_ARM_SYMRENAME_PATH = noop). On Linux, these are
> set
> >>to `echo` which effectively no-ops them. On Windows, echo behaves
> >>differently and unfortunately there's no clean Windows command to
> >>noop, so we made a noop.exe program and added it to our build tools.
> >>If we can find a way to parameterize the existing GCCx toolchain to
> >>select command based on build environment, then I think this patch can
> >>be dropped in favor of reusing the existing GCCx chain.
> >>
> >>> >Thanks,
> >>> >Ard.
> >>> >
> >>> >
> >>> >>>-----Original Message-----
> >>> >>>From: Chris Co [mailto:Christopher.Co@microsoft.com]
> >>> >>>Sent: Saturday, June 23, 2018 8:58 AM
> >>> >>>To: edk2-devel@lists.01.org
> >>> >>>Cc: Zhu, Yonghong <yonghong.zhu@intel.com>; Gao, Liming
> >>> >>><liming.gao@intel.com>; Leif Lindholm <leif.lindholm@linaro.org>
> >>> >>>Subject: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
> >>> >>>Toolchain support
> >>> >>>
> >>> >>>From: Chris Co <chrco@microsoft.com>
> >>> >>>
> >>> >>>This patch adds a build option for invoking GCC49 ARM cross
> >>> >>>compiler in the Windows environment to build firmware for
> Windows
> >>> >>>10 IoT devices using NXP i.MX6 and i.MX7 SoCs.
> >>> >>>
> >>> >>>In addition, this build option targets the Microsoft ASL compiler
> >>> >>>instead of iasl. The Microsoft ASL compiler is necessary to
> >>> >>>expose Windows-specific Pin Function Config Descriptors on
> >>> >>>Windows IoT devices.
> >>> >>>
> >>> >>>Contributed-under: TianoCore Contribution Agreement 1.1
> >>> >>>Signed-off-by: Christopher Co <christopher.co@microsoft.com>
> >>> >>>Cc: Yonghong Zhu <yonghong.zhu@intel.com>
> >>> >>>Cc: Liming Gao <liming.gao@intel.com>
> >>> >>>Cc: Leif Lindholm <leif.lindholm@linaro.org>
> >>> >>>---
> >>> >>> BaseTools/Conf/tools_def.template | 61 ++++++++++++++++++++
> >>> >>> 1 file changed, 61 insertions(+)
> >>> >>>
> >>> >>>diff --git a/BaseTools/Conf/tools_def.template
> >>> >>>b/BaseTools/Conf/tools_def.template
> >>> >>>index 11a79029b890..f7a375ebaf1e 100755
> >>> >>>--- a/BaseTools/Conf/tools_def.template
> >>> >>>+++ b/BaseTools/Conf/tools_def.template
> >>> >>>@@ -393,6 +393,12 @@ DEFINE DTC_BIN =
> ENV(DTC_PREFIX)dtc
> >>> >>> # Required to build platforms or ACPI tables:
> >>> >>> # Intel(r) ACPI Compiler from
> >>> >>> #
> >>>
> >>https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Facpi
> ca.
> >>>
> org%2Fdownloads&data=02%7C01%7CChristopher.Co%40microsoft.co
> >>>
> >>m%7C04783c7442e045028b6b08d5da73c590%7C72f988bf86f141af91ab2d7c
> d0
> >>>
> 11db47%7C1%7C0%7C636655113127087911&sdata=rekWKjfTCvj%2FCv
> >>> mXi%2FtAcEOw7ooGMYGo6uyKoNCL0os%3D&reserved=0
> >>> >>>+# GCC49xASL -Windows- Requires:
> >>> >>>+# GCC 4.9 targeting arm-none-eabi
> >>> >>>+# Optional:
> >>> >>>+# Required to build platforms or ACPI tables:
> >>> >>>+# Microsoft ASL ACPI Compiler (asl.exe) from
> Windows
> >>> >WDK
> >>> >>>+#
> >>>
> https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdocs.
> >>> microsoft.com%2Fen-us%2Fwindows-
> >>>
> &data=02%7C01%7CChristopher.Co%40microsoft.com%7C04783c7442e
> >>>
> 045028b6b08d5da73c590%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0
> >>>
> %7C636655113127087911&sdata=OEHhpxkYbIqRmALJeMDjp4RekTgVK
> >>G
> >>> 6dlmdmYa3HNOg%3D&reserved=0
> >>> >>>hardware/drivers/download-the-wdk
> >>> >>> # GCC5 -Linux,Windows- Requires:
> >>> >>> # GCC 5 with LTO support, targeting x86_64-linux-gnu,
> >>> >aarch64-
> >>> >>>linux-gnu, or arm-linux-gnueabi
> >>> >>> # Optional:
> >>> >>>@@ -5466,6 +5472,61 @@ RELEASE_GCC49_AARCH64_DLINK_FLAGS
> =
> >>> >>>DEF(GCC49_AARCH64_DLINK_FLAGS)
> >>> >>> NOOPT_GCC49_AARCH64_DLINK_FLAGS =
> >>> >>>DEF(GCC49_AARCH64_DLINK_FLAGS) -z common-page-size=0x1000
> -O0
> >>> >>> NOOPT_GCC49_AARCH64_DLINK_XIPFLAGS = -z common-page-
> >>> size=0x20
> >>> >-
> >>> >>>O0
> >>> >>>
> >>>
> >>>+######################################################
> >>> ##
> >>> >##
> >>> >>>##########################
> >>> >>>+#
> >>> >>>+# GCC49xASL - This configuration is used to compile under
> >>> >>>+Windows to
> >>> >>>produce
> >>> >>>+# PE/COFF binaries using GCC 4.9.
> >>> >>>+#
> >>>
> >>>+######################################################
> >>> ##
> >>> >##
> >>> >>>##########################
> >>> >>>+*_GCC49xASL_*_*_FAMILY = GCC
> >>> >>>+
> >>> >>>+*_GCC49xASL_*_MAKE_PATH =
> >>> DEF(GCC_HOST_PREFIX)make
> >>> >>>+*_GCC49xASL_*_*_DLL = ENV(GCC49_DLL)
> >>> >>>+*_GCC49xASL_*_ASL_PATH = DEF(WIN_ASL_BIN)
> >>> >>>+
> >>> >>>+*_GCC49xASL_*_PP_FLAGS = DEF(GCC_PP_FLAGS)
> >>> >>>+*_GCC49xASL_*_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS)
> >>> >>>+*_GCC49xASL_*_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
> >>> >>>+*_GCC49xASL_*_VFRPP_FLAGS =
> DEF(GCC_VFRPP_FLAGS)
> >>> >>>+*_GCC49xASL_*_APP_FLAGS =
> >>> >>>+*_GCC49xASL_*_ASL_FLAGS = /MsftInternal
> >>> >>>+*_GCC49xASL_*_ASL_OUTFLAGS =
> DEF(MS_ASL_OUTFLAGS)
> >>> >>>+
> >>> >>>+##################
> >>> >>>+# GCC49xASL ARM definitions
> >>> >>>+##################
> >>> >>>+*_GCC49xASL_ARM_OBJCOPY_PATH = noop
> >>> >>>+*_GCC49xASL_ARM_CC_PATH =
> ENV(GCC49_ARM_PREFIX)gcc
> >>> >>>+*_GCC49xASL_ARM_SLINK_PATH =
> ENV(GCC49_ARM_PREFIX)ar
> >>> >>>+*_GCC49xASL_ARM_DLINK_PATH =
> >>ENV(GCC49_ARM_PREFIX)gcc
> >>> >>>+*_GCC49xASL_ARM_ASLDLINK_PATH =
> >>> ENV(GCC49_ARM_PREFIX)gcc
> >>> >>>+*_GCC49xASL_ARM_ASM_PATH =
> >>ENV(GCC49_ARM_PREFIX)gcc
> >>> >>>+*_GCC49xASL_ARM_PP_PATH =
> ENV(GCC49_ARM_PREFIX)gcc
> >>> >>>+*_GCC49xASL_ARM_VFRPP_PATH =
> >>> ENV(GCC49_ARM_PREFIX)gcc
> >>> >>>+*_GCC49xASL_ARM_ASLCC_PATH =
> >>ENV(GCC49_ARM_PREFIX)gcc
> >>> >>>+*_GCC49xASL_ARM_ASLPP_PATH =
> >>ENV(GCC49_ARM_PREFIX)gcc
> >>> >>>+*_GCC49xASL_ARM_RC_PATH =
> >>> >ENV(GCC49_ARM_PREFIX)objcopy
> >>> >>>+*_GCC49xASL_ARM_SYMRENAME_PATH = noop
> >>> >>>+
> >>> >>>+*_GCC49xASL_ARM_ARCHCC_FLAGS = -mthumb
> >>> >>>+*_GCC49xASL_ARM_PLATFORM_FLAGS = -march=armv7-a
> >>> >>>+
> >>> >>>+*_GCC49xASL_ARM_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
> >>> >>>+*_GCC49xASL_ARM_ASLDLINK_FLAGS =
> >>> >>>DEF(GCC49_ARM_ASLDLINK_FLAGS)
> >>> >>>+*_GCC49xASL_ARM_ASM_FLAGS =
> >>> DEF(GCC49_ARM_ASM_FLAGS)
> >>> >>>+*_GCC49xASL_ARM_DLINK_FLAGS =
> >>> >DEF(GCC49_ARM_DLINK_FLAGS)
> >>> >>>+*_GCC49xASL_ARM_DLINK2_FLAGS =
> >>> >DEF(GCC49_ARM_DLINK2_FLAGS)
> >>> >>>+*_GCC49xASL_ARM_DTCPP_FLAGS =
> DEF(GCC_DTCPP_FLAGS)
> >>> >>>+*_GCC49xASL_ARM_PLATFORM_FLAGS = -march=armv7-a
> >>> >>>+*_GCC49xASL_ARM_PP_FLAGS = $(ARCHCC_FLAGS)
> >>> >>>$(PLATFORM_FLAGS) DEF(GCC_PP_FLAGS)
> >>> >>>+*_GCC49xASL_ARM_RC_FLAGS =
> DEF(GCC_ARM_RC_FLAGS)
> >>> >>>+*_GCC49xASL_ARM_VFRPP_FLAGS = $(ARCHCC_FLAGS)
> >>> >>>$(PLATFORM_FLAGS) DEF(GCC_VFRPP_FLAGS)
> >>> >>>+*_GCC49xASL_ARM_CC_XIPFLAGS =
> >>> DEF(GCC49_ARM_CC_XIPFLAGS)
> >>> >>>+
> >>> >>>+ DEBUG_GCC49xASL_ARM_CC_FLAGS =
> >>> DEF(GCC49_ARM_CC_FLAGS)
> >>> >-
> >>> >>>O0
> >>> >>>+RELEASE_GCC49xASL_ARM_CC_FLAGS =
> >>> DEF(GCC49_ARM_CC_FLAGS)
> >>> >-
> >>> >>>Wno-unused-but-set-variable -Wno-unused-const-variable
> >>> >>>+ NOOPT_GCC49xASL_ARM_CC_FLAGS =
> >>> DEF(GCC49_ARM_CC_FLAGS)
> >>> >-
> >>> >>>O0
> >>> >>>+
> >>> >>>
> >>>
> >>>#######################################################
> >>> ##
> >>> >##
> >>> >>>#########################
> >>> >>> #
> >>> >>> # GCC 5 - This configuration is used to compile under Linux to
> >>> >>>produce
> >>> >>>--
> >>> >>>2.16.2.gvfs.1.33.gf5370f1
> >>> >>
> >>> >> _______________________________________________
> >>> >> edk2-devel mailing list
> >>> >> edk2-devel@lists.01.org
> >>> >>
> https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2F
> >>> >> list
> >>> >> s.01.org%2Fmailman%2Flistinfo%2Fedk2-
> >>> devel&data=02%7C01%7CChristo
> >>> >>
> >>>
> >>pher.Co%40microsoft.com%7C04783c7442e045028b6b08d5da73c590%7C7
> 2f9
> >>> 88bf
> >>> >>
> >>>
> >>86f141af91ab2d7cd011db47%7C1%7C0%7C636655113127087911&sdat
> a=
> >>> WLQCR
> >>> >> O6Olja0J14OBnX1PSsdXnTYEXDMki9fN7CuAHs%3D&reserved=0
> >>_______________________________________________
> >>edk2-devel mailing list
> >>edk2-devel@lists.01.org
> >>https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists
> >>.01.org%2Fmailman%2Flistinfo%2Fedk2-
> devel&data=02%7C01%7CChristoph
> >>er.Co%40microsoft.com%7Cad0a47af8e7049a47a0008d5db3df07f%7C72f9
> 88bf86f
> >>141af91ab2d7cd011db47%7C1%7C0%7C636655981433557180&sdata=I
> %2FHuHee
> >>akZTzRKCBF%2BxC3yxngcMbt%2FxQp4qyEbFzUTQ%3D&reserved=0
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain support
2018-06-26 18:42 ` Chris Co
@ 2018-06-26 18:51 ` Ard Biesheuvel
2018-06-27 4:14 ` Chris Co
0 siblings, 1 reply; 15+ messages in thread
From: Ard Biesheuvel @ 2018-06-26 18:51 UTC (permalink / raw)
To: Chris Co
Cc: Gao, Liming, Leif Lindholm, edk2-devel@lists.01.org,
Charles Garcia-Tobin
On 26 June 2018 at 20:42, Chris Co <Christopher.Co@microsoft.com> wrote:
>
>
>> -----Original Message-----
>> From: Ard Biesheuvel <ard.biesheuvel@linaro.org>
>> Sent: Tuesday, June 26, 2018 1:22 AM
>> To: Gao, Liming <liming.gao@intel.com>
>> Cc: Chris Co <Christopher.Co@microsoft.com>; edk2-devel@lists.01.org; Leif
>> Lindholm <leif.lindholm@linaro.org>; Charles Garcia-Tobin <Charles.Garcia-
>> Tobin@arm.com>
>> Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
>> Toolchain support
>>
>> On 26 June 2018 at 06:40, Gao, Liming <liming.gao@intel.com> wrote:
>> > Chris:
>> > Here is the example usage. You can add below [BuildOptions] in your
>> platform DSC. Then, it will use override ASL path and flag.
>> >
>> > [BuildOptions]
>> > *_*_*_ASL_PATH == C:\Asl\asl.exe
>> > *_*_*_ASL_FLAGS == /MsftInternal
>> > *_*_*_ASL_OUTFLAGS == /Fo=
>> >
>>
>> I strongly prefer this over adding a new MS specific toolchain definition.
>>
>
> Thanks Liming! I added these overrides and they works great. Since we can do platform dsc overrides, I also used it to override the objcopy_path and symrename_path which was the other change we needed for building on Windows.
> GCC:*_*_*_OBJCOPY_PATH = noop
> GCC:*_*_*_SYMRENAME_PATH = noop
>
> Ard, I agree this is the better method. We can drop this patch in favor of the platform dsc overrides.
>
> Leif, I tested GCC7.3 arm-eabi and ran into build errors. Found out this was an issue encountered before: https://bugs.linaro.org/show_bug.cgi?id=2909
> I made a couple modifications to Trim.py to fix the errors and was able to successfully build and test. Will submit the fix for review and update our toolchain to use GCC7.3 with GCC5 profile.
>
That is good news.
So I guess we're all set to start incorporating this platform.
Any clue whether there is also a device tree available for this
platform? I would prefer it if we could make the firmware OS agnostic,
rather than have Windows-only and Linux-only platforms in the
edk2-platforms tree.
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain support
2018-06-26 18:51 ` Ard Biesheuvel
@ 2018-06-27 4:14 ` Chris Co
2018-06-27 5:07 ` Ard Biesheuvel
0 siblings, 1 reply; 15+ messages in thread
From: Chris Co @ 2018-06-27 4:14 UTC (permalink / raw)
To: Ard Biesheuvel
Cc: Gao, Liming, Leif Lindholm, edk2-devel@lists.01.org,
Charles Garcia-Tobin
> -----Original Message-----
> From: Ard Biesheuvel <ard.biesheuvel@linaro.org>
> Sent: Tuesday, June 26, 2018 11:52 AM
> To: Chris Co <Christopher.Co@microsoft.com>
> Cc: Gao, Liming <liming.gao@intel.com>; Leif Lindholm
> <leif.lindholm@linaro.org>; edk2-devel@lists.01.org; Charles Garcia-Tobin
> <Charles.Garcia-Tobin@arm.com>
> Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
> Toolchain support
>
> On 26 June 2018 at 20:42, Chris Co <Christopher.Co@microsoft.com> wrote:
> >
> >
> >> -----Original Message-----
> >> From: Ard Biesheuvel <ard.biesheuvel@linaro.org>
> >> Sent: Tuesday, June 26, 2018 1:22 AM
> >> To: Gao, Liming <liming.gao@intel.com>
> >> Cc: Chris Co <Christopher.Co@microsoft.com>; edk2-devel@lists.01.org;
> >> Leif Lindholm <leif.lindholm@linaro.org>; Charles Garcia-Tobin
> >> <Charles.Garcia- Tobin@arm.com>
> >> Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
> >> Toolchain support
> >>
> >> On 26 June 2018 at 06:40, Gao, Liming <liming.gao@intel.com> wrote:
> >> > Chris:
> >> > Here is the example usage. You can add below [BuildOptions] in
> >> > your
> >> platform DSC. Then, it will use override ASL path and flag.
> >> >
> >> > [BuildOptions]
> >> > *_*_*_ASL_PATH == C:\Asl\asl.exe
> >> > *_*_*_ASL_FLAGS == /MsftInternal
> >> > *_*_*_ASL_OUTFLAGS == /Fo=
> >> >
> >>
> >> I strongly prefer this over adding a new MS specific toolchain definition.
> >>
> >
> > Thanks Liming! I added these overrides and they works great. Since we
> can do platform dsc overrides, I also used it to override the objcopy_path
> and symrename_path which was the other change we needed for building
> on Windows.
> > GCC:*_*_*_OBJCOPY_PATH = noop
> > GCC:*_*_*_SYMRENAME_PATH = noop
> >
> > Ard, I agree this is the better method. We can drop this patch in favor of
> the platform dsc overrides.
> >
> > Leif, I tested GCC7.3 arm-eabi and ran into build errors. Found out
> > this was an issue encountered before:
> >
> https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fbugs.
> >
> linaro.org%2Fshow_bug.cgi%3Fid%3D2909&data=02%7C01%7CChristop
> her.C
> >
> o%40microsoft.com%7C0960f252b3dd4f2e79ed08d5db95e411%7C72f988bf86
> f141a
> >
> f91ab2d7cd011db47%7C1%7C0%7C636656359185404698&sdata=ZEt9sY
> %2F94us
> > UaTDkvHQrzkkIiaXTPPfWqMlPh2NK%2BgM%3D&reserved=0
> > I made a couple modifications to Trim.py to fix the errors and was able to
> successfully build and test. Will submit the fix for review and update our
> toolchain to use GCC7.3 with GCC5 profile.
> >
>
> That is good news.
>
> So I guess we're all set to start incorporating this platform.
>
> Any clue whether there is also a device tree available for this platform? I
> would prefer it if we could make the firmware OS agnostic, rather than have
> Windows-only and Linux-only platforms in the edk2-platforms tree.
We did not include a device tree since Windows does not comprehend device trees, however all of our ARM platforms have a u-boot config which generates a device tree and boots linux.
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain support
2018-06-27 4:14 ` Chris Co
@ 2018-06-27 5:07 ` Ard Biesheuvel
2018-06-29 3:49 ` Chris Co
0 siblings, 1 reply; 15+ messages in thread
From: Ard Biesheuvel @ 2018-06-27 5:07 UTC (permalink / raw)
To: Chris Co
Cc: Gao, Liming, Leif Lindholm, edk2-devel@lists.01.org,
Charles Garcia-Tobin
On 27 June 2018 at 06:14, Chris Co <Christopher.Co@microsoft.com> wrote:
>> -----Original Message-----
>> From: Ard Biesheuvel <ard.biesheuvel@linaro.org>
>> Sent: Tuesday, June 26, 2018 11:52 AM
>> To: Chris Co <Christopher.Co@microsoft.com>
>> Cc: Gao, Liming <liming.gao@intel.com>; Leif Lindholm
>> <leif.lindholm@linaro.org>; edk2-devel@lists.01.org; Charles Garcia-Tobin
>> <Charles.Garcia-Tobin@arm.com>
>> Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
>> Toolchain support
>>
>> On 26 June 2018 at 20:42, Chris Co <Christopher.Co@microsoft.com> wrote:
>> >
>> >
>> >> -----Original Message-----
>> >> From: Ard Biesheuvel <ard.biesheuvel@linaro.org>
>> >> Sent: Tuesday, June 26, 2018 1:22 AM
>> >> To: Gao, Liming <liming.gao@intel.com>
>> >> Cc: Chris Co <Christopher.Co@microsoft.com>; edk2-devel@lists.01.org;
>> >> Leif Lindholm <leif.lindholm@linaro.org>; Charles Garcia-Tobin
>> >> <Charles.Garcia- Tobin@arm.com>
>> >> Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
>> >> Toolchain support
>> >>
>> >> On 26 June 2018 at 06:40, Gao, Liming <liming.gao@intel.com> wrote:
>> >> > Chris:
>> >> > Here is the example usage. You can add below [BuildOptions] in
>> >> > your
>> >> platform DSC. Then, it will use override ASL path and flag.
>> >> >
>> >> > [BuildOptions]
>> >> > *_*_*_ASL_PATH == C:\Asl\asl.exe
>> >> > *_*_*_ASL_FLAGS == /MsftInternal
>> >> > *_*_*_ASL_OUTFLAGS == /Fo=
>> >> >
>> >>
>> >> I strongly prefer this over adding a new MS specific toolchain definition.
>> >>
>> >
>> > Thanks Liming! I added these overrides and they works great. Since we
>> can do platform dsc overrides, I also used it to override the objcopy_path
>> and symrename_path which was the other change we needed for building
>> on Windows.
>> > GCC:*_*_*_OBJCOPY_PATH = noop
>> > GCC:*_*_*_SYMRENAME_PATH = noop
>> >
>> > Ard, I agree this is the better method. We can drop this patch in favor of
>> the platform dsc overrides.
>> >
>> > Leif, I tested GCC7.3 arm-eabi and ran into build errors. Found out
>> > this was an issue encountered before:
>> >
>> https://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fbugs.
>> >
>> linaro.org%2Fshow_bug.cgi%3Fid%3D2909&data=02%7C01%7CChristop
>> her.C
>> >
>> o%40microsoft.com%7C0960f252b3dd4f2e79ed08d5db95e411%7C72f988bf86
>> f141a
>> >
>> f91ab2d7cd011db47%7C1%7C0%7C636656359185404698&sdata=ZEt9sY
>> %2F94us
>> > UaTDkvHQrzkkIiaXTPPfWqMlPh2NK%2BgM%3D&reserved=0
>> > I made a couple modifications to Trim.py to fix the errors and was able to
>> successfully build and test. Will submit the fix for review and update our
>> toolchain to use GCC7.3 with GCC5 profile.
>> >
>>
>> That is good news.
>>
>> So I guess we're all set to start incorporating this platform.
>>
>> Any clue whether there is also a device tree available for this platform? I
>> would prefer it if we could make the firmware OS agnostic, rather than have
>> Windows-only and Linux-only platforms in the edk2-platforms tree.
>
> We did not include a device tree since Windows does not comprehend device trees, however all of our ARM platforms have a u-boot config which generates a device tree and boots linux.
>
OK, good to know. I think Leif already asked the same question, but if
he or I could get our hands on such a platform, we could work together
to ensure that both Windows and Linux can boot from the same firmware
image.
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL Toolchain support
2018-06-27 5:07 ` Ard Biesheuvel
@ 2018-06-29 3:49 ` Chris Co
0 siblings, 0 replies; 15+ messages in thread
From: Chris Co @ 2018-06-29 3:49 UTC (permalink / raw)
To: Ard Biesheuvel
Cc: Gao, Liming, Leif Lindholm, edk2-devel@lists.01.org,
Charles Garcia-Tobin
> -----Original Message-----
> From: Ard Biesheuvel <ard.biesheuvel@linaro.org>
> Sent: Tuesday, June 26, 2018 10:08 PM
> To: Chris Co <Christopher.Co@microsoft.com>
> Cc: Gao, Liming <liming.gao@intel.com>; Leif Lindholm
> <leif.lindholm@linaro.org>; edk2-devel@lists.01.org; Charles Garcia-Tobin
> <Charles.Garcia-Tobin@arm.com>
> Subject: Re: [edk2] [PATCH v2 1/1] BaseTools/tools_def: Add GCC49xASL
> Toolchain support
>
> OK, good to know. I think Leif already asked the same question, but if he or I
> could get our hands on such a platform, we could work together to ensure
> that both Windows and Linux can boot from the same firmware image.
I have not forgotten about this - still waiting for a response on which suppliers have the Solidrun i.MX6Q Hummingboard Edge immediately available in stock.
^ permalink raw reply [flat|nested] 15+ messages in thread
end of thread, other threads:[~2018-06-29 3:49 UTC | newest]
Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-06-23 0:57 [PATCH v2 0/1] BaseTools/tools_def: Add GCC49xASL Toolchain support Chris Co
2018-06-23 0:57 ` [PATCH v2 1/1] " Chris Co
2018-06-25 1:38 ` Gao, Liming
2018-06-25 7:33 ` Ard Biesheuvel
2018-06-25 8:15 ` Gao, Liming
2018-06-25 18:21 ` Chris Co
2018-06-25 19:10 ` Leif Lindholm
2018-06-25 19:50 ` Chris Co
2018-06-26 4:40 ` Gao, Liming
2018-06-26 8:22 ` Ard Biesheuvel
2018-06-26 18:42 ` Chris Co
2018-06-26 18:51 ` Ard Biesheuvel
2018-06-27 4:14 ` Chris Co
2018-06-27 5:07 ` Ard Biesheuvel
2018-06-29 3:49 ` Chris Co
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox