[edk2] [PATCH] BaseTools: Add $(INC)-like support when compiling .nasm files

2018-12-13 Thread Yonghong Zhu
source file directory. As a comparison, the compile of both .s and .asm have $(INC) support in their compile commands. Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=1085 Cc: Liming Gao Cc: Yonghong Zhu Cc: Bob Feng Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off

[edk2] [PATCH 2/2] BaseTools: Update nasm file build rule to support $(INC)

2018-12-13 Thread Yonghong Zhu
From: zhijufan Update the build rule to: "$(NASM)" -I${s_path}(+) $(NASM_INC) $(NASM_FLAGS) -o $dst ${d_path}(+)${s_base}.iii Cc: Liming Gao Cc: Yonghong Zhu Cc: Bob Feng Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zhiju.Fan --- BaseTools/Conf/build_rul

[edk2] [Patch 0/2] Update .nasm to support $(INC)-like support

2018-12-13 Thread Yonghong Zhu
From: zhijufan Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=1085 Cc: Liming Gao Cc: Yonghong Zhu Cc: Bob Feng Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zhiju.Fan zhijufan (2): BaseTools: Add $(INC)-like support when compiling .nasm files BaseTools

[edk2] [PATCH] BaseTools:Break build if same [LibraryClasses] name is used

2018-12-13 Thread Yonghong Zhu
/MyLibClass.h Cc: Liming Gao Cc: Yonghong Zhu Cc: Bob Feng Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=954 Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zhiju.Fan --- .../Python/Workspace/WorkspaceCommon.py | 19 ++- 1 file changed, 18

[edk2] [Patch] Maintainers.txt: Update BaseTools maintainers

2018-11-29 Thread Yonghong Zhu
As Yonghong has some other focus, change him from maintainer to reviewer, Bob will be the new maintainer. Cc: Bob Feng Cc: Liming Gao Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- Maintainers.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion

[edk2] [PATCH] BaseTools/Eot: Remove a duplication code in EotMain class

2018-10-31 Thread Yonghong Zhu
From: Hess Chen Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hess Chen --- BaseTools/Source/Python/Eot/EotMain.py | 365 - 1 file changed, 365 deletions(-) diff --git a/BaseTools/Source/Python/Eot/EotMain.py

[edk2] [Patch V2] BaseTools: Add special handle for '\' use in Pcd Value

2018-10-30 Thread Yonghong Zhu
From: zhijufan V2: Follow PEP8 to not multiples import on one line Case: gEfiOzmosisPkgTokenSpaceGuid.PcdBootLogFolderPath|L"\\Logs\\"|VOID*|12 Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=1287 Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agr

[edk2] [Patch] BaseTools: Add special handle for '\' use in Pcd Value

2018-10-30 Thread Yonghong Zhu
From: zhijufan Case: gEfiOzmosisPkgTokenSpaceGuid.PcdBootLogFolderPath|L"\\Logs\\"|VOID*|12 Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=1287 Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zhiju.Fan --- BaseTools/Sou

[edk2] [Patch 2/2 V2] BaseTools: Update nasm file build rule to support $(INC)

2018-10-25 Thread Yonghong Zhu
From: zhijufan Update the build rule to: "$(NASM)" -I${s_path}(+) $(NASM_INC)(+) $(NASM_FLAGS) -o $dst ${d_path}(+)${s_base}.iii Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zhiju.Fan --- BaseTools/Conf/build_rule.template

[edk2] [Patch 0/2 V2] Update .nasm to support $(INC)-like support

2018-10-25 Thread Yonghong Zhu
V2: 1. remove FileMacro variable 2. Make sure the NASM_INC file path have '\' in the end Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=1085 Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zhiju.Fan zhijufan (2): BaseTools: Add

[edk2] [Patch 1/2 V2] BaseTools: Add $(INC)-like support when compiling .nasm files

2018-10-25 Thread Yonghong Zhu
source file directory. As a comparison, the compile of both .s and .asm have $(INC) support in their compile commands. Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=1085 Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zhiju.Fan

[edk2] [Patch] FDF spec: Add PI1.5 standalone SMM support in FDF file

2018-10-25 Thread Yonghong Zhu
V2: Update it to MM_CORE_STANDALONE and MM_STANDALONE Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=551 Cc: Liming Gao Cc: Michael Kinney Cc: Kevin W Shaw Cc: Cohen, Eugene Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- 1_introduction

[edk2] [Patch 1/2] BaseTools: Add $(INC)-like support when compiling .nasm files

2018-10-25 Thread Yonghong Zhu
source file directory. As a comparison, the compile of both .s and .asm have $(INC) support in their compile commands. Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=1085 Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zhiju.Fan

[edk2] [Patch 2/2] BaseTools: Update nasm file build rule to support $(INC)

2018-10-25 Thread Yonghong Zhu
From: zhijufan Update the build rule to: "$(NASM)" -I${s_path}(+) $(NASM_INC)(+) $(NASM_FLAGS) -o $dst ${d_path}(+)${s_base}.iii Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zhiju.Fan --- BaseTools/Conf/build_rule.template

[edk2] [Patch 0/2] Update .nasm to support $(INC)-like support

2018-10-25 Thread Yonghong Zhu
Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=1085 Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zhiju.Fan zhijufan (2): BaseTools: Add $(INC)-like support when compiling .nasm files BaseTools: Update nasm file build rule

[edk2] [Patch V2] BaseTools: Fix the bug for Pcd used in command line's override

2018-10-24 Thread Yonghong Zhu
ld command with --pcd TokenSpaceGuid.PcdTest="BB" Then we found the Pcd value in the AutoGen.c file is incorrect, because of the incorrect logic that use the pcd in the [component] section to re-override it. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong

[edk2] [Patch] BaseTools: list .nasm include inc files as its dependency

2018-10-24 Thread Yonghong Zhu
From: zhijufan .nasm source file may include some header files. header file should be listed in Makefile as .nasm source file dependency. But now, BaseTools doesn't find them and list them in Makefile. This is a missing, because original ASM file supports it. Cc: Liming Gao Cc: Yonghong Zhu

[edk2] [Patch] BaseTools: Fix the bug for Pcd used in command line's override

2018-10-24 Thread Yonghong Zhu
id.PcdTest="BB" Then we found the Pcd value in the AutoGen.c file is incorrect, because of the incorrect logic that use the pcd in the [component] section to re-override it. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Pytho

[edk2] [Patch] BaseTools: Fix VPD PCD Sub-section display bug

2018-10-23 Thread Yonghong Zhu
of the report. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/build/BuildReport.py | 46 ++-- 1 file changed, 17 insertions(+), 29 deletions(-) diff --git a/BaseTools/Source/Python/build/BuildReport.py b

[edk2] [Patch] FDF spec: Add PI1.5 standalone SMM support in FDF file

2018-10-22 Thread Yonghong Zhu
Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=551 Cc: Liming Gao Cc: Michael Kinney Cc: Kevin W Shaw Cc: Cohen, Eugene Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- 1_introduction/12_terms.md| 9

[edk2] [Patch] FDF Spec: Add the $(PCD) usage in the [FD] section

2018-10-22 Thread Yonghong Zhu
: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- 2_fdf_design_discussion/24_[fd]_sections.md | 2 +- 3_edk_ii_fdf_file_format/35_[fd]_sections.md | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/2_fdf_design_discussion/24_[fd]_sections.md b

[edk2] [Patch] BaseTools: Fix the bug that PcdValueFromComm is not set

2018-10-19 Thread Yonghong Zhu
the bug is PcdValueFromComm is not set, but the Pcd have been override by the command line option. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/Workspace/DscBuildData.py | 1 + 1 file changed, 1 insertion(+) diff --git

[edk2] [Patch] BaseTools: Fix the crash issue when Dynamic structure Pcd use in FDF

2018-10-19 Thread Yonghong Zhu
Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/AutoGen/AutoGen.py | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/BaseTools/Source/Python/AutoGen/AutoGen.py b/BaseTools/Source/Python/AutoGen/AutoGen.py index f2146a7..804f579 100644

[edk2] [Patch] BaseTools: Fix the *B and *F Flag display for Structure Pcd

2018-10-19 Thread Yonghong Zhu
Because of we newly add the PcdFieldValueFromComm and PcdFieldValueFromFdf in early parser phase, so in the report we use the saved value in this two variables to print it. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/build

[edk2] [Patch] BaseTools: Fix one crash bug in the report for Fixed structure Pcd

2018-10-18 Thread Yonghong Zhu
"DEFAULT", and in this case the "DEFAULT" SKU doesn't save any value, then it cause the Data is empty, in the next code when we use the code it cause crash. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/build

[edk2] [PATCH V2] BaseTools/ECC: Add a checkpoint to check no usage for deprecated functions.

2018-10-17 Thread Yonghong Zhu
From: Hess Chen V2: change list to set Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hess Chen --- BaseTools/Source/Python/Ecc/Check.py | 60 BaseTools/Source/Python/Ecc/Configuration.py | 3 ++

[edk2] [Patch] BaseTools: Fix bug caused by 03c36c36a3

2018-10-17 Thread Yonghong Zhu
In the expression for unicode string and general string compare, it should check whether it startswith "L'" or 'L"', but not "L". Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/Common/Expression.py |

[edk2] [PATCH] BaseTools/ECC: Add a checkpoint to check no usage for deprecated functions.

2018-10-16 Thread Yonghong Zhu
From: Hess Chen Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hess Chen --- BaseTools/Source/Python/Ecc/Check.py | 60 BaseTools/Source/Python/Ecc/Configuration.py | 3 ++ BaseTools/Source/Python/Ecc/EccToolError.py | 2 +

[edk2] [Patch] BaseTools: Fix a bug --pcd option enable and use the pcd in expression

2018-10-16 Thread Yonghong Zhu
-by: Yonghong Zhu --- BaseTools/Source/Python/Workspace/DscBuildData.py | 1 + 1 file changed, 1 insertion(+) diff --git a/BaseTools/Source/Python/Workspace/DscBuildData.py b/BaseTools/Source/Python/Workspace/DscBuildData.py index f41038e..ace348b 100644 --- a/BaseTools/Source/Python/Workspace

[edk2] [PATCH] BaseTools/ECC: Fix an identification issue of typedef function.

2018-10-16 Thread Yonghong Zhu
From: Hess Chen Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hess Chen --- BaseTools/Source/Python/Ecc/Check.py | 12 +++- BaseTools/Source/Python/Ecc/c.py | 8 ++-- 2 files changed, 17 insertions(+), 3 deletions(-) diff --git

[edk2] [PATCH] BaseTools/UPT: Fix an issue of UNI string checking.

2018-10-16 Thread Yonghong Zhu
From: Hess Chen The tool now can detect the error that the content between double quotes contains another double quotes or enter key. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hess Chen --- .../Source/Python/UPT/Library/UniClassObject.py| 23

[edk2] [PATCH] BaseTools/Ecc: Update a checkpoint criteria.

2018-10-16 Thread Yonghong Zhu
From: Hess Chen Change the criteria of the checkpoint of "#ifndef" to remove the requirement of prefix '_'. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hess Chen --- BaseTools/Source/Python/Ecc/Check.py| 2 +- BaseTools/Source/Python/Ecc/EccToolError.py | 2

[edk2] [Patch] Expression spec: Add clarification for String compare

2018-10-15 Thread Yonghong Zhu
evin W Shaw Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- 2_expression_overview.md | 13 - 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/2_expression_overview.md b/2_expression_overview.md index c29a632..bf66ffe 100644 --- a/

[edk2] [Patch] BaseTools: Support to use struct name as datum type before max size

2018-10-15 Thread Yonghong Zhu
Original it hard code to use "VOID*", this patch extend it to both support VOID* and valid struct name. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/Common/Misc.py | 4 +++- BaseTools/Source/Python

[edk2] [Patch] BaseTools: Fix bugs use special character in the --pcd option

2018-10-15 Thread Yonghong Zhu
Cases: --pcd Token.Name="!" --pcd Token.Name="\'W&\'" --pcd Token.Name="2*h" Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/Workspace/DscBuildData.py | 2 ++ 1 file changed, 2 insertions(+) di

[edk2] [Patch] BaseTools: Add check for the string type whether is same

2018-10-15 Thread Yonghong Zhu
From: zhijufan Relational and equality operators require both operands to be of the same type. Treat the string 'A' and "A" as same type, but for "A" and L"A" are not same type since one is general string, another is unicode string. True:'A'<'B', "

[edk2] [PATCH] BaseTools/EOT: Change to call a program instead of calling Python API.

2018-10-15 Thread Yonghong Zhu
From: hchen30 Update the EOT tool to call the program itself instead of calling the Python API when parsing FV images. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hess Chen --- BaseTools/Source/Python/Eot/{Eot.py => EotMain.py} | 465 +++--

[edk2] [Patch] BaseTools/Tests: Update GNUmakefile to use python3 variable

2018-10-13 Thread Yonghong Zhu
Cover the case use do make -C BaseTools before run the .edksetup.sh file. Cc: Ard Biesheuvel Cc: Leif Lindholm Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Tests/GNUmakefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[edk2] [Patch] BaseTools: Remove the logic that check Python3 version larger than 3.6

2018-10-13 Thread Yonghong Zhu
Remove the logic that the Python3 version must larger than 3.6. We verified Python3 migration patches on version 3.6 and 3.7. for other version we not verified it. Cc: Ard Biesheuvel Cc: Leif Lindholm Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu

[edk2] [PATCH] BaseTools: Add --uefi option to enable UefiCompress method

2018-10-11 Thread Yonghong Zhu
From: Yunhua Feng Add one new option --uefi to enable UefiCompress. Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yunhua Feng --- BaseTools/Source/C/TianoCompress/TianoCompress.c | 81 +--- BaseTools/Source/C

[edk2] [PATCH] BaseTools: increment build generate inf file lost .depex file

2018-10-11 Thread Yonghong Zhu
From: Yunhua Feng increment build generate inf file in output directory lost .depex file info. Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=1244 Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yunhua Feng --- BaseTools/Source

[edk2] [PATCH] BaseTools: Not compare the VOID* difference in the DSC and DEC file

2018-10-11 Thread Yonghong Zhu
-by: Yonghong Zhu --- BaseTools/Source/Python/Workspace/DscBuildData.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/BaseTools/Source/Python/Workspace/DscBuildData.py b/BaseTools/Source/Python/Workspace/DscBuildData.py index 02aae3a67b..5ed879c8d7 100644 --- a/BaseTools/Source

[edk2] [Patch] Build Spec: Add description for Structure Pcd display in the module

2018-10-11 Thread Yonghong Zhu
The detail rules are totally same with Global Pcd section. Cc: Liming Gao Cc: Michael Kinney Cc: Kevin W Shaw Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- 13_build_reports/136_global_pcd_section.md | 12 ++-- 13_build_reports

[edk2] [Patch] BaseTools: Enhance the *P Flag display for Structure Pcd

2018-10-11 Thread Yonghong Zhu
-by: Yonghong Zhu --- BaseTools/Source/Python/build/BuildReport.py | 66 1 file changed, 39 insertions(+), 27 deletions(-) diff --git a/BaseTools/Source/Python/build/BuildReport.py b/BaseTools/Source/Python/build/BuildReport.py index feaf6a5..031594b 100644 --- a/BaseTools

[edk2] [Patch] BaseTools: do basic check in FvImage with header size and signature

2018-09-29 Thread Yonghong Zhu
From: zhijufan Add some basic check in FvImage with header size and signature. Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=1181 Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zhiju.Fan --- BaseTools/Source/Python/GenFds/Fv.py

[edk2] [Patch] BaseTools: refactor the error for PCD value is negative or exceed max

2018-09-28 Thread Yonghong Zhu
From: zhijufan refactor the error handling for the PCD value that is negative or it exceed the max value. Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zhiju.Fan --- BaseTools/Source/Python/AutoGen/GenC.py | 57

[edk2] [Patch] Build Spec: Add some clarification of Build report section

2018-09-25 Thread Yonghong Zhu
1. Add the section header of Global PCD Section 2. Add 'INF DEFAULT' in the module PCD section Cc: Liming Gao Cc: Michael Kinney Cc: Kevin W Shaw Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- 13_build_reports/136_global_pcd_section.md | 13

[edk2] [Patch] Build Spec: Update EBNF of --pcd for String type to at least one char

2018-09-25 Thread Yonghong Zhu
Update the '*' in the EBNF to '+' which means in the string there at least need one char. the case like "" is not supported. Cc: Liming Gao Cc: Michael Kinney Cc: Kevin W Shaw Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- appendix_d_builde

[edk2] [Patch] BaseTools: remove the not used PyUtility file

2018-09-17 Thread Yonghong Zhu
the PyUtility is not used, so we remove it. Cc: Liming Gao Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/C/PyUtility/Makefile| 25 --- BaseTools/Source/C/PyUtility/PyUtility.c | 106

[edk2] [Patch] BaseTools: remove PyUtility and open the file with unbuffered

2018-09-17 Thread Yonghong Zhu
-by: Yonghong Zhu --- BaseTools/Source/C/PyUtility/Makefile| 25 --- BaseTools/Source/C/PyUtility/PyUtility.c | 106 --- BaseTools/Source/C/PyUtility/setup.py| 42 --- BaseTools/Source/Python/Common/Misc.py | 16 +--- BaseTools/Source/Python

[edk2] [Patch] BaseTools: Fix a bug for Unused PCDs section display in the report

2018-09-12 Thread Yonghong Zhu
From: zhijufan Fix a regression issue caused by ac4578af364, when there doesn't exist not used PCD, it also display the not used Pcd section in the report. Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=1170 Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution

[edk2] [Patch V2] INF spec: Correct some items in the Table 1 EDK II [Defines] Section

2018-09-12 Thread Yonghong Zhu
format spec this table's display was cut off. Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=1162 Cc: Liming Gao Cc: Michael Kinney Cc: Kevin W Shaw Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- 2_inf_overview/24_[defines]_section.md

[edk2] [Patch] BaseTools: Align the boolean type PCD value's display in the report

2018-09-11 Thread Yonghong Zhu
From: zhijufan This patch align the boolean type PCD value's display in the build report. Original it may display 0x0, also may use 0 for the same PCD. Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zhiju.Fan --- BaseTools/Source

[edk2] [Patch] BaseTools: Report error for incorrect hex value format

2018-09-10 Thread Yonghong Zhu
From: zhijufan The case is user use 0x1} as a hex value for Pcd, it directly cause tool report traceback info. This patch add more error info. Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zhiju.Fan --- BaseTools/Source/Python/Common

[edk2] [Patch] Build spec: correct the Operator used in the expression for Table 12

2018-09-07 Thread Yonghong Zhu
Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=598 Cc: Liming Gao Cc: Michael Kinney Cc: Kevin W Shaw Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- .../82_auto-generation_process.md | 34 +++--- README.md

[edk2] [Patch] INF spec: Correct some items in the Table 1 EDK II [Defines] Section

2018-09-07 Thread Yonghong Zhu
Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=1162 Cc: Liming Gao Cc: Michael Kinney Cc: Kevin W Shaw Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- 2_inf_overview/24_[defines]_section.md | 59

[edk2] [Patch] BaseTools: Fix the RaiseError variable issue caused by 855698fb69f

2018-09-04 Thread Yonghong Zhu
The bug is that it cause the RaiseError always be set to TRUE even we call the function with FALSE parameter. Cc: Hess Chen Cc: Liming Gao Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/Common/EdkLogger.py | 4 ++-- 1 file

[edk2] [Patch] BaseTools: Fix a bug about list the PCD in "not used" section

2018-09-04 Thread Yonghong Zhu
From: zhijufan Defined a pcd in Ovmf.dec and used that pcd in AcpiPlatformDxe.inf, then assign a value to that pcd from DSC, then build Ovmf platform successfully. But this Pcd was wrongly listed into not used section in the report.txt file. Cc: Liming Gao Cc: Yonghong Zhu Contributed-under

[edk2] [Patch] BaseTools: Report more clear error message for PCD used in expression

2018-09-04 Thread Yonghong Zhu
From: zhijufan Only the FeatureFlag type or FixedAtBuild type can be used in the expression. Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zhiju.Fan --- BaseTools/Source/Python/Common/Expression.py | 2 +- BaseTools/Source/Python

[edk2] [Patch] BaseTools: Extend the keyword "!include"/"!if" to case-insensitive

2018-09-03 Thread Yonghong Zhu
From: zhijufan Extend the keyword "!include", "!if", etc to case-insensitive. Current DSC parser already support it, while FDF parser only support the lower case, so this patch add the support for FDF parser. Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Co

[edk2] [Patch] FDF Spec: Extend exclamation statement's keyword to case-insensitive

2018-09-03 Thread Yonghong Zhu
This patch add some description for "!include", "!error", "!if", etc, to extend those statement's keyword to case-insensitive. Cc: Liming Gao Cc: Michael Kinney Cc: Kevin W Shaw Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu

[edk2] [Patch] Build Spec: Extend exclamation statement's keyword to case-insensitive

2018-09-03 Thread Yonghong Zhu
This patch add some description for "!include", "!error", "!if", etc, to extend those statement's keyword to case-insensitive. Cc: Liming Gao Cc: Michael Kinney Cc: Kevin W Shaw Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by:

[edk2] [Patch] DSC Spec: Extend exclamation statement's keyword to case-insensitive

2018-09-03 Thread Yonghong Zhu
This patch add some description for "!include", "!error", "!if", etc, to extend those statement's keyword to case-insensitive. Cc: Liming Gao Cc: Michael Kinney Cc: Kevin W Shaw Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yon

[edk2] [Patch] BaseTools: include variable namespace GUIDs of HII PCDs in Guid.xref

2018-08-28 Thread Yonghong Zhu
From: zhijufan [PcdsDynamicHii] gFooTokenSpaceGuid.PcdBar|L"Variable"|gVarNameSpaceGuid|0x0|FALSE|NV,BS This patch add the variable namespace GUIDs in "Guid.xref" that are used with dynamic HII PCDs. Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=452 Cc: Liming G

[edk2] [PATCH] BaseTools: Add check only VOID* type Pcd need the maxsize info

2018-08-26 Thread Yonghong Zhu
From: zhijufan Add check for the datum type keyword "VOID*", only the VOID* type Pcd need the additional maxsize info. Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zhiju.Fan --- BaseTools/Source/Python/Common/Misc.py

[edk2] [Patch V2] BaseTools: Update Makefile for ECC tool

2018-08-22 Thread Yonghong Zhu
V2: Add --target-name to specify the file name to create Because Ecc.py was renamed to EccMain.py Cc: Liming Gao Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions

[edk2] [Patch] BaseTools: Update Makefile for ECC tool

2018-08-22 Thread Yonghong Zhu
Because Ecc.py was renamed to EccMain.py Cc: Liming Gao Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/BaseTools/Source/Python/Makefile b

[edk2] [Patch] BaseTools: Fix one expression bug to support ~ operate

2018-08-22 Thread Yonghong Zhu
current use (0x41>=~0x0&0x41|0x0) as Pcd value cause build failure because the ~ is not correctly recognized. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/Common/Expression.py | 2 +- 1 file changed, 1 insertion(+), 1 d

[edk2] [Patch V2] BaseTools: Clean up not used code in BuildClassObject

2018-08-13 Thread Yonghong Zhu
V2: Add back "from Common.DataType import *" 1. Remove some import statement that are not used. 2. Remove the Type value in the LibraryClassObject because we don't actually use it. Cc: Liming Gao Cc: Jaben Carsey Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by

[edk2] [Patch] BaseTools: Clean up not used code in BuildClassObject

2018-08-12 Thread Yonghong Zhu
1. Remove some import statement that are not used. 2. Remove the Type value in the LibraryClassObject because we don't actually use it. Cc: Liming Gao Cc: Jaben Carsey Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/Workspace

[edk2] [Patch] BaseTools: Remove the redundant if statement

2018-08-10 Thread Yonghong Zhu
after analysis the BuildOptionValue function, we found the if statement IsFieldValueAnArray is redundant because ValueExpressionEx will handle it. Cc: Liming Gao Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/Common/Expression.py

[edk2] [Patch] BaseTools: Update the rule to remove .lib before link it for GCC

2018-08-08 Thread Yonghong Zhu
delete it first. Cc: Liming Gao Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Conf/build_rule.template | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/BaseTools/Conf/build_rule.template b/BaseTools/Conf/build_rule.template

[edk2] [PATCH] BaseTools/Ecc: Fix import issues

2018-08-08 Thread Yonghong Zhu
From: hchen30 1. Complete the full path for import statement. Use "EccMain" to replace "Ecc" for the absolute path support. 2. Fix some issues on configuration file. 3. Fix an issue of RaiseError not working in EdkLogger. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by:

[edk2] [Patch] BaseTools: Add check for VOID* PCD Max Size

2018-08-03 Thread Yonghong Zhu
Per spec VOID* PCD max size should be a UINT16 value. so this patch add the value check whether it is in range 0x0 .. 0x. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/Workspace/DscBuildData.py | 21 + 1

[edk2] [Patch] DSC Spec: limit the VOID* PCD max size to UINT16

2018-08-03 Thread Yonghong Zhu
Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- 2_dsc_overview/29_pcd_sections.md| 6 +++--- 3_edk_ii_dsc_file_format/310_pcd_sections.md | 8 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/2_dsc_overview/29_pcd_sections.md b

[edk2] [Patch] Build Spec: Add rules for structure pcd display in the report

2018-07-31 Thread Yonghong Zhu
Cc: Liming Gao Cc: Michael Kinney Cc: Kevin W Shaw Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- 13_build_reports/136_global_pcd_section.md | 32 +- 1 file changed, 23 insertions(+), 9 deletions(-) diff --git

[edk2] [PATCH] BaseTools: Use pickle to replace cPickle

2018-07-31 Thread Yonghong Zhu
From: Yunhua Feng Use pickle to replace cPickle because of python3 removed cPickle Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yunhua Feng --- BaseTools/Source/Python/Common/Misc.py | 6 +++--- 1 file changed, 3 insertions(+), 3

[edk2] [PATCH] BaseTools: remove unused import thread

2018-07-31 Thread Yonghong Zhu
From: Yunhua Feng remove unused import thread Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yunhua Feng --- BaseTools/Source/Python/Common/Misc.py | 1 - 1 file changed, 1 deletion(-) diff --git a/BaseTools/Source/Python/Common

[edk2] [PATCH] BaseTools: Guid.xref doesn't specify the correct GUID value for Driver

2018-07-31 Thread Yonghong Zhu
/DriverSampleDxe.inf { FILE_GUID = 3A4A354F-6935-40fa-B19C-500EEEBF0BC2 PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf } Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yunhua Feng --- BaseTools/Source/Python

[edk2] [PATCH] BaseTools: Update build report for StructurePcd value

2018-07-26 Thread Yonghong Zhu
From: Yunhua Feng Update build report to display the structure Pcd value that from FDF file. Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yunhua Feng --- BaseTools/Source/Python/build/BuildReport.py | 14 -- 1 file

[edk2] [PATCH] BaseTools: Fix build crash when fdf is empty file

2018-07-25 Thread Yonghong Zhu
From: Yunhua Feng Fix build crash when fdf is empty file Fix https://bugzilla.tianocore.org/show_bug.cgi?id=912 Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yunhua Feng --- BaseTools/Source/Python/GenFds/FdfParser.py | 2 ++ 1 file

[edk2] [PATCH] BaseTools: Parse decimal format INF_VERSION incorrect

2018-07-24 Thread Yonghong Zhu
From: Yunhua Feng hex number 0x00010019, the major number is 0001, the minor number is 0019. the decimal number 1.25, the major number is 1, and the minor number is 25 Fix https://bugzilla.tianocore.org/show_bug.cgi?id=921 Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore

[edk2] [Patch] BaseTools: Fix bug about *M value not display decimal and hexadecimal

2018-07-24 Thread Yonghong Zhu
From: Yunhua Feng V2: Add the check for Pcd DatumType report format like as below: *M Shell.inf = 0xFF (255) Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yunhua Feng --- BaseTools/Source/Python/build/BuildReport.py | 8

[edk2] [Patch] BaseTools: Fix bug about *M value not display decimal and hexadecimal

2018-07-24 Thread Yonghong Zhu
From: Yunhua Feng report format like as below: *M Shell.inf = 0xFF (255) Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yunhua Feng --- BaseTools/Source/Python/build/BuildReport.py | 7 ++- 1 file changed, 6 insertions

[edk2] [PATCH] BaseTools: Fix build report for *P and *M flag incorrectly

2018-07-23 Thread Yonghong Zhu
From: Yunhua Feng Flag *M for INF defined value and DSC components value Flag *P only for platform defined value Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yunhua Feng --- BaseTools/Source/Python/build/BuildReport.py | 20

[edk2] [PATCH] BaseTools/Ecc: Add some new checkpoints

2018-07-23 Thread Yonghong Zhu
From: hchen30 1. Add a checkpoint to check NO TABs. 2. Add a checkpoint to check line ending with CRLF. 3. Add a checkpoint to check no trailing spaces. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hess Chen --- BaseTools/Source/Python/Ecc/Check.py | 54

[edk2] [Patch] BaseTools: Correct _PCD_PATCHABLE_TokenName_SIZE's value

2018-07-22 Thread Yonghong Zhu
current if user use PatchPcdSetPtr in library, it will report the _PCD_PATCHABLE_TokenName_SIZE is not defined. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/AutoGen/GenC.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions

[edk2] [Patch V3] BaseTools: enable FixedAtBuild (VOID*) PCD use in the [DEPEX] section

2018-07-16 Thread Yonghong Zhu
://bugzilla.tianocore.org/show_bug.cgi?id=443 Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yunhua Feng --- BaseTools/Source/Python/AutoGen/AutoGen.py| 32 +-- BaseTools/Source/Python/AutoGen/GenDepex.py | 6

[edk2] [Patch] BaseTools: Remove the duplicate Pcd items

2018-07-16 Thread Yonghong Zhu
is different in the module and lib. but actually we only need use the Pcd value in the module to decide whether it use the same value. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/AutoGen/AutoGen.py | 2 +- 1 file changed, 1 insertion

[edk2] [Patch] BaseTools: ElfConvert Tool update VerboseMsg to same with the comment

2018-07-12 Thread Yonghong Zhu
Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=994 Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Yonghong Zhu --- BaseTools/Source/C/GenFw/Elf32Convert.c | 2 +- BaseTools/Source/C/GenFw/Elf64Convert.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff

[edk2] [Patch] BaseTools: Fix the bug that incorrect size info in the Lib autogen

2018-07-09 Thread Yonghong Zhu
Agreement 1.0 Signed-off-by: Yonghong Zhu --- BaseTools/Source/Python/AutoGen/AutoGen.py | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/BaseTools/Source/Python/AutoGen/AutoGen.py b/BaseTools/Source/Python/AutoGen/AutoGen.py index 6d76afd..3908697 100644 --- a/BaseTools

[edk2] [Patch V2] BaseTools: enable FixedAtBuild (VOID*) PCD use in the [DEPEX] section

2018-07-05 Thread Yonghong Zhu
Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yunhua Feng --- BaseTools/Source/Python/AutoGen/AutoGen.py| 31 --- BaseTools/Source/Python/AutoGen/GenDepex.py | 6 + BaseTools/Source/Python/Workspace

[edk2] [Patch] BaseTools: enable FixedAtBuild (VOID*) PCD use in the [DEPEX] section

2018-07-03 Thread Yonghong Zhu
From: Yunhua Feng The PCD item used in INF [Depex] section must be defined as FixedAtBuild type and VOID* datum type, and the size of the PCD must be 16 bytes. Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=443 Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution

[edk2] [Patch V2] BaseTools: Fix parsing multiple nest !include issue

2018-06-28 Thread Yonghong Zhu
n.PcdTest2 | "B" Cc: Liming Gao Cc: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yunhua Feng --- .../Source/Python/Workspace/MetaFileParser.py | 28 ++ 1 file changed, 13 insertions(+), 15 deletions(-) diff --git a/Bas

[edk2] [Patch V2] FDF Spec: support varstore template generation with a [FV] section

2018-06-28 Thread Yonghong Zhu
Add format to support varstore template generation with a dedicated [FV] section. Code bug: https://bugzilla.tianocore.org/show_bug.cgi?id=932 Cc: Liming Gao Cc: Michael Kinney Cc: Kevin W Shaw Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu

[edk2] [Patch] FDF spec: document WEAK_ALIGNMENT attribute

2018-06-27 Thread Yonghong Zhu
WEAK_ALIGNMENT FV attribute is supported by GenFds, but is not documented in the FDF specification. Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=892 Cc: Liming Gao Cc: Michael Kinney Cc: Kevin W Shaw Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu

[edk2] [Patch] FDF Spec: support varstore template generation with a [FV] section

2018-06-26 Thread Yonghong Zhu
Add format to support varstore template generation with a dedicated [FV] section. Code bug: https://bugzilla.tianocore.org/show_bug.cgi?id=932 Cc: Liming Gao Cc: Michael Kinney Cc: Kevin W Shaw Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yonghong Zhu

[edk2] [PATCH] BaseTools/PackageDocumentTools: Correct INI parse condition check

2018-06-25 Thread Yonghong Zhu
From: "Chen, Pai-Ching" Change-Id: I147ad470d5840c6fee1086f629991f8a9f9d9056 Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Chen, Pai-Ching --- .../Scripts/PackageDocumentTools/plugins/EdkPlugins/basemodel/ini.py| 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)

[edk2] [Patch] BaseTools: Fix two drivers include the same file issue

2018-06-24 Thread Yonghong Zhu
: Yonghong Zhu Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Yunhua Feng --- BaseTools/Source/Python/Workspace/MetaDataTable.py | 27 +- .../Source/Python/Workspace/MetaFileParser.py | 4 ++-- BaseTools/Source/Python/Workspace/MetaFileTable.py | 14

[edk2] [Patch] BaseTools: Fix parsing multiple nest !include issue

2018-06-24 Thread Yonghong Zhu
From: Yunhua Feng Case example: DSC components: !include Test1.txt Test1.txt: TestPkg/TestDriver.inf { PcdToken.PcdTest1 | "A" !include Test2.txt } Test2.txt: !include Test3.txt Test3.txt: PcdToken.PcdTest2 | "B" Cc: Liming Gao Cc: Yonghong Zhu Contribu

  1   2   3   4   5   6   >