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

Yonghong Zhu posted 1 patch 5 years, 11 months ago
Failed in applying to current master (apply log)
3_edk_ii_inf_file_format/314_[depex]_sections.md | 20 ++++++++++++--------
1 file changed, 12 insertions(+), 8 deletions(-)
[edk2] [Patch] INF Spec: FixedAtBuild (VOID*) PCD use in the [DEPEX] section
Posted by Yonghong Zhu 5 years, 11 months ago
Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=444
Cc: Liming Gao <liming.gao@intel.com>
Cc: Michael Kinney <michael.d.kinney@intel.com>
Cc: Kevin W Shaw <kevin.w.shaw@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Yonghong Zhu <yonghong.zhu@intel.com>
---
 3_edk_ii_inf_file_format/314_[depex]_sections.md | 20 ++++++++++++--------
 1 file changed, 12 insertions(+), 8 deletions(-)

diff --git a/3_edk_ii_inf_file_format/314_[depex]_sections.md b/3_edk_ii_inf_file_format/314_[depex]_sections.md
index e325f06..942bcf9 100644
--- a/3_edk_ii_inf_file_format/314_[depex]_sections.md
+++ b/3_edk_ii_inf_file_format/314_[depex]_sections.md
@@ -1,9 +1,9 @@
 <!--- @file
   3.14 [Depex] Sections
 
-  Copyright (c) 2007-2017, Intel Corporation. All rights reserved.<BR>
+  Copyright (c) 2007-2018, Intel Corporation. All rights reserved.<BR>
 
   Redistribution and use in source (original document form) and 'compiled'
   forms (converted to PDF, epub, HTML and other formats) with or without
   modification, are permitted provided that the following conditions are met:
 
@@ -156,10 +156,13 @@ that will be loaded from the shell or stored in a PCI option ROM) will not have
 an FFS DEPEX section generated by the tools.
 **********
 **Note:** Capitalization in the Prototypes listed below does not match the
 capitalization used in the PI Specification.
 **********
+**Note:** The PCD item used in this section must be defined as FixedAtBuild type
+and VOID* datum type, and the size of the PCD must be 16 bytes.
+**********
 
 #### Prototype
 
 ```c
 <Depex>              ::= "[Depex" [<com_attribs>] "]" <EOL>
@@ -171,37 +174,38 @@ capitalization used in the PI Specification.
 <DepexModuleType>    ::= {"PEIM"} {"DXE_DRIVER"} {"DXE_SMM_DRIVER"}
                          {"DXE_RUNTIME_DRIVER"} {"DXE_SAL_DRIVER"}
                          {"UEFI_DRIVER"} {"USER_DEFINED"}
 <DepexSection>       ::= {<PeiDepex>} {<SmmDepex>} {<DxeDepex>}
 <DxeDepex>           ::= <DxeDepexStatements>+ ["END" <EOL>]
-<DxeDepexStatements> ::= {<SorStmt>} {<GuidStmt>} {<BoolStmt>}
+<DxeDepexStatements> ::= {<SorStmt>} {<GuidOrPcdStmt>} {<BoolStmt>}
 <PeiDepex>           ::= <PeiDepexStatements>*
                          ["END" <EOL>]
 <PeiDepexStatements> ::= {<BoolStmt>} {<DepInstruct>}
 <SmmDepex>           ::= <DxeDepex>
-<GuidStmt>           ::= {"BEFORE"} {"AFTER"} <GuidCName> [<EOL>]
+<GuidOrPcdStmt>      ::= {"BEFORE"} {"AFTER"} <GuidOrPcdName> [<EOL>]
+<GuidOrPcdName>      ::= {<GuidCName>} {<PcdName>}
 <DepInstruct>        ::= "PUSH" <CFormatGUID> [<EOL>]
 <SorStmt>            ::= "SOR" <BoolStmt> [<EOL>]
 <BoolStmt>           ::= {<Bool>} {<BoolExpress>}
-<Bool>               ::= {"TRUE"} {"FALSE"} {<GuidCName>} [<EOL>]
+<Bool>               ::= {"TRUE"} {"FALSE"} {<GuidCName>} {<PcdName>} [<EOL>]
 <GuidCName>          ::= <CName> # A Guid C Name
 <NTs>                ::= "NOT" <TS>
 <BoolExpress>        ::= <NTs> <Bool> [<BoolExpressCont>]*
 <BoolExpressCont>    ::= <MTS> {"AND"} {"OR"} <MTS> [<NTs>] <Bool>
 <AsBuiltDepex>       ::= "#" {<FullDxe>} {<FullPei>} {<FullSmm>} <EOL>
 <FullDxe>            ::= <DxeStatements>+
                          [<TS> "END"]
-<DxeStatements>      ::= {<SorAbStmt>} {<GuidAbStmt>} {<BoolAbStmt>}
+<DxeStatements>      ::= {<SorAbStmt>} {<GuidOrPcdAbStmt>} {<BoolAbStmt>}
 <FullPei>            ::= <PeiStatements>*
                          [<TS> "END"]
 <PeiStatements>      ::= {<BoolAbStmt>} {<DepAbInstruct>}
 <FullSmm>            ::= <FullDxe>
-<GuidAbStmt>         ::= {"BEFORE"} {"AFTER"} <TS> <GuidCName> <TS>
+<GuidOrPcdAbStmt>    ::= {"BEFORE"} {"AFTER"} <TS> <GuidOrPcdName> <TS>
 <DepAbInstruct>      ::= "PUSH" <TS> <CFormatGUID> <TS>
 <SorAbStmt>          ::= "SOR" <TS> <BoolAbStmt> <TS>
 <BoolAbStmt>         ::= {<BoolAb>} {<BoolAbExpress>}
-<BoolAb>             ::= {"TRUE"} {"FALSE"} {<GuidCName>} <TS>
+<BoolAb>             ::= {"TRUE"} {"FALSE"} {<GuidCName>} {<PcdName>} <TS>
 <GuidCName>          ::= <CName> # A Guid C Name
 <BoolAbExpress>      ::= <NTs> <Bool> [<BoolAbExpressCont>]*
 <BoolAbExpressCont>  ::= <MTS> {"AND"} {"OR"} <MTS> [<NTs>] <Bool>
 ```
 
@@ -212,11 +216,11 @@ capitalization used in the PI Specification.
   gEfiFirmwareVolumeBlockProtocolGuid
   AND gEfiAlternateFvBlockGuid
   AND gEfiFaultTolerantWriteLiteProtocolGuid
 
 [Depex]
-  SOR gEfiProtocolIDependOnGuid
+  gEfiNt32PkgTokenSpaceGuid.PcdGuidTest
 
 [Depex.common]
   SOR gEfiProtocolIDependOnGuid
 
 [Depex.IA32.DXE_SMM_DRIVER]
-- 
2.6.1.windows.1

_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel
Re: [edk2] [Patch] INF Spec: FixedAtBuild (VOID*) PCD use in the [DEPEX] section
Posted by Gao, Liming 5 years, 11 months ago
Reviewed-by: Liming Gao <liming.gao@intel.com>

>-----Original Message-----
>From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of
>Yonghong Zhu
>Sent: Thursday, June 14, 2018 3:43 PM
>To: edk2-devel@lists.01.org
>Cc: Kinney, Michael D <michael.d.kinney@intel.com>; Shaw, Kevin W
><kevin.w.shaw@intel.com>; Gao, Liming <liming.gao@intel.com>
>Subject: [edk2] [Patch] INF Spec: FixedAtBuild (VOID*) PCD use in the [DEPEX]
>section
>
>Fixes: https://bugzilla.tianocore.org/show_bug.cgi?id=444
>Cc: Liming Gao <liming.gao@intel.com>
>Cc: Michael Kinney <michael.d.kinney@intel.com>
>Cc: Kevin W Shaw <kevin.w.shaw@intel.com>
>Contributed-under: TianoCore Contribution Agreement 1.1
>Signed-off-by: Yonghong Zhu <yonghong.zhu@intel.com>
>---
> 3_edk_ii_inf_file_format/314_[depex]_sections.md | 20 ++++++++++++-----
>---
> 1 file changed, 12 insertions(+), 8 deletions(-)
>
>diff --git a/3_edk_ii_inf_file_format/314_[depex]_sections.md
>b/3_edk_ii_inf_file_format/314_[depex]_sections.md
>index e325f06..942bcf9 100644
>--- a/3_edk_ii_inf_file_format/314_[depex]_sections.md
>+++ b/3_edk_ii_inf_file_format/314_[depex]_sections.md
>@@ -1,9 +1,9 @@
> <!--- @file
>   3.14 [Depex] Sections
>
>-  Copyright (c) 2007-2017, Intel Corporation. All rights reserved.<BR>
>+  Copyright (c) 2007-2018, Intel Corporation. All rights reserved.<BR>
>
>   Redistribution and use in source (original document form) and 'compiled'
>   forms (converted to PDF, epub, HTML and other formats) with or without
>   modification, are permitted provided that the following conditions are met:
>
>@@ -156,10 +156,13 @@ that will be loaded from the shell or stored in a PCI
>option ROM) will not have
> an FFS DEPEX section generated by the tools.
> **********
> **Note:** Capitalization in the Prototypes listed below does not match the
> capitalization used in the PI Specification.
> **********
>+**Note:** The PCD item used in this section must be defined as
>FixedAtBuild type
>+and VOID* datum type, and the size of the PCD must be 16 bytes.
>+**********
>
> #### Prototype
>
> ```c
> <Depex>              ::= "[Depex" [<com_attribs>] "]" <EOL>
>@@ -171,37 +174,38 @@ capitalization used in the PI Specification.
> <DepexModuleType>    ::= {"PEIM"} {"DXE_DRIVER"} {"DXE_SMM_DRIVER"}
>                          {"DXE_RUNTIME_DRIVER"} {"DXE_SAL_DRIVER"}
>                          {"UEFI_DRIVER"} {"USER_DEFINED"}
> <DepexSection>       ::= {<PeiDepex>} {<SmmDepex>} {<DxeDepex>}
> <DxeDepex>           ::= <DxeDepexStatements>+ ["END" <EOL>]
>-<DxeDepexStatements> ::= {<SorStmt>} {<GuidStmt>} {<BoolStmt>}
>+<DxeDepexStatements> ::= {<SorStmt>} {<GuidOrPcdStmt>} {<BoolStmt>}
> <PeiDepex>           ::= <PeiDepexStatements>*
>                          ["END" <EOL>]
> <PeiDepexStatements> ::= {<BoolStmt>} {<DepInstruct>}
> <SmmDepex>           ::= <DxeDepex>
>-<GuidStmt>           ::= {"BEFORE"} {"AFTER"} <GuidCName> [<EOL>]
>+<GuidOrPcdStmt>      ::= {"BEFORE"} {"AFTER"} <GuidOrPcdName> [<EOL>]
>+<GuidOrPcdName>      ::= {<GuidCName>} {<PcdName>}
> <DepInstruct>        ::= "PUSH" <CFormatGUID> [<EOL>]
> <SorStmt>            ::= "SOR" <BoolStmt> [<EOL>]
> <BoolStmt>           ::= {<Bool>} {<BoolExpress>}
>-<Bool>               ::= {"TRUE"} {"FALSE"} {<GuidCName>} [<EOL>]
>+<Bool>               ::= {"TRUE"} {"FALSE"} {<GuidCName>} {<PcdName>} [<EOL>]
> <GuidCName>          ::= <CName> # A Guid C Name
> <NTs>                ::= "NOT" <TS>
> <BoolExpress>        ::= <NTs> <Bool> [<BoolExpressCont>]*
> <BoolExpressCont>    ::= <MTS> {"AND"} {"OR"} <MTS> [<NTs>] <Bool>
> <AsBuiltDepex>       ::= "#" {<FullDxe>} {<FullPei>} {<FullSmm>} <EOL>
> <FullDxe>            ::= <DxeStatements>+
>                          [<TS> "END"]
>-<DxeStatements>      ::= {<SorAbStmt>} {<GuidAbStmt>} {<BoolAbStmt>}
>+<DxeStatements>      ::= {<SorAbStmt>} {<GuidOrPcdAbStmt>}
>{<BoolAbStmt>}
> <FullPei>            ::= <PeiStatements>*
>                          [<TS> "END"]
> <PeiStatements>      ::= {<BoolAbStmt>} {<DepAbInstruct>}
> <FullSmm>            ::= <FullDxe>
>-<GuidAbStmt>         ::= {"BEFORE"} {"AFTER"} <TS> <GuidCName> <TS>
>+<GuidOrPcdAbStmt>    ::= {"BEFORE"} {"AFTER"} <TS> <GuidOrPcdName>
><TS>
> <DepAbInstruct>      ::= "PUSH" <TS> <CFormatGUID> <TS>
> <SorAbStmt>          ::= "SOR" <TS> <BoolAbStmt> <TS>
> <BoolAbStmt>         ::= {<BoolAb>} {<BoolAbExpress>}
>-<BoolAb>             ::= {"TRUE"} {"FALSE"} {<GuidCName>} <TS>
>+<BoolAb>             ::= {"TRUE"} {"FALSE"} {<GuidCName>} {<PcdName>} <TS>
> <GuidCName>          ::= <CName> # A Guid C Name
> <BoolAbExpress>      ::= <NTs> <Bool> [<BoolAbExpressCont>]*
> <BoolAbExpressCont>  ::= <MTS> {"AND"} {"OR"} <MTS> [<NTs>] <Bool>
> ```
>
>@@ -212,11 +216,11 @@ capitalization used in the PI Specification.
>   gEfiFirmwareVolumeBlockProtocolGuid
>   AND gEfiAlternateFvBlockGuid
>   AND gEfiFaultTolerantWriteLiteProtocolGuid
>
> [Depex]
>-  SOR gEfiProtocolIDependOnGuid
>+  gEfiNt32PkgTokenSpaceGuid.PcdGuidTest
>
> [Depex.common]
>   SOR gEfiProtocolIDependOnGuid
>
> [Depex.IA32.DXE_SMM_DRIVER]
>--
>2.6.1.windows.1
>
>_______________________________________________
>edk2-devel mailing list
>edk2-devel@lists.01.org
>https://lists.01.org/mailman/listinfo/edk2-devel
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel