]> git.proxmox.com Git - mirror_edk2.git/blobdiff - IntelFsp2Pkg/Tools/GenCfgOpt.py
IntelFsp2Pkg: FSPI_UPD is not mandatory.
[mirror_edk2.git] / IntelFsp2Pkg / Tools / GenCfgOpt.py
index 128b8965926caf390c8a0aca8297c6e65a42773e..71c48f10e0c23da29605658af8404774bbd0dcc4 100644 (file)
@@ -959,8 +959,13 @@ EndList
             UpdTxtFile = ''\r
             FvDir = self._FvDir\r
             if GuidList[Index] not in self._MacroDict:\r
-                self.Error = "%s definition is missing in DSC file" % (GuidList[Index])\r
-                return 1\r
+                NoFSPI = False\r
+                if GuidList[Index] == 'FSP_I_UPD_TOOL_GUID':\r
+                    NoFSPI = True\r
+                    continue\r
+                else:\r
+                    self.Error = "%s definition is missing in DSC file" % (GuidList[Index])\r
+                    return 1\r
 \r
             if UpdTxtFile == '':\r
                 UpdTxtFile = os.path.join(FvDir, self._MacroDict[GuidList[Index]] + '.txt')\r
@@ -1296,7 +1301,8 @@ EndList
                elif '_S' in SignatureStr[6:6+2]:\r
                    TxtBody.append("#define FSPS_UPD_SIGNATURE               %s        /* '%s' */\n\n" % (Item['value'], SignatureStr))\r
                elif '_I' in SignatureStr[6:6+2]:\r
-                   TxtBody.append("#define FSPI_UPD_SIGNATURE               %s        /* '%s' */\n\n" % (Item['value'], SignatureStr))\r
+                   if NoFSPI == True:\r
+                       TxtBody.append("#define FSPI_UPD_SIGNATURE               %s        /* '%s' */\n\n" % (Item['value'], SignatureStr))\r
         TxtBody.append("\n")\r
 \r
         for Region in ['UPD']:\r
@@ -1702,7 +1708,7 @@ EndList
 \r
 \r
 def Usage():\r
-    print ("GenCfgOpt Version 0.58")\r
+    print ("GenCfgOpt Version 0.59")\r
     print ("Usage:")\r
     print ("    GenCfgOpt  UPDTXT  PlatformDscFile BuildFvDir                 [-D Macros]")\r
     print ("    GenCfgOpt  HEADER  PlatformDscFile BuildFvDir  InputHFile     [-D Macros]")\r