]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Source/Python/GenFds/Fv.py
MdeModulePkg: Fix build warning on Xhci driver with XCode 32 tool chain.
[mirror_edk2.git] / BaseTools / Source / Python / GenFds / Fv.py
index 8d2ef1d87419c1923a5341fce0470f107c6475bb..6c7a0503cfa61ac1a31ffec2fc340a4dd614597c 100644 (file)
@@ -1,9 +1,9 @@
 ## @file\r
 # process FV generation\r
 #\r
-#  Copyright (c) 2007 - 2010, Intel Corporation\r
+#  Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>\r
 #\r
-#  All rights reserved. This program and the accompanying materials\r
+#  This program and the accompanying materials\r
 #  are licensed and made available under the terms and conditions of the BSD License\r
 #  which accompanies this distribution.  The full text of the license may be found at\r
 #  http://opensource.org/licenses/bsd-license.php\r
@@ -46,7 +46,9 @@ class FV (FvClassObject):
         self.InfFileName = None\r
         self.FvAddressFileName = None\r
         self.CapsuleName = None\r
-\r
+        self.FvBaseAddress = None\r
+        self.FvForceRebase = None\r
+        \r
     ## AddToBuffer()\r
     #\r
     #   Generate Fv and add it to the Buffer\r
@@ -81,9 +83,12 @@ class FV (FvClassObject):
                             elif RegionData.upper() + 'fv' in GenFds.ImageBinDict.keys():\r
                                 continue\r
                             elif self.UiFvName.upper() == RegionData.upper():\r
-                               GenFdsGlobalVariable.ErrorLogger("Capsule %s in FD region can't contain a FV %s in FD region." % (self.CapsuleName, self.UiFvName.upper()))\r
+                                GenFdsGlobalVariable.ErrorLogger("Capsule %s in FD region can't contain a FV %s in FD region." % (self.CapsuleName, self.UiFvName.upper()))\r
 \r
         GenFdsGlobalVariable.InfLogger( "\nGenerating %s FV" %self.UiFvName)\r
+        \r
+        if self.FvBaseAddress != None:\r
+            BaseAddress = self.FvBaseAddress\r
 \r
         self.__InitializeInf__(BaseAddress, BlockSize, BlockNum, ErasePloarity, VtfDict)\r
         #\r
@@ -129,7 +134,8 @@ class FV (FvClassObject):
                                 FvOutputFile,\r
                                 [self.InfFileName],\r
                                 AddressFile=FvInfoFileName,\r
-                                FfsList=FfsFileList\r
+                                FfsList=FfsFileList,\r
+                                ForceRebase=self.FvForceRebase\r
                                 )\r
 \r
         NewFvInfo = None\r
@@ -158,7 +164,8 @@ class FV (FvClassObject):
                                         FvOutputFile,\r
                                         [self.InfFileName],\r
                                         AddressFile=FvInfoFileName,\r
-                                        FfsList=FfsFileList\r
+                                        FfsList=FfsFileList,\r
+                                        ForceRebase=self.FvForceRebase\r
                                         )\r
 \r
         #\r
@@ -309,7 +316,7 @@ class FV (FvClassObject):
                         Buffer += pack('B', int(ByteList[Index1], 16))\r
 \r
             Guid = self.FvNameGuid.split('-')\r
-            Buffer = pack('LHHBBBBBBBBL', \r
+            Buffer = pack('=LHHBBBBBBBBL', \r
                         int(Guid[0], 16), \r
                         int(Guid[1], 16), \r
                         int(Guid[2], 16), \r