public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification ***
@ 2017-06-26 16:47 Supreeth Venkatesh
  2017-06-26 16:47 ` [PATCH v5 01/10] BaseTools/GenFfs: add FFS file types for MM modules Supreeth Venkatesh
                   ` (11 more replies)
  0 siblings, 12 replies; 15+ messages in thread
From: Supreeth Venkatesh @ 2017-06-26 16:47 UTC (permalink / raw)
  To: edk2-devel
  Cc: leif.lindholm, michael.d.kinney, liming.gao, achin.gupta,
	supreeth.venkatesh, felixp, jbrasen, jonathan.zhang

*** 
PI v1.5 Specification Volume 4 defines Management Mode Core Interface.
In order to support Management Mode Core Interface, Module Types MM_STANDALONE, MM_CORE_STANDALONE are needed. 
PI specification v1.5 defines the following new file types:
#define EFI_FV_FILETYPE_MM_STANDALONE 0x0E
#define EFI_FV_FILETYPE_MM_CORE_STANDALONE 0x0F
The following changes are necessitated in order to support the above changes to the specification. 

Changes Since v4:
(*) Update Review Comment from Laszlo.
(*) Reword Commit subject for the patches in the set to 
convey meaningful summary. 

Changes Since v3:
(*) Update Review Comments from Liming, Felix.
(*) Directly define FV file types MM_STANDALONE / MM_CORE_STANDALONE
and module types MM_STANDALONE / MM_CORE_STANDALONE
i.e., with MM prefix instead of SMM prefix.

Changes Since v2:
Add missing EFI_FV_FILETYPE_MM_CORE_STANDALONE defined in PI Specification v1.5 VOL3, 
but not defined in VOL4.

Changes Since v1:
Corrected Version check HEX Value "0x00010032" (1 and 50), not 0x0001000A (1 and 10)
***

Supreeth Venkatesh (10):
  BaseTools/GenFfs: add FFS file types for MM modules.
  BaseTools/GenFw: recognize MM file types as EFI Boot Service Drivers.
  BaseTools/AutoGen: auto generate MM template APIs and dependencies.
  BaseTools/Common: add MM Module data types.
  BaseTools/Common: add support in FDF Parser to parse MM Modules.
  BaseTools/CommonDataClass: register MM Modules.
  BaseTools/GenFds: register MM Modules and MM FV file types.
  BaseTools/build: register MM module types with build tools.
  BaseTools/Workspace: check MM module type compatibility with PI
    version.
  BaseTools/Eot: register MM Module types with FFS class.

 BaseTools/Source/C/GenFfs/GenFfs.c                 |   8 +-
 BaseTools/Source/C/GenFw/GenFw.c                   |   5 +-
 BaseTools/Source/C/Include/Common/PiFirmwareFile.h |   2 +
 BaseTools/Source/Python/AutoGen/GenC.py            | 148 ++++++++++++++++++++-
 BaseTools/Source/Python/AutoGen/GenDepex.py        |  17 ++-
 BaseTools/Source/Python/Common/DataType.py         |   4 +-
 BaseTools/Source/Python/Common/FdfParserLite.py    |   4 +-
 .../Source/Python/CommonDataClass/CommonClass.py   |   6 +-
 .../Source/Python/CommonDataClass/PackageClass.py  |   2 +-
 BaseTools/Source/Python/Eot/FvImage.py             |   2 +
 BaseTools/Source/Python/GenFds/FdfParser.py        |   4 +-
 BaseTools/Source/Python/GenFds/Ffs.py              |   8 +-
 BaseTools/Source/Python/GenFds/FfsInfStatement.py  |   3 +
 .../Source/Python/Workspace/WorkspaceDatabase.py   |   5 +
 BaseTools/Source/Python/build/BuildReport.py       |   4 +-
 BaseTools/Source/Python/build/build.py             |   2 +-
 16 files changed, 205 insertions(+), 19 deletions(-)

-- 
2.7.4



^ permalink raw reply	[flat|nested] 15+ messages in thread

* [PATCH v5 01/10] BaseTools/GenFfs: add FFS file types for MM modules.
  2017-06-26 16:47 [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification *** Supreeth Venkatesh
@ 2017-06-26 16:47 ` Supreeth Venkatesh
  2017-06-29  8:52   ` Gao, Liming
  2017-06-26 16:47 ` [PATCH v5 02/10] BaseTools/GenFw: recognize MM file types as EFI Boot Service Drivers Supreeth Venkatesh
                   ` (10 subsequent siblings)
  11 siblings, 1 reply; 15+ messages in thread
From: Supreeth Venkatesh @ 2017-06-26 16:47 UTC (permalink / raw)
  To: edk2-devel
  Cc: leif.lindholm, michael.d.kinney, liming.gao, achin.gupta,
	supreeth.venkatesh, felixp, jbrasen, jonathan.zhang, Jiewen Yao

PI specification v1.5 defines new firmware volume file types
for Management Mode (MM).

This patch adds the new file type EFI_FV_FILETYPE_MM_STANDALONE and
EFI_FV_FILETYPE_MM_CORE_STANDALONE in GenFfs tool.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jiewen Yao <jiewen.yao@intel.com>
Signed-off-by: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
---
 BaseTools/Source/C/GenFfs/GenFfs.c                 | 8 ++++++--
 BaseTools/Source/C/Include/Common/PiFirmwareFile.h | 2 ++
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/BaseTools/Source/C/GenFfs/GenFfs.c b/BaseTools/Source/C/GenFfs/GenFfs.c
index c5d657b..91632a9 100644
--- a/BaseTools/Source/C/GenFfs/GenFfs.c
+++ b/BaseTools/Source/C/GenFfs/GenFfs.c
@@ -43,8 +43,10 @@ STATIC CHAR8 *mFfsFileType[] = {
   "EFI_FV_FILETYPE_SMM",                  // 0x0A
   "EFI_FV_FILETYPE_FIRMWARE_VOLUME_IMAGE",// 0x0B
   "EFI_FV_FILETYPE_COMBINED_SMM_DXE",     // 0x0C
-  "EFI_FV_FILETYPE_SMM_CORE"              // 0x0D
- };
+  "EFI_FV_FILETYPE_SMM_CORE",             // 0x0D
+  "EFI_FV_FILETYPE_MM_STANDALONE",        // 0x0E
+  "EFI_FV_FILETYPE_MM_CORE_STANDALONE"    // 0x0F
+};
 
 STATIC CHAR8 *mAlignName[] = {
   "1", "2", "4", "8", "16", "32", "64", "128", "256", "512",
@@ -130,6 +132,8 @@ Returns:
                         EFI_FV_FILETYPE_DRIVER, EFI_FV_FILETYPE_APPLICATION,\n\
                         EFI_FV_FILETYPE_COMBINED_PEIM_DRIVER,\n\
                         EFI_FV_FILETYPE_SMM, EFI_FV_FILETYPE_SMM_CORE,\n\
+                        EFI_FV_FILETYPE_MM_STANDALONE,\n\
+                        EFI_FV_FILETYPE_MM_CORE_STANDALONE,\n\
                         EFI_FV_FILETYPE_COMBINED_SMM_DXE, \n\
                         EFI_FV_FILETYPE_FIRMWARE_VOLUME_IMAGE.\n");
   fprintf (stdout, "  -g FileGuid, --fileguid FileGuid\n\
diff --git a/BaseTools/Source/C/Include/Common/PiFirmwareFile.h b/BaseTools/Source/C/Include/Common/PiFirmwareFile.h
index 2984860..8c54021 100644
--- a/BaseTools/Source/C/Include/Common/PiFirmwareFile.h
+++ b/BaseTools/Source/C/Include/Common/PiFirmwareFile.h
@@ -52,6 +52,8 @@ typedef UINT8 EFI_FFS_FILE_STATE;
 #define EFI_FV_FILETYPE_FIRMWARE_VOLUME_IMAGE 0x0B
 #define EFI_FV_FILETYPE_COMBINED_SMM_DXE      0x0C
 #define EFI_FV_FILETYPE_SMM_CORE              0x0D
+#define EFI_FV_FILETYPE_MM_STANDALONE         0x0E
+#define EFI_FV_FILETYPE_MM_CORE_STANDALONE    0x0F
 #define EFI_FV_FILETYPE_OEM_MIN               0xc0
 #define EFI_FV_FILETYPE_OEM_MAX               0xdf
 #define EFI_FV_FILETYPE_DEBUG_MIN             0xe0
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH v5 02/10] BaseTools/GenFw: recognize MM file types as EFI Boot Service Drivers.
  2017-06-26 16:47 [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification *** Supreeth Venkatesh
  2017-06-26 16:47 ` [PATCH v5 01/10] BaseTools/GenFfs: add FFS file types for MM modules Supreeth Venkatesh
@ 2017-06-26 16:47 ` Supreeth Venkatesh
  2017-06-26 16:47 ` [PATCH v5 03/10] BaseTools/AutoGen: auto generate MM template APIs and dependencies Supreeth Venkatesh
                   ` (9 subsequent siblings)
  11 siblings, 0 replies; 15+ messages in thread
From: Supreeth Venkatesh @ 2017-06-26 16:47 UTC (permalink / raw)
  To: edk2-devel
  Cc: leif.lindholm, michael.d.kinney, liming.gao, achin.gupta,
	supreeth.venkatesh, felixp, jbrasen, jonathan.zhang, Jiewen Yao

PI v1.5 Specification Volume 4 defines Management Mode Core Interface.
In order to support Management Mode Core Interface, Module Types
MM_STANDALONE, MM_CORE_STANDALONE are needed.
This patch ensures that MM_STANDALONE, MM_CORE_STANDALONE Modules are
treated as EFI Boot Service Driver in GenFw tool.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jiewen Yao <jiewen.yao@intel.com>
Signed-off-by: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
---
 BaseTools/Source/C/GenFw/GenFw.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/BaseTools/Source/C/GenFw/GenFw.c b/BaseTools/Source/C/GenFw/GenFw.c
index 22e4e72..dbf16e8 100644
--- a/BaseTools/Source/C/GenFw/GenFw.c
+++ b/BaseTools/Source/C/GenFw/GenFw.c
@@ -181,6 +181,7 @@ Returns:
                         PEI_CORE, PEIM, DXE_CORE, DXE_DRIVER, UEFI_APPLICATION,\n\
                         SEC, DXE_SAL_DRIVER, UEFI_DRIVER, DXE_RUNTIME_DRIVER,\n\
                         DXE_SMM_DRIVER, SECURITY_CORE, COMBINED_PEIM_DRIVER,\n\
+                        MM_STANDALONE, MM_CORE_STANDALONE,\n\
                         PIC_PEIM, RELOCATABLE_PEIM, BS_DRIVER, RT_DRIVER,\n\
                         APPLICATION, SAL_RT_DRIVER to support all module types\n\
                         It can only be used together with --keepexceptiontable,\n\
@@ -2009,7 +2010,9 @@ Returns:
         stricmp (ModuleType, "DXE_DRIVER") == 0 ||
         stricmp (ModuleType, "DXE_SMM_DRIVER") == 0  ||
         stricmp (ModuleType, "UEFI_DRIVER") == 0 ||
-        stricmp (ModuleType, "SMM_CORE") == 0) {
+        stricmp (ModuleType, "SMM_CORE") == 0 ||
+        stricmp (ModuleType, "MM_STANDALONE") == 0 ||
+        stricmp (ModuleType, "MM_CORE_STANDALONE") == 0) {
           Type = EFI_IMAGE_SUBSYSTEM_EFI_BOOT_SERVICE_DRIVER;
           VerboseMsg ("Efi Image subsystem type is efi boot service driver.");
 
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH v5 03/10] BaseTools/AutoGen: auto generate MM template APIs and dependencies.
  2017-06-26 16:47 [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification *** Supreeth Venkatesh
  2017-06-26 16:47 ` [PATCH v5 01/10] BaseTools/GenFfs: add FFS file types for MM modules Supreeth Venkatesh
  2017-06-26 16:47 ` [PATCH v5 02/10] BaseTools/GenFw: recognize MM file types as EFI Boot Service Drivers Supreeth Venkatesh
@ 2017-06-26 16:47 ` Supreeth Venkatesh
  2017-06-26 16:47 ` [PATCH v5 04/10] BaseTools/Common: add MM Module data types Supreeth Venkatesh
                   ` (8 subsequent siblings)
  11 siblings, 0 replies; 15+ messages in thread
From: Supreeth Venkatesh @ 2017-06-26 16:47 UTC (permalink / raw)
  To: edk2-devel
  Cc: leif.lindholm, michael.d.kinney, liming.gao, achin.gupta,
	supreeth.venkatesh, felixp, jbrasen, jonathan.zhang, Jiewen Yao

This patch adds changes to auto generate MM_CORE_STANDALONE and
MM_STANDALONE Entry Point templates.
Also, it adds changes to help auto generate dependency expressions for
MM_STANDALONE modules.

PI Specification v1.5 specifies Management Mode System Table (MMST)
which is  a collection of common services for managing
MMRAM allocation and providing basic I/O services. MMST is similar to
the UEFI System Table. (Currently, EFI_SMM_SYSTEM_TABLE2 defines
Management Mode System Table)

Some of auto generated MM_CORE_STANDALONE and MM_STANDALONE template
APIs use MMST as parameter.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jiewen Yao <jiewen.yao@intel.com>
Signed-off-by: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
---
 BaseTools/Source/Python/AutoGen/GenC.py     | 148 +++++++++++++++++++++++++++-
 BaseTools/Source/Python/AutoGen/GenDepex.py |  17 +++-
 2 files changed, 162 insertions(+), 3 deletions(-)

diff --git a/BaseTools/Source/Python/AutoGen/GenC.py b/BaseTools/Source/Python/AutoGen/GenC.py
index 67aaef7..7aa2016 100644
--- a/BaseTools/Source/Python/AutoGen/GenC.py
+++ b/BaseTools/Source/Python/AutoGen/GenC.py
@@ -237,6 +237,100 @@ ProcessModuleEntryPointList (
 ${END}
 """)
 
+## MM_CORE_STANDALONE Entry Point Templates
+gMmCoreStandaloneEntryPointPrototype = TemplateString("""
+${BEGIN}
+EFI_STATUS
+EFIAPI
+${Function} (
+  IN VOID *HobStart
+  );
+${END}
+""")
+
+gMmCoreStandaloneEntryPointString = TemplateString("""
+${BEGIN}
+const UINT32 _gMmRevision = ${PiSpecVersion};
+
+VOID
+EFIAPI
+ProcessModuleEntryPointList (
+  IN VOID *HobStart
+  )
+{
+  ${Function} (HobStart);
+}
+${END}
+""")
+
+## MM_STANDALONE Entry Point Templates
+gMmStandaloneEntryPointPrototype = TemplateString("""
+${BEGIN}
+EFI_STATUS
+EFIAPI
+${Function} (
+  IN EFI_HANDLE            ImageHandle,
+  IN EFI_SMM_SYSTEM_TABLE2 *MmSystemTable
+  );
+${END}
+""")
+
+gMmStandaloneEntryPointString = [
+TemplateString("""
+GLOBAL_REMOVE_IF_UNREFERENCED const UINT32 _gMmRevision = ${PiSpecVersion};
+
+EFI_STATUS
+EFIAPI
+ProcessModuleEntryPointList (
+  IN EFI_HANDLE            ImageHandle,
+  IN EFI_SMM_SYSTEM_TABLE2 *MmSystemTable
+  )
+
+{
+  return EFI_SUCCESS;
+}
+"""),
+TemplateString("""
+GLOBAL_REMOVE_IF_UNREFERENCED const UINT32 _gMmRevision = ${PiSpecVersion};
+${BEGIN}
+EFI_STATUS
+EFIAPI
+ProcessModuleEntryPointList (
+  IN EFI_HANDLE            ImageHandle,
+  IN EFI_SMM_SYSTEM_TABLE2 *MmSystemTable
+  )
+
+{
+  return ${Function} (ImageHandle, MmSystemTable);
+}
+${END}
+"""),
+TemplateString("""
+GLOBAL_REMOVE_IF_UNREFERENCED const UINT32 _gMmRevision = ${PiSpecVersion};
+
+EFI_STATUS
+EFIAPI
+ProcessModuleEntryPointList (
+  IN EFI_HANDLE            ImageHandle,
+  IN EFI_SMM_SYSTEM_TABLE2 *MmSystemTable
+  )
+
+{
+  EFI_STATUS  Status;
+  EFI_STATUS  CombinedStatus;
+
+  CombinedStatus = EFI_LOAD_ERROR;
+${BEGIN}
+  Status = ${Function} (ImageHandle, MmSystemTable);
+  if (!EFI_ERROR (Status) || EFI_ERROR (CombinedStatus)) {
+    CombinedStatus = Status;
+  }
+${END}
+  return CombinedStatus;
+}
+""")
+]
+
 ## DXE SMM Entry Point Templates
 gDxeSmmEntryPointPrototype = TemplateString("""
 ${BEGIN}
@@ -580,6 +674,15 @@ ${Function} (
   IN EFI_SYSTEM_TABLE  *SystemTable
   );${END}
 """),
+
+'MM'   : TemplateString("""${BEGIN}
+EFI_STATUS
+EFIAPI
+${Function} (
+  IN EFI_HANDLE            ImageHandle,
+  IN EFI_SMM_SYSTEM_TABLE2  *MmSystemTable
+  );${END}
+"""),
 }
 
 gLibraryStructorCall = {
@@ -597,6 +700,11 @@ gLibraryStructorCall = {
   Status = ${Function} (ImageHandle, SystemTable);
   ASSERT_EFI_ERROR (Status);${END}
 """),
+
+'MM'   : TemplateString("""${BEGIN}
+  Status = ${Function} (ImageHandle, MmSystemTable);
+  ASSERT_EFI_ERROR (Status);${END}
+"""),
 }
 
 ## Library Constructor and Destructor Templates
@@ -644,6 +752,21 @@ ${BEGIN}  EFI_STATUS  Status;
 ${FunctionCall}${END}
 }
 """),
+
+'MM'   :   TemplateString("""
+${BEGIN}${FunctionPrototype}${END}
+
+VOID
+EFIAPI
+ProcessLibrary${Type}List (
+  IN EFI_HANDLE            ImageHandle,
+  IN EFI_SMM_SYSTEM_TABLE2  *MmSystemTable
+  )
+{
+${BEGIN}  EFI_STATUS  Status;
+${FunctionCall}${END}
+}
+"""),
 }
 
 gBasicHeaderFile = "Base.h"
@@ -661,6 +784,8 @@ gModuleTypeHeaderFile = {
     "UEFI_DRIVER"       :   ["Uefi.h",  "Library/BaseLib.h", "Library/DebugLib.h", "Library/UefiBootServicesTableLib.h", "Library/UefiDriverEntryPoint.h"],
     "UEFI_APPLICATION"  :   ["Uefi.h",  "Library/BaseLib.h", "Library/DebugLib.h", "Library/UefiBootServicesTableLib.h", "Library/UefiApplicationEntryPoint.h"],
     "SMM_CORE"          :   ["PiDxe.h", "Library/BaseLib.h", "Library/DebugLib.h", "Library/UefiDriverEntryPoint.h"],
+    "MM_STANDALONE"     :   ["PiSmm.h", "Library/BaseLib.h", "Library/DebugLib.h", "Library/SmmDriverStandaloneEntryPoint.h"],
+    "MM_CORE_STANDALONE" :  ["PiSmm.h", "Library/BaseLib.h", "Library/DebugLib.h", "Library/SmmCoreStandaloneEntryPoint.h"],
     "USER_DEFINED"      :   [gBasicHeaderFile]
 }
 
@@ -1266,6 +1391,9 @@ def CreateLibraryConstructorCode(Info, AutoGenC, AutoGenH):
                                 'DXE_SAL_DRIVER','UEFI_DRIVER','UEFI_APPLICATION','SMM_CORE']:
             ConstructorPrototypeString.Append(gLibraryStructorPrototype['DXE'].Replace(Dict))
             ConstructorCallingString.Append(gLibraryStructorCall['DXE'].Replace(Dict))
+        elif Lib.ModuleType in ['MM_STANDALONE','MM_CORE_STANDALONE']:
+            ConstructorPrototypeString.Append(gLibraryStructorPrototype['MM'].Replace(Dict))
+            ConstructorCallingString.Append(gLibraryStructorCall['MM'].Replace(Dict))
 
     if str(ConstructorPrototypeString) == '':
         ConstructorPrototypeList = []
@@ -1291,6 +1419,8 @@ def CreateLibraryConstructorCode(Info, AutoGenC, AutoGenH):
         elif Info.ModuleType in ['DXE_CORE','DXE_DRIVER','DXE_SMM_DRIVER','DXE_RUNTIME_DRIVER',
                                  'DXE_SAL_DRIVER','UEFI_DRIVER','UEFI_APPLICATION','SMM_CORE']:
             AutoGenC.Append(gLibraryString['DXE'].Replace(Dict))
+        elif Info.ModuleType in ['MM_STANDALONE','MM_CORE_STANDALONE']:
+            AutoGenC.Append(gLibraryString['MM'].Replace(Dict))
 
 ## Create code for library destructor
 #
@@ -1323,6 +1453,9 @@ def CreateLibraryDestructorCode(Info, AutoGenC, AutoGenH):
                                 'DXE_SAL_DRIVER','UEFI_DRIVER','UEFI_APPLICATION', 'SMM_CORE']:
             DestructorPrototypeString.Append(gLibraryStructorPrototype['DXE'].Replace(Dict))
             DestructorCallingString.Append(gLibraryStructorCall['DXE'].Replace(Dict))
+        elif Lib.ModuleType in ['MM_STANDALONE','MM_CORE_STANDALONE']:
+            DestructorPrototypeString.Append(gLibraryStructorPrototype['MM'].Replace(Dict))
+            DestructorCallingString.Append(gLibraryStructorCall['MM'].Replace(Dict))
 
     if str(DestructorPrototypeString) == '':
         DestructorPrototypeList = []
@@ -1348,6 +1481,8 @@ def CreateLibraryDestructorCode(Info, AutoGenC, AutoGenH):
         elif Info.ModuleType in ['DXE_CORE','DXE_DRIVER','DXE_SMM_DRIVER','DXE_RUNTIME_DRIVER',
                                  'DXE_SAL_DRIVER','UEFI_DRIVER','UEFI_APPLICATION','SMM_CORE']:
             AutoGenC.Append(gLibraryString['DXE'].Replace(Dict))
+        elif Info.ModuleType in ['MM_STANDALONE','MM_CORE_STANDALONE']:
+            AutoGenC.Append(gLibraryString['MM'].Replace(Dict))
 
 
 ## Create code for ModuleEntryPoint
@@ -1377,7 +1512,7 @@ def CreateModuleEntryPointCode(Info, AutoGenC, AutoGenH):
         'UefiSpecVersion':   UefiSpecVersion + 'U'
     }
 
-    if Info.ModuleType in ['PEI_CORE', 'DXE_CORE', 'SMM_CORE']:
+    if Info.ModuleType in ['PEI_CORE', 'DXE_CORE', 'SMM_CORE', 'MM_CORE_STANDALONE']:
         if Info.SourceFileList <> None and Info.SourceFileList <> []:
           if NumEntryPoints != 1:
               EdkLogger.error(
@@ -1396,6 +1531,9 @@ def CreateModuleEntryPointCode(Info, AutoGenC, AutoGenH):
     elif Info.ModuleType == 'SMM_CORE':
         AutoGenC.Append(gSmmCoreEntryPointString.Replace(Dict))
         AutoGenH.Append(gSmmCoreEntryPointPrototype.Replace(Dict))
+    elif Info.ModuleType == 'MM_CORE_STANDALONE':
+        AutoGenC.Append(gMmCoreStandaloneEntryPointString.Replace(Dict))
+        AutoGenH.Append(gMmCoreStandaloneEntryPointPrototype.Replace(Dict))
     elif Info.ModuleType == 'PEIM':
         if NumEntryPoints < 2:
             AutoGenC.Append(gPeimEntryPointString[NumEntryPoints].Replace(Dict))
@@ -1413,7 +1551,13 @@ def CreateModuleEntryPointCode(Info, AutoGenC, AutoGenH):
             AutoGenC.Append(gDxeSmmEntryPointString[0].Replace(Dict))
         else:
             AutoGenC.Append(gDxeSmmEntryPointString[1].Replace(Dict))
-        AutoGenH.Append(gDxeSmmEntryPointPrototype.Replace(Dict))    
+        AutoGenH.Append(gDxeSmmEntryPointPrototype.Replace(Dict))
+    elif Info.ModuleType == 'MM_STANDALONE':
+        if NumEntryPoints < 2:
+            AutoGenC.Append(gMmStandaloneEntryPointString[NumEntryPoints].Replace(Dict))
+        else:
+            AutoGenC.Append(gMmStandaloneEntryPointString[2].Replace(Dict))
+        AutoGenH.Append(gMmStandaloneEntryPointPrototype.Replace(Dict))
     elif Info.ModuleType == 'UEFI_APPLICATION':
         if NumEntryPoints < 2:
             AutoGenC.Append(gUefiApplicationEntryPointString[NumEntryPoints].Replace(Dict))
diff --git a/BaseTools/Source/Python/AutoGen/GenDepex.py b/BaseTools/Source/Python/AutoGen/GenDepex.py
index 5923a75..7aa22bd 100644
--- a/BaseTools/Source/Python/AutoGen/GenDepex.py
+++ b/BaseTools/Source/Python/AutoGen/GenDepex.py
@@ -42,6 +42,8 @@ gType2Phase = {
     "UEFI_DRIVER"       :   "DXE",
     "UEFI_APPLICATION"  :   "DXE",
     "SMM_CORE"          :   "DXE",
+    "MM_STANDALONE"     :   "MM",
+    "MM_CORE_STANDALONE" :  "MM",
 }
 
 ## Convert dependency expression string into EFI internal representation
@@ -98,6 +100,19 @@ class DependencyExpression:
             "FALSE" :   0x07,
             "END"   :   0x08,
             "SOR"   :   0x09
+        },
+
+        "MM"   : {
+            "BEFORE":   0x00,
+            "AFTER" :   0x01,
+            "PUSH"  :   0x02,
+            "AND"   :   0x03,
+            "OR"    :   0x04,
+            "NOT"   :   0x05,
+            "TRUE"  :   0x06,
+            "FALSE" :   0x07,
+            "END"   :   0x08,
+            "SOR"   :   0x09
         }
     }
 
@@ -289,7 +304,7 @@ class DependencyExpression:
             return
 
         # don't generate depex if all operands are architecture protocols
-        if self.ModuleType in ['UEFI_DRIVER', 'DXE_DRIVER', 'DXE_RUNTIME_DRIVER', 'DXE_SAL_DRIVER', 'DXE_SMM_DRIVER'] and \
+        if self.ModuleType in ['UEFI_DRIVER', 'DXE_DRIVER', 'DXE_RUNTIME_DRIVER', 'DXE_SAL_DRIVER', 'DXE_SMM_DRIVER', 'MM_STANDALONE'] and \
            Op == 'AND' and \
            self.ArchProtocols == set([GuidStructureStringToGuidString(Guid) for Guid in AllOperand]):
             self.PostfixNotation = []
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH v5 04/10] BaseTools/Common: add MM Module data types.
  2017-06-26 16:47 [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification *** Supreeth Venkatesh
                   ` (2 preceding siblings ...)
  2017-06-26 16:47 ` [PATCH v5 03/10] BaseTools/AutoGen: auto generate MM template APIs and dependencies Supreeth Venkatesh
@ 2017-06-26 16:47 ` Supreeth Venkatesh
  2017-06-26 16:47 ` [PATCH v5 05/10] BaseTools/Common: add support in FDF Parser to parse MM Modules Supreeth Venkatesh
                   ` (7 subsequent siblings)
  11 siblings, 0 replies; 15+ messages in thread
From: Supreeth Venkatesh @ 2017-06-26 16:47 UTC (permalink / raw)
  To: edk2-devel
  Cc: leif.lindholm, michael.d.kinney, liming.gao, achin.gupta,
	supreeth.venkatesh, felixp, jbrasen, jonathan.zhang, Jiewen Yao

This patch adds SUP_MODULE_MM_STANDALONE and
SUP_MODULE_MM_CORE_STANDALONE data types and includes it in
SUP_MODULE_LIST.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jiewen Yao <jiewen.yao@intel.com>
Signed-off-by: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
---
 BaseTools/Source/Python/Common/DataType.py | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/BaseTools/Source/Python/Common/DataType.py b/BaseTools/Source/Python/Common/DataType.py
index 6edc0c0..ce8c50c 100644
--- a/BaseTools/Source/Python/Common/DataType.py
+++ b/BaseTools/Source/Python/Common/DataType.py
@@ -70,10 +70,12 @@ SUP_MODULE_UEFI_DRIVER = 'UEFI_DRIVER'
 SUP_MODULE_UEFI_APPLICATION = 'UEFI_APPLICATION'
 SUP_MODULE_USER_DEFINED = 'USER_DEFINED'
 SUP_MODULE_SMM_CORE = 'SMM_CORE'
+SUP_MODULE_MM_STANDALONE = 'MM_STANDALONE'
+SUP_MODULE_MM_CORE_STANDALONE = 'MM_CORE_STANDALONE'
 
 SUP_MODULE_LIST = [SUP_MODULE_BASE, SUP_MODULE_SEC, SUP_MODULE_PEI_CORE, SUP_MODULE_PEIM, SUP_MODULE_DXE_CORE, SUP_MODULE_DXE_DRIVER, \
                    SUP_MODULE_DXE_RUNTIME_DRIVER, SUP_MODULE_DXE_SAL_DRIVER, SUP_MODULE_DXE_SMM_DRIVER, SUP_MODULE_UEFI_DRIVER, \
-                   SUP_MODULE_UEFI_APPLICATION, SUP_MODULE_USER_DEFINED, SUP_MODULE_SMM_CORE]
+                   SUP_MODULE_UEFI_APPLICATION, SUP_MODULE_USER_DEFINED, SUP_MODULE_SMM_CORE, SUP_MODULE_MM_STANDALONE, SUP_MODULE_MM_CORE_STANDALONE]
 SUP_MODULE_LIST_STRING = TAB_VALUE_SPLIT.join(l for l in SUP_MODULE_LIST)
 
 EDK_COMPONENT_TYPE_LIBRARY = 'LIBRARY'
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH v5 05/10] BaseTools/Common: add support in FDF Parser to parse MM Modules.
  2017-06-26 16:47 [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification *** Supreeth Venkatesh
                   ` (3 preceding siblings ...)
  2017-06-26 16:47 ` [PATCH v5 04/10] BaseTools/Common: add MM Module data types Supreeth Venkatesh
@ 2017-06-26 16:47 ` Supreeth Venkatesh
  2017-06-26 16:47 ` [PATCH v5 06/10] BaseTools/CommonDataClass: register " Supreeth Venkatesh
                   ` (6 subsequent siblings)
  11 siblings, 0 replies; 15+ messages in thread
From: Supreeth Venkatesh @ 2017-06-26 16:47 UTC (permalink / raw)
  To: edk2-devel
  Cc: leif.lindholm, michael.d.kinney, liming.gao, achin.gupta,
	supreeth.venkatesh, felixp, jbrasen, jonathan.zhang, Jiewen Yao

This patch adds support for FdfParser tool to parse MM_STANDALONE and
MM_CORE_STANDALONE modules.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jiewen Yao <jiewen.yao@intel.com>
Signed-off-by: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
---
 BaseTools/Source/Python/Common/FdfParserLite.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/BaseTools/Source/Python/Common/FdfParserLite.py b/BaseTools/Source/Python/Common/FdfParserLite.py
index a8cce26..8e68a67 100644
--- a/BaseTools/Source/Python/Common/FdfParserLite.py
+++ b/BaseTools/Source/Python/Common/FdfParserLite.py
@@ -2823,7 +2823,7 @@ class FdfParser(object):
                              "DXE_SMM_DRIVER", "DXE_RUNTIME_DRIVER", \
                              "UEFI_DRIVER", "UEFI_APPLICATION", "USER_DEFINED", "DEFAULT", "BASE", \
                              "SECURITY_CORE", "COMBINED_PEIM_DRIVER", "PIC_PEIM", "RELOCATABLE_PEIM", \
-                             "PE32_PEIM", "BS_DRIVER", "RT_DRIVER", "SAL_RT_DRIVER", "APPLICATION", "ACPITABLE", "SMM_CORE"):
+                             "PE32_PEIM", "BS_DRIVER", "RT_DRIVER", "SAL_RT_DRIVER", "APPLICATION", "ACPITABLE", "SMM_CORE", "MM_STANDALONE", "MM_CORE_STANDALONE"):
             raise Warning("Unknown Module type At line ", self.FileName, self.CurrentLineNumber)
         return self.__Token
     
@@ -2867,7 +2867,7 @@ class FdfParser(object):
         
         Type = self.__Token.strip().upper()
         if Type not in ("RAW", "FREEFORM", "SEC", "PEI_CORE", "PEIM",\
-                             "PEI_DXE_COMBO", "DRIVER", "DXE_CORE", "APPLICATION", "FV_IMAGE", "SMM", "SMM_CORE"):
+                             "PEI_DXE_COMBO", "DRIVER", "DXE_CORE", "APPLICATION", "FV_IMAGE", "SMM", "SMM_CORE", "MM_STANDALONE"):
             raise Warning("Unknown FV type At line ", self.FileName, self.CurrentLineNumber)
 
         if not self.__IsToken("="):
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH v5 06/10] BaseTools/CommonDataClass: register MM Modules.
  2017-06-26 16:47 [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification *** Supreeth Venkatesh
                   ` (4 preceding siblings ...)
  2017-06-26 16:47 ` [PATCH v5 05/10] BaseTools/Common: add support in FDF Parser to parse MM Modules Supreeth Venkatesh
@ 2017-06-26 16:47 ` Supreeth Venkatesh
  2017-06-26 16:47 ` [PATCH v5 07/10] BaseTools/GenFds: register MM Modules and MM FV file types Supreeth Venkatesh
                   ` (5 subsequent siblings)
  11 siblings, 0 replies; 15+ messages in thread
From: Supreeth Venkatesh @ 2017-06-26 16:47 UTC (permalink / raw)
  To: edk2-devel
  Cc: leif.lindholm, michael.d.kinney, liming.gao, achin.gupta,
	supreeth.venkatesh, felixp, jbrasen, jonathan.zhang, Jiewen Yao

This patch registers MM_STANDALONE and MM_CORE_STANDALONE module types
with CommonClass and PackageIncludePkgHeaderClass in CommonDataClass.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jiewen Yao <jiewen.yao@intel.com>
Signed-off-by: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
---
 BaseTools/Source/Python/CommonDataClass/CommonClass.py  | 6 +++---
 BaseTools/Source/Python/CommonDataClass/PackageClass.py | 2 +-
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/BaseTools/Source/Python/CommonDataClass/CommonClass.py b/BaseTools/Source/Python/CommonDataClass/CommonClass.py
index 5e908a6..5a924ec 100644
--- a/BaseTools/Source/Python/CommonDataClass/CommonClass.py
+++ b/BaseTools/Source/Python/CommonDataClass/CommonClass.py
@@ -174,7 +174,7 @@ class IncludeStatementClass(object):
 # @var GuidTypeList:   To store value for GuidTypeList, selection scope is in below list
 #                      DATA_HUB_RECORD | EFI_EVENT | EFI_SYSTEM_CONFIGURATION_TABLE | EFI_VARIABLE | GUID | HII_PACKAGE_LIST | HOB | TOKEN_SPACE_GUID
 # @var SupModuleList:  To store value for SupModuleList, selection scope is in below list
-#                      BASE | SEC | PEI_CORE | PEIM | DXE_CORE | DXE_DRIVER | DXE_RUNTIME_DRIVER | DXE_SAL_DRIVER | DXE_SMM_DRIVER | UEFI_DRIVER | UEFI_APPLICATION | USER_DEFINED | SMM_CORE
+#                      BASE | SEC | PEI_CORE | PEIM | DXE_CORE | DXE_DRIVER | DXE_RUNTIME_DRIVER | DXE_SAL_DRIVER | DXE_SMM_DRIVER | UEFI_DRIVER | UEFI_APPLICATION | USER_DEFINED | SMM_CORE | MM_STANDALONE | MM_CORE_STANDALONE
 #
 class GuidProtocolPpiCommonClass(CommonClass):
     def __init__(self):
@@ -202,7 +202,7 @@ class GuidProtocolPpiCommonClass(CommonClass):
 # @var RecommendedInstance:         To store value for RecommendedInstance, selection scope is in below list
 #                                   DATA_HUB_RECORD | EFI_EVENT | EFI_SYSTEM_CONFIGURATION_TABLE | EFI_VARIABLE | GUID | HII_PACKAGE_LIST | HOB | TOKEN_SPACE_GUID
 # @var SupModuleList:               To store value for SupModuleList, selection scope is in below list
-#                                   BASE | SEC | PEI_CORE | PEIM | DXE_CORE | DXE_DRIVER | DXE_RUNTIME_DRIVER | DXE_SAL_DRIVER | DXE_SMM_DRIVER | UEFI_DRIVER | UEFI_APPLICATION | USER_DEFINED | SMM_CORE
+#                                   BASE | SEC | PEI_CORE | PEIM | DXE_CORE | DXE_DRIVER | DXE_RUNTIME_DRIVER | DXE_SAL_DRIVER | DXE_SMM_DRIVER | UEFI_DRIVER | UEFI_APPLICATION | USER_DEFINED | SMM_CORE | MM_STANDALONE | MM_CORE_STANDALONE
 #
 class LibraryClassClass(CommonClass, DefineClass):
     def __init__(self):
@@ -354,7 +354,7 @@ class PcdErrorClass(object):
 # @var SkuInfoList:            To store value for SkuInfoList
 #                              It is a set structure as { [SkuIdName] : SkuInfoClass } 
 # @var SupModuleList:          To store value for SupModuleList, selection scope is in below list
-#                              BASE | SEC | PEI_CORE | PEIM | DXE_CORE | DXE_DRIVER | DXE_RUNTIME_DRIVER | DXE_SAL_DRIVER | DXE_SMM_DRIVER | UEFI_DRIVER | UEFI_APPLICATION | USER_DEFINED | SMM_CORE
+#                              BASE | SEC | PEI_CORE | PEIM | DXE_CORE | DXE_DRIVER | DXE_RUNTIME_DRIVER | DXE_SAL_DRIVER | DXE_SMM_DRIVER | UEFI_DRIVER | UEFI_APPLICATION | USER_DEFINED | SMM_CORE | MM_STANDALONE | MM_CORE_STANDALONE
 #
 class PcdClass(CommonClass):
     def __init__(self, CName = '', Token = '', TokenSpaceGuidCName = '', DatumType = '', MaxDatumSize = '', DefaultValue = '', ItemType = '', ValidUsage = None, SkuInfoList = None, SupModuleList = None):
diff --git a/BaseTools/Source/Python/CommonDataClass/PackageClass.py b/BaseTools/Source/Python/CommonDataClass/PackageClass.py
index 82e7394..89d4d07 100644
--- a/BaseTools/Source/Python/CommonDataClass/PackageClass.py
+++ b/BaseTools/Source/Python/CommonDataClass/PackageClass.py
@@ -62,7 +62,7 @@ class PackageIndustryStdHeaderClass(CommonClass):
 #
 # @var IncludeHeader:  To store value for IncludeHeader
 # @var ModuleType:     To store value for ModuleType, it is a set structure as
-#                      BASE | SEC | PEI_CORE | PEIM | DXE_CORE | DXE_DRIVER | DXE_RUNTIME_DRIVER | DXE_SAL_DRIVER | DXE_SMM_DRIVER | TOOL | UEFI_DRIVER | UEFI_APPLICATION | USER_DEFINED | SMM_CORE
+#                      BASE | SEC | PEI_CORE | PEIM | DXE_CORE | DXE_DRIVER | DXE_RUNTIME_DRIVER | DXE_SAL_DRIVER | DXE_SMM_DRIVER | TOOL | UEFI_DRIVER | UEFI_APPLICATION | USER_DEFINED | SMM_CORE | MM_STANDALONE | MM_CORE_STANDALONE
 #
 class PackageIncludePkgHeaderClass(object):
     def __init__(self):
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH v5 07/10] BaseTools/GenFds: register MM Modules and MM FV file types.
  2017-06-26 16:47 [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification *** Supreeth Venkatesh
                   ` (5 preceding siblings ...)
  2017-06-26 16:47 ` [PATCH v5 06/10] BaseTools/CommonDataClass: register " Supreeth Venkatesh
@ 2017-06-26 16:47 ` Supreeth Venkatesh
  2017-06-26 16:47 ` [PATCH v5 08/10] BaseTools/build: register MM module types with build tools Supreeth Venkatesh
                   ` (4 subsequent siblings)
  11 siblings, 0 replies; 15+ messages in thread
From: Supreeth Venkatesh @ 2017-06-26 16:47 UTC (permalink / raw)
  To: edk2-devel
  Cc: leif.lindholm, michael.d.kinney, liming.gao, achin.gupta,
	supreeth.venkatesh, felixp, jbrasen, jonathan.zhang, Jiewen Yao

This patch verifies MM_CORE_STANDALONE module compatibility with PI
specification version.
Also, it registers MM_STANDALONE/MM_CORE_STANDALONE modules with
FdfParser class and provides mapping between MM_STANDALONE and
MM_CORE_STANDALONE module type in FDF with
EFI_FV_FILETYPE_MM_STANDALONE and EFI_FV_FILETYPE_MM_CORE_STANDALONE file types
in GenFfs.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jiewen Yao <jiewen.yao@intel.com>
Signed-off-by: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
---
 BaseTools/Source/Python/GenFds/FdfParser.py       | 4 ++--
 BaseTools/Source/Python/GenFds/Ffs.py             | 8 ++++++--
 BaseTools/Source/Python/GenFds/FfsInfStatement.py | 3 +++
 3 files changed, 11 insertions(+), 4 deletions(-)

diff --git a/BaseTools/Source/Python/GenFds/FdfParser.py b/BaseTools/Source/Python/GenFds/FdfParser.py
index a1825ba..2782be4 100644
--- a/BaseTools/Source/Python/GenFds/FdfParser.py
+++ b/BaseTools/Source/Python/GenFds/FdfParser.py
@@ -3672,7 +3672,7 @@ class FdfParser:
                              "DXE_SMM_DRIVER", "DXE_RUNTIME_DRIVER", \
                              "UEFI_DRIVER", "UEFI_APPLICATION", "USER_DEFINED", "DEFAULT", "BASE", \
                              "SECURITY_CORE", "COMBINED_PEIM_DRIVER", "PIC_PEIM", "RELOCATABLE_PEIM", \
-                             "PE32_PEIM", "BS_DRIVER", "RT_DRIVER", "SAL_RT_DRIVER", "APPLICATION", "ACPITABLE", "SMM_CORE"):
+                                        "PE32_PEIM", "BS_DRIVER", "RT_DRIVER", "SAL_RT_DRIVER", "APPLICATION", "ACPITABLE", "SMM_CORE", "MM_STANDALONE", "MM_CORE_STANDALONE"):
             raise Warning("Unknown Module type '%s'" % self.__Token, self.FileName, self.CurrentLineNumber)
         return self.__Token
 
@@ -3716,7 +3716,7 @@ class FdfParser:
 
         Type = self.__Token.strip().upper()
         if Type not in ("RAW", "FREEFORM", "SEC", "PEI_CORE", "PEIM",\
-                             "PEI_DXE_COMBO", "DRIVER", "DXE_CORE", "APPLICATION", "FV_IMAGE", "SMM", "SMM_CORE"):
+                             "PEI_DXE_COMBO", "DRIVER", "DXE_CORE", "APPLICATION", "FV_IMAGE", "SMM", "SMM_CORE", "MM_STANDALONE", "MM_CORE_STANDALONE"):
             raise Warning("Unknown FV type '%s'" % self.__Token, self.FileName, self.CurrentLineNumber)
 
         if not self.__IsToken("="):
diff --git a/BaseTools/Source/Python/GenFds/Ffs.py b/BaseTools/Source/Python/GenFds/Ffs.py
index c8c5a6e..a417812 100644
--- a/BaseTools/Source/Python/GenFds/Ffs.py
+++ b/BaseTools/Source/Python/GenFds/Ffs.py
@@ -34,7 +34,9 @@ class Ffs(FDClassObject):
         'DXE_RUNTIME_DRIVER': 'EFI_FV_FILETYPE_DRIVER',
         'UEFI_DRIVER'       : 'EFI_FV_FILETYPE_DRIVER',
         'UEFI_APPLICATION'  : 'EFI_FV_FILETYPE_APPLICATION',
-        'SMM_CORE'          : 'EFI_FV_FILETYPE_SMM_CORE'
+        'SMM_CORE'          : 'EFI_FV_FILETYPE_SMM_CORE',
+        'MM_STANDALONE'     : 'EFI_FV_FILETYPE_MM_STANDALONE',
+        'MM_CORE_STANDALONE' : 'EFI_FV_FILETYPE_MM_CORE_STANDALONE'
     }
     
     # mapping between FILE type in FDF and file type for GenFfs
@@ -50,7 +52,9 @@ class Ffs(FDClassObject):
         'RAW'               : 'EFI_FV_FILETYPE_RAW',
         'PEI_DXE_COMBO'     : 'EFI_FV_FILETYPE_COMBINED_PEIM_DRIVER',
         'SMM'               : 'EFI_FV_FILETYPE_SMM',
-        'SMM_CORE'          : 'EFI_FV_FILETYPE_SMM_CORE'
+        'SMM_CORE'          : 'EFI_FV_FILETYPE_SMM_CORE',
+        'MM_STANDALONE'     : 'EFI_FV_FILETYPE_MM_STANDALONE',
+        'MM_CORE_STANDALONE' : 'EFI_FV_FILETYPE_MM_CORE_STANDALONE'
     }
     
     # mapping between section type in FDF and file suffix
diff --git a/BaseTools/Source/Python/GenFds/FfsInfStatement.py b/BaseTools/Source/Python/GenFds/FfsInfStatement.py
index e9517a4..c61c227 100644
--- a/BaseTools/Source/Python/GenFds/FfsInfStatement.py
+++ b/BaseTools/Source/Python/GenFds/FfsInfStatement.py
@@ -224,6 +224,9 @@ class FfsInfStatement(FfsInfStatementClassObject):
         if self.ModuleType == 'SMM_CORE' and int(self.PiSpecVersion, 16) < 0x0001000A:
             EdkLogger.error("GenFds", FORMAT_NOT_SUPPORTED, "SMM_CORE module type can't be used in the module with PI_SPECIFICATION_VERSION less than 0x0001000A", File=self.InfFileName)      
 
+        if self.ModuleType == 'MM_CORE_STANDALONE' and int(self.PiSpecVersion, 16) < 0x00010032:
+            EdkLogger.error("GenFds", FORMAT_NOT_SUPPORTED, "MM_CORE_STANDALONE module type can't be used in the module with PI_SPECIFICATION_VERSION less than 0x00010032", File=self.InfFileName)
+
         if Inf._Defs != None and len(Inf._Defs) > 0:
             self.OptRomDefs.update(Inf._Defs)
 
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH v5 08/10] BaseTools/build: register MM module types with build tools.
  2017-06-26 16:47 [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification *** Supreeth Venkatesh
                   ` (6 preceding siblings ...)
  2017-06-26 16:47 ` [PATCH v5 07/10] BaseTools/GenFds: register MM Modules and MM FV file types Supreeth Venkatesh
@ 2017-06-26 16:47 ` Supreeth Venkatesh
  2017-06-26 16:47 ` [PATCH v5 09/10] BaseTools/Workspace: check MM module type compatibility with PI version Supreeth Venkatesh
                   ` (3 subsequent siblings)
  11 siblings, 0 replies; 15+ messages in thread
From: Supreeth Venkatesh @ 2017-06-26 16:47 UTC (permalink / raw)
  To: edk2-devel
  Cc: leif.lindholm, michael.d.kinney, liming.gao, achin.gupta,
	supreeth.venkatesh, felixp, jbrasen, jonathan.zhang, Jiewen Yao

This patch registers MM_STANDALONE and MM_CORE_STANDALONE module type
with python build tools.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jiewen Yao <jiewen.yao@intel.com>
Signed-off-by: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
---
 BaseTools/Source/Python/build/BuildReport.py | 4 +++-
 BaseTools/Source/Python/build/build.py       | 2 +-
 2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/BaseTools/Source/Python/build/BuildReport.py b/BaseTools/Source/Python/build/BuildReport.py
index 91d1e93..bf6ecb5 100644
--- a/BaseTools/Source/Python/build/BuildReport.py
+++ b/BaseTools/Source/Python/build/BuildReport.py
@@ -123,6 +123,8 @@ gDriverTypeMap = {
   'UEFI_APPLICATION'  : '0x9 (APPLICATION)',
   'SMM_CORE'          : '0xD (SMM_CORE)',
   'SMM_DRIVER'        : '0xA (SMM)', # Extension of module type to support PI 1.1 SMM drivers
+  'MM_STANDALONE'     : '0xE (MM_STANDALONE)',
+  'MM_CORE_STANDALONE' : '0xF (MM_CORE_STANDALONE)'
   }
 
 ## The look up table of the supported opcode in the dependency expression binaries
@@ -374,7 +376,7 @@ class DepexReport(object):
         if not ModuleType:
             ModuleType = gComponentType2ModuleType.get(M.ComponentType, "")
 
-        if ModuleType in ["SEC", "PEI_CORE", "DXE_CORE", "SMM_CORE", "UEFI_APPLICATION"]:
+        if ModuleType in ["SEC", "PEI_CORE", "DXE_CORE", "SMM_CORE", "MM_CORE_STANDALONE", "UEFI_APPLICATION"]:
             return
       
         for Source in M.SourceFileList:
diff --git a/BaseTools/Source/Python/build/build.py b/BaseTools/Source/Python/build/build.py
index fd94ae6..2b7f10f 100644
--- a/BaseTools/Source/Python/build/build.py
+++ b/BaseTools/Source/Python/build/build.py
@@ -1499,7 +1499,7 @@ class Build():
                         if IsIpfPlatform and ImageInfo.Image.Size % 0x2000 != 0:
                             ImageInfo.Image.Size = (ImageInfo.Image.Size / 0x2000 + 1) * 0x2000
                         RtSize += ImageInfo.Image.Size
-                    elif Module.ModuleType in ['SMM_CORE', 'DXE_SMM_DRIVER']:
+                    elif Module.ModuleType in ['SMM_CORE', 'DXE_SMM_DRIVER', 'MM_STANDALONE', 'MM_CORE_STANDALONE']:
                         SmmModuleList[Module.MetaFile] = ImageInfo
                         SmmSize += ImageInfo.Image.Size
                         if Module.ModuleType == 'DXE_SMM_DRIVER':
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH v5 09/10] BaseTools/Workspace: check MM module type compatibility with PI version.
  2017-06-26 16:47 [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification *** Supreeth Venkatesh
                   ` (7 preceding siblings ...)
  2017-06-26 16:47 ` [PATCH v5 08/10] BaseTools/build: register MM module types with build tools Supreeth Venkatesh
@ 2017-06-26 16:47 ` Supreeth Venkatesh
  2017-06-26 16:47 ` [PATCH v5 10/10] BaseTools/Eot: register MM Module types with FFS class Supreeth Venkatesh
                   ` (2 subsequent siblings)
  11 siblings, 0 replies; 15+ messages in thread
From: Supreeth Venkatesh @ 2017-06-26 16:47 UTC (permalink / raw)
  To: edk2-devel
  Cc: leif.lindholm, michael.d.kinney, liming.gao, achin.gupta,
	supreeth.venkatesh, felixp, jbrasen, jonathan.zhang, Jiewen Yao

This patch checks SUP_MODULE_MM_CORE_STANDALONE and
SUP_MODULE_MM_STANDALONE module compatibility with PI specification
version.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jiewen Yao <jiewen.yao@intel.com>
Signed-off-by: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
---
 BaseTools/Source/Python/Workspace/WorkspaceDatabase.py | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/BaseTools/Source/Python/Workspace/WorkspaceDatabase.py b/BaseTools/Source/Python/Workspace/WorkspaceDatabase.py
index c1af5c7..73b3fe7 100644
--- a/BaseTools/Source/Python/Workspace/WorkspaceDatabase.py
+++ b/BaseTools/Source/Python/Workspace/WorkspaceDatabase.py
@@ -1977,6 +1977,11 @@ class InfBuildData(ModuleBuildClassObject):
             if (self._Specification == None) or (not 'PI_SPECIFICATION_VERSION' in self._Specification) or (int(self._Specification['PI_SPECIFICATION_VERSION'], 16) < 0x0001000A):
                 if self._ModuleType == SUP_MODULE_SMM_CORE:
                     EdkLogger.error("build", FORMAT_NOT_SUPPORTED, "SMM_CORE module type can't be used in the module with PI_SPECIFICATION_VERSION less than 0x0001000A", File=self.MetaFile)
+            if (self._Specification == None) or (not 'PI_SPECIFICATION_VERSION' in self._Specification) or (int(self._Specification['PI_SPECIFICATION_VERSION'], 16) < 0x00010032):
+                if self._ModuleType == SUP_MODULE_MM_CORE_STANDALONE:
+                    EdkLogger.error("build", FORMAT_NOT_SUPPORTED, "MM_CORE_STANDALONE module type can't be used in the module with PI_SPECIFICATION_VERSION less than 0x00010032", File=self.MetaFile)
+                if self._ModuleType == SUP_MODULE_MM_STANDALONE:
+                    EdkLogger.error("build", FORMAT_NOT_SUPPORTED, "MM_STANDALONE module type can't be used in the module with PI_SPECIFICATION_VERSION less than 0x00010032", File=self.MetaFile)
             if self._Defs and 'PCI_DEVICE_ID' in self._Defs and 'PCI_VENDOR_ID' in self._Defs \
                and 'PCI_CLASS_CODE' in self._Defs and 'PCI_REVISION' in self._Defs:
                 self._BuildType = 'UEFI_OPTIONROM'
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH v5 10/10] BaseTools/Eot: register MM Module types with FFS class.
  2017-06-26 16:47 [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification *** Supreeth Venkatesh
                   ` (8 preceding siblings ...)
  2017-06-26 16:47 ` [PATCH v5 09/10] BaseTools/Workspace: check MM module type compatibility with PI version Supreeth Venkatesh
@ 2017-06-26 16:47 ` Supreeth Venkatesh
  2017-06-26 19:47 ` [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification *** Laszlo Ersek
  2017-07-07  2:56 ` Zhu, Yonghong
  11 siblings, 0 replies; 15+ messages in thread
From: Supreeth Venkatesh @ 2017-06-26 16:47 UTC (permalink / raw)
  To: edk2-devel
  Cc: leif.lindholm, michael.d.kinney, liming.gao, achin.gupta,
	supreeth.venkatesh, felixp, jbrasen, jonathan.zhang, Jiewen Yao

This patch registers MM_STANDALONE and MM_CORE_STANDALONE with Ffs class.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jiewen Yao <jiewen.yao@intel.com>
Signed-off-by: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
---
 BaseTools/Source/Python/Eot/FvImage.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/BaseTools/Source/Python/Eot/FvImage.py b/BaseTools/Source/Python/Eot/FvImage.py
index f2a9bc6..0f742c7 100644
--- a/BaseTools/Source/Python/Eot/FvImage.py
+++ b/BaseTools/Source/Python/Eot/FvImage.py
@@ -999,6 +999,8 @@ class Ffs(Image):
         0x0B    :   "FIRMWARE_VOLUME_IMAGE",
         0x0C    :   "COMBINED_SMM_DXE",
         0x0D    :   "SMM_CORE",
+        0x0E    :   "MM_STANDALONE",
+        0x0F    :   "MM_CORE_STANDALONE",
         0xc0    :   "OEM_MIN",
         0xdf    :   "OEM_MAX",
         0xe0    :   "DEBUG_MIN",
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 15+ messages in thread

* Re: [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification ***
  2017-06-26 16:47 [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification *** Supreeth Venkatesh
                   ` (9 preceding siblings ...)
  2017-06-26 16:47 ` [PATCH v5 10/10] BaseTools/Eot: register MM Module types with FFS class Supreeth Venkatesh
@ 2017-06-26 19:47 ` Laszlo Ersek
  2017-07-07  2:56 ` Zhu, Yonghong
  11 siblings, 0 replies; 15+ messages in thread
From: Laszlo Ersek @ 2017-06-26 19:47 UTC (permalink / raw)
  To: Supreeth Venkatesh, edk2-devel
  Cc: jonathan.zhang, liming.gao, leif.lindholm, felixp,
	michael.d.kinney, jbrasen

On 06/26/17 18:47, Supreeth Venkatesh wrote:
> *** 
> PI v1.5 Specification Volume 4 defines Management Mode Core Interface.
> In order to support Management Mode Core Interface, Module Types MM_STANDALONE, MM_CORE_STANDALONE are needed. 
> PI specification v1.5 defines the following new file types:
> #define EFI_FV_FILETYPE_MM_STANDALONE 0x0E
> #define EFI_FV_FILETYPE_MM_CORE_STANDALONE 0x0F
> The following changes are necessitated in order to support the above changes to the specification. 
> 
> Changes Since v4:
> (*) Update Review Comment from Laszlo.
> (*) Reword Commit subject for the patches in the set to 
> convey meaningful summary. 

Thanks Supreeth, from a quick skim, the subjects look great!

Laszlo


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v5 01/10] BaseTools/GenFfs: add FFS file types for MM modules.
  2017-06-26 16:47 ` [PATCH v5 01/10] BaseTools/GenFfs: add FFS file types for MM modules Supreeth Venkatesh
@ 2017-06-29  8:52   ` Gao, Liming
  0 siblings, 0 replies; 15+ messages in thread
From: Gao, Liming @ 2017-06-29  8:52 UTC (permalink / raw)
  To: Supreeth Venkatesh, edk2-devel@lists.01.org
  Cc: leif.lindholm@linaro.org, Kinney, Michael D, achin.gupta@arm.com,
	felixp@ami.com, jbrasen@qti.qualcomm.com,
	jonathan.zhang@cavium.com, Yao, Jiewen

Supreeth:
  The patches are good to me. Reviewed-by: Liming Gao <liming.gao@intel.com>

>-----Original Message-----
>From: Supreeth Venkatesh [mailto:supreeth.venkatesh@arm.com]
>Sent: Tuesday, June 27, 2017 12:48 AM
>To: edk2-devel@lists.01.org
>Cc: leif.lindholm@linaro.org; Kinney, Michael D
><michael.d.kinney@intel.com>; Gao, Liming <liming.gao@intel.com>;
>achin.gupta@arm.com; supreeth.venkatesh@arm.com; felixp@ami.com;
>jbrasen@qti.qualcomm.com; jonathan.zhang@cavium.com; Yao, Jiewen
><jiewen.yao@intel.com>
>Subject: [PATCH v5 01/10] BaseTools/GenFfs: add FFS file types for MM
>modules.
>
>PI specification v1.5 defines new firmware volume file types
>for Management Mode (MM).
>
>This patch adds the new file type EFI_FV_FILETYPE_MM_STANDALONE and
>EFI_FV_FILETYPE_MM_CORE_STANDALONE in GenFfs tool.
>
>Contributed-under: TianoCore Contribution Agreement 1.0
>Signed-off-by: Jiewen Yao <jiewen.yao@intel.com>
>Signed-off-by: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
>---
> BaseTools/Source/C/GenFfs/GenFfs.c                 | 8 ++++++--
> BaseTools/Source/C/Include/Common/PiFirmwareFile.h | 2 ++
> 2 files changed, 8 insertions(+), 2 deletions(-)
>
>diff --git a/BaseTools/Source/C/GenFfs/GenFfs.c
>b/BaseTools/Source/C/GenFfs/GenFfs.c
>index c5d657b..91632a9 100644
>--- a/BaseTools/Source/C/GenFfs/GenFfs.c
>+++ b/BaseTools/Source/C/GenFfs/GenFfs.c
>@@ -43,8 +43,10 @@ STATIC CHAR8 *mFfsFileType[] = {
>   "EFI_FV_FILETYPE_SMM",                  // 0x0A
>   "EFI_FV_FILETYPE_FIRMWARE_VOLUME_IMAGE",// 0x0B
>   "EFI_FV_FILETYPE_COMBINED_SMM_DXE",     // 0x0C
>-  "EFI_FV_FILETYPE_SMM_CORE"              // 0x0D
>- };
>+  "EFI_FV_FILETYPE_SMM_CORE",             // 0x0D
>+  "EFI_FV_FILETYPE_MM_STANDALONE",        // 0x0E
>+  "EFI_FV_FILETYPE_MM_CORE_STANDALONE"    // 0x0F
>+};
>
> STATIC CHAR8 *mAlignName[] = {
>   "1", "2", "4", "8", "16", "32", "64", "128", "256", "512",
>@@ -130,6 +132,8 @@ Returns:
>                         EFI_FV_FILETYPE_DRIVER, EFI_FV_FILETYPE_APPLICATION,\n\
>                         EFI_FV_FILETYPE_COMBINED_PEIM_DRIVER,\n\
>                         EFI_FV_FILETYPE_SMM, EFI_FV_FILETYPE_SMM_CORE,\n\
>+                        EFI_FV_FILETYPE_MM_STANDALONE,\n\
>+                        EFI_FV_FILETYPE_MM_CORE_STANDALONE,\n\
>                         EFI_FV_FILETYPE_COMBINED_SMM_DXE, \n\
>                         EFI_FV_FILETYPE_FIRMWARE_VOLUME_IMAGE.\n");
>   fprintf (stdout, "  -g FileGuid, --fileguid FileGuid\n\
>diff --git a/BaseTools/Source/C/Include/Common/PiFirmwareFile.h
>b/BaseTools/Source/C/Include/Common/PiFirmwareFile.h
>index 2984860..8c54021 100644
>--- a/BaseTools/Source/C/Include/Common/PiFirmwareFile.h
>+++ b/BaseTools/Source/C/Include/Common/PiFirmwareFile.h
>@@ -52,6 +52,8 @@ typedef UINT8 EFI_FFS_FILE_STATE;
> #define EFI_FV_FILETYPE_FIRMWARE_VOLUME_IMAGE 0x0B
> #define EFI_FV_FILETYPE_COMBINED_SMM_DXE      0x0C
> #define EFI_FV_FILETYPE_SMM_CORE              0x0D
>+#define EFI_FV_FILETYPE_MM_STANDALONE         0x0E
>+#define EFI_FV_FILETYPE_MM_CORE_STANDALONE    0x0F
> #define EFI_FV_FILETYPE_OEM_MIN               0xc0
> #define EFI_FV_FILETYPE_OEM_MAX               0xdf
> #define EFI_FV_FILETYPE_DEBUG_MIN             0xe0
>--
>2.7.4



^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification ***
  2017-06-26 16:47 [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification *** Supreeth Venkatesh
                   ` (10 preceding siblings ...)
  2017-06-26 19:47 ` [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification *** Laszlo Ersek
@ 2017-07-07  2:56 ` Zhu, Yonghong
  2017-07-07 17:09   ` Supreeth Venkatesh
  11 siblings, 1 reply; 15+ messages in thread
From: Zhu, Yonghong @ 2017-07-07  2:56 UTC (permalink / raw)
  To: Supreeth Venkatesh, edk2-devel@lists.01.org
  Cc: jonathan.zhang@cavium.com, Gao, Liming, leif.lindholm@linaro.org,
	felixp@ami.com, Kinney, Michael D, jbrasen@qti.qualcomm.com,
	Zhu, Yonghong

I pushed this series patch.

Best Regards,
Zhu Yonghong


-----Original Message-----
From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Supreeth Venkatesh
Sent: Tuesday, June 27, 2017 12:48 AM
To: edk2-devel@lists.01.org
Cc: jonathan.zhang@cavium.com; Gao, Liming <liming.gao@intel.com>; leif.lindholm@linaro.org; felixp@ami.com; Kinney, Michael D <michael.d.kinney@intel.com>; jbrasen@qti.qualcomm.com
Subject: [edk2] [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification ***

***
PI v1.5 Specification Volume 4 defines Management Mode Core Interface.
In order to support Management Mode Core Interface, Module Types MM_STANDALONE, MM_CORE_STANDALONE are needed. 
PI specification v1.5 defines the following new file types:
#define EFI_FV_FILETYPE_MM_STANDALONE 0x0E #define EFI_FV_FILETYPE_MM_CORE_STANDALONE 0x0F The following changes are necessitated in order to support the above changes to the specification. 

Changes Since v4:
(*) Update Review Comment from Laszlo.
(*) Reword Commit subject for the patches in the set to convey meaningful summary. 

Changes Since v3:
(*) Update Review Comments from Liming, Felix.
(*) Directly define FV file types MM_STANDALONE / MM_CORE_STANDALONE and module types MM_STANDALONE / MM_CORE_STANDALONE i.e., with MM prefix instead of SMM prefix.

Changes Since v2:
Add missing EFI_FV_FILETYPE_MM_CORE_STANDALONE defined in PI Specification v1.5 VOL3, but not defined in VOL4.

Changes Since v1:
Corrected Version check HEX Value "0x00010032" (1 and 50), not 0x0001000A (1 and 10)
***

Supreeth Venkatesh (10):
  BaseTools/GenFfs: add FFS file types for MM modules.
  BaseTools/GenFw: recognize MM file types as EFI Boot Service Drivers.
  BaseTools/AutoGen: auto generate MM template APIs and dependencies.
  BaseTools/Common: add MM Module data types.
  BaseTools/Common: add support in FDF Parser to parse MM Modules.
  BaseTools/CommonDataClass: register MM Modules.
  BaseTools/GenFds: register MM Modules and MM FV file types.
  BaseTools/build: register MM module types with build tools.
  BaseTools/Workspace: check MM module type compatibility with PI
    version.
  BaseTools/Eot: register MM Module types with FFS class.

 BaseTools/Source/C/GenFfs/GenFfs.c                 |   8 +-
 BaseTools/Source/C/GenFw/GenFw.c                   |   5 +-
 BaseTools/Source/C/Include/Common/PiFirmwareFile.h |   2 +
 BaseTools/Source/Python/AutoGen/GenC.py            | 148 ++++++++++++++++++++-
 BaseTools/Source/Python/AutoGen/GenDepex.py        |  17 ++-
 BaseTools/Source/Python/Common/DataType.py         |   4 +-
 BaseTools/Source/Python/Common/FdfParserLite.py    |   4 +-
 .../Source/Python/CommonDataClass/CommonClass.py   |   6 +-
 .../Source/Python/CommonDataClass/PackageClass.py  |   2 +-
 BaseTools/Source/Python/Eot/FvImage.py             |   2 +
 BaseTools/Source/Python/GenFds/FdfParser.py        |   4 +-
 BaseTools/Source/Python/GenFds/Ffs.py              |   8 +-
 BaseTools/Source/Python/GenFds/FfsInfStatement.py  |   3 +
 .../Source/Python/Workspace/WorkspaceDatabase.py   |   5 +
 BaseTools/Source/Python/build/BuildReport.py       |   4 +-
 BaseTools/Source/Python/build/build.py             |   2 +-
 16 files changed, 205 insertions(+), 19 deletions(-)

--
2.7.4

_______________________________________________
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 v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification ***
  2017-07-07  2:56 ` Zhu, Yonghong
@ 2017-07-07 17:09   ` Supreeth Venkatesh
  0 siblings, 0 replies; 15+ messages in thread
From: Supreeth Venkatesh @ 2017-07-07 17:09 UTC (permalink / raw)
  To: Zhu, Yonghong, edk2-devel@lists.01.org
  Cc: jonathan.zhang@cavium.com, Gao, Liming, leif.lindholm@linaro.org,
	Felixp@ami.com, Kinney, Michael D, jbrasen@qti.qualcomm.com

Zhu Yonghong,

Thank you.

Supreeth

-----Original Message-----
From: Zhu, Yonghong [mailto:yonghong.zhu@intel.com]
Sent: Thursday, July 6, 2017 9:57 PM
To: Supreeth Venkatesh <Supreeth.Venkatesh@arm.com>; edk2-devel@lists.01.org
Cc: jonathan.zhang@cavium.com; Gao, Liming <liming.gao@intel.com>; leif.lindholm@linaro.org; Felixp@ami.com; Kinney, Michael D <michael.d.kinney@intel.com>; jbrasen@qti.qualcomm.com; Zhu, Yonghong <yonghong.zhu@intel.com>
Subject: RE: [edk2] [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification ***

I pushed this series patch.

Best Regards,
Zhu Yonghong


-----Original Message-----
From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Supreeth Venkatesh
Sent: Tuesday, June 27, 2017 12:48 AM
To: edk2-devel@lists.01.org
Cc: jonathan.zhang@cavium.com; Gao, Liming <liming.gao@intel.com>; leif.lindholm@linaro.org; felixp@ami.com; Kinney, Michael D <michael.d.kinney@intel.com>; jbrasen@qti.qualcomm.com
Subject: [edk2] [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification ***

***
PI v1.5 Specification Volume 4 defines Management Mode Core Interface.
In order to support Management Mode Core Interface, Module Types MM_STANDALONE, MM_CORE_STANDALONE are needed.
PI specification v1.5 defines the following new file types:
#define EFI_FV_FILETYPE_MM_STANDALONE 0x0E #define EFI_FV_FILETYPE_MM_CORE_STANDALONE 0x0F The following changes are necessitated in order to support the above changes to the specification.

Changes Since v4:
(*) Update Review Comment from Laszlo.
(*) Reword Commit subject for the patches in the set to convey meaningful summary.

Changes Since v3:
(*) Update Review Comments from Liming, Felix.
(*) Directly define FV file types MM_STANDALONE / MM_CORE_STANDALONE and module types MM_STANDALONE / MM_CORE_STANDALONE i.e., with MM prefix instead of SMM prefix.

Changes Since v2:
Add missing EFI_FV_FILETYPE_MM_CORE_STANDALONE defined in PI Specification v1.5 VOL3, but not defined in VOL4.

Changes Since v1:
Corrected Version check HEX Value "0x00010032" (1 and 50), not 0x0001000A (1 and 10)
***

Supreeth Venkatesh (10):
  BaseTools/GenFfs: add FFS file types for MM modules.
  BaseTools/GenFw: recognize MM file types as EFI Boot Service Drivers.
  BaseTools/AutoGen: auto generate MM template APIs and dependencies.
  BaseTools/Common: add MM Module data types.
  BaseTools/Common: add support in FDF Parser to parse MM Modules.
  BaseTools/CommonDataClass: register MM Modules.
  BaseTools/GenFds: register MM Modules and MM FV file types.
  BaseTools/build: register MM module types with build tools.
  BaseTools/Workspace: check MM module type compatibility with PI
    version.
  BaseTools/Eot: register MM Module types with FFS class.

 BaseTools/Source/C/GenFfs/GenFfs.c                 |   8 +-
 BaseTools/Source/C/GenFw/GenFw.c                   |   5 +-
 BaseTools/Source/C/Include/Common/PiFirmwareFile.h |   2 +
 BaseTools/Source/Python/AutoGen/GenC.py            | 148 ++++++++++++++++++++-
 BaseTools/Source/Python/AutoGen/GenDepex.py        |  17 ++-
 BaseTools/Source/Python/Common/DataType.py         |   4 +-
 BaseTools/Source/Python/Common/FdfParserLite.py    |   4 +-
 .../Source/Python/CommonDataClass/CommonClass.py   |   6 +-
 .../Source/Python/CommonDataClass/PackageClass.py  |   2 +-
 BaseTools/Source/Python/Eot/FvImage.py             |   2 +
 BaseTools/Source/Python/GenFds/FdfParser.py        |   4 +-
 BaseTools/Source/Python/GenFds/Ffs.py              |   8 +-
 BaseTools/Source/Python/GenFds/FfsInfStatement.py  |   3 +
 .../Source/Python/Workspace/WorkspaceDatabase.py   |   5 +
 BaseTools/Source/Python/build/BuildReport.py       |   4 +-
 BaseTools/Source/Python/build/build.py             |   2 +-
 16 files changed, 205 insertions(+), 19 deletions(-)

--
2.7.4

_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel
IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.


^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2017-07-07 17:08 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-06-26 16:47 [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification *** Supreeth Venkatesh
2017-06-26 16:47 ` [PATCH v5 01/10] BaseTools/GenFfs: add FFS file types for MM modules Supreeth Venkatesh
2017-06-29  8:52   ` Gao, Liming
2017-06-26 16:47 ` [PATCH v5 02/10] BaseTools/GenFw: recognize MM file types as EFI Boot Service Drivers Supreeth Venkatesh
2017-06-26 16:47 ` [PATCH v5 03/10] BaseTools/AutoGen: auto generate MM template APIs and dependencies Supreeth Venkatesh
2017-06-26 16:47 ` [PATCH v5 04/10] BaseTools/Common: add MM Module data types Supreeth Venkatesh
2017-06-26 16:47 ` [PATCH v5 05/10] BaseTools/Common: add support in FDF Parser to parse MM Modules Supreeth Venkatesh
2017-06-26 16:47 ` [PATCH v5 06/10] BaseTools/CommonDataClass: register " Supreeth Venkatesh
2017-06-26 16:47 ` [PATCH v5 07/10] BaseTools/GenFds: register MM Modules and MM FV file types Supreeth Venkatesh
2017-06-26 16:47 ` [PATCH v5 08/10] BaseTools/build: register MM module types with build tools Supreeth Venkatesh
2017-06-26 16:47 ` [PATCH v5 09/10] BaseTools/Workspace: check MM module type compatibility with PI version Supreeth Venkatesh
2017-06-26 16:47 ` [PATCH v5 10/10] BaseTools/Eot: register MM Module types with FFS class Supreeth Venkatesh
2017-06-26 19:47 ` [PATCH v5 00/10] *** BaseTools: Tools change to support MM Interface in PI v1.5 Specification *** Laszlo Ersek
2017-07-07  2:56 ` Zhu, Yonghong
2017-07-07 17:09   ` Supreeth Venkatesh

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox