]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Source/Python/GenFds/FfsInfStatement.py
BaseTools: Update Gensec to set PROCESSING_REQUIRED value
[mirror_edk2.git] / BaseTools / Source / Python / GenFds / FfsInfStatement.py
index c61c227c99000df9926db44ada82b2c2e401e76c..958cecfad63e847b4ecf58acb45c946505ec3ee0 100644 (file)
@@ -1,7 +1,7 @@
 ## @file\r
 # process FFS generation from INF statement\r
 #\r
-#  Copyright (c) 2007 - 2016, Intel Corporation. All rights reserved.<BR>\r
+#  Copyright (c) 2007 - 2017, Intel Corporation. All rights reserved.<BR>\r
 #  Copyright (c) 2014-2016 Hewlett-Packard Development Company, L.P.<BR>\r
 #\r
 #  This program and the accompanying materials\r
@@ -731,8 +731,10 @@ class FfsInfStatement(FfsInfStatementClassObject):
                     ImageObj = PeImageClass (File)\r
                     if ImageObj.SectionAlignment < 0x400:\r
                         self.Alignment = str (ImageObj.SectionAlignment)\r
-                    else:\r
+                    elif ImageObj.SectionAlignment < 0x100000:\r
                         self.Alignment = str (ImageObj.SectionAlignment / 0x400) + 'K'\r
+                    else:\r
+                        self.Alignment = str (ImageObj.SectionAlignment / 0x100000) + 'M'\r
 \r
                 if not NoStrip:\r
                     FileBeforeStrip = os.path.join(self.OutputPath, ModuleName + '.reloc')\r
@@ -770,8 +772,10 @@ class FfsInfStatement(FfsInfStatementClassObject):
                 ImageObj = PeImageClass (GenSecInputFile)\r
                 if ImageObj.SectionAlignment < 0x400:\r
                     self.Alignment = str (ImageObj.SectionAlignment)\r
-                else:\r
+                elif ImageObj.SectionAlignment < 0x100000:\r
                     self.Alignment = str (ImageObj.SectionAlignment / 0x400) + 'K'\r
+                else:\r
+                    self.Alignment = str (ImageObj.SectionAlignment / 0x100000) + 'M'\r
 \r
             if not NoStrip:\r
                 FileBeforeStrip = os.path.join(self.OutputPath, ModuleName + '.reloc')\r