]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Source/Python/GenFds/OptRomInfStatement.py
BaseTools: Replace BSD License with BSD+Patent License
[mirror_edk2.git] / BaseTools / Source / Python / GenFds / OptRomInfStatement.py
index dff8235ef755800055c4e6c192b6a9a6067039eb..8b570ed6bcbc5dc6e4b924a7364658722831dfb1 100644 (file)
@@ -3,28 +3,22 @@
 #\r
 #  Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved.<BR>\r
 #\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
-#\r
-#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+#  SPDX-License-Identifier: BSD-2-Clause-Patent\r
 #\r
 \r
 ##\r
 # Import Modules\r
 #\r
-import RuleSimpleFile\r
-import RuleComplexFile\r
-import Section\r
-import OptionRom\r
+from __future__ import absolute_import\r
+from . import RuleSimpleFile\r
+from . import RuleComplexFile\r
+from . import Section\r
 import Common.GlobalData as GlobalData\r
 \r
 from Common.DataType import *\r
 from Common.StringUtils import *\r
-from FfsInfStatement import FfsInfStatement\r
-from GenFdsGlobalVariable import GenFdsGlobalVariable\r
+from .FfsInfStatement import FfsInfStatement\r
+from .GenFdsGlobalVariable import GenFdsGlobalVariable\r
 \r
 ##\r
 #\r
@@ -45,9 +39,8 @@ class OptRomInfStatement (FfsInfStatement):
     #   @param  self        The object pointer\r
     #\r
     def __GetOptRomParams(self):\r
-\r
         if self.OverrideAttribs is None:\r
-            self.OverrideAttribs = OptionRom.OverrideAttribs()\r
+            self.OverrideAttribs = OverrideAttribs()\r
 \r
         if self.OverrideAttribs.NeedCompress is None:\r
             self.OverrideAttribs.NeedCompress = self.OptRomDefs.get ('PCI_COMPRESS')\r
@@ -151,4 +144,16 @@ class OptRomInfStatement (FfsInfStatement):
 \r
         return OutputFileList\r
 \r
+class OverrideAttribs:\r
+\r
+    ## The constructor\r
+    #\r
+    #   @param  self        The object pointer\r
+    #\r
+    def __init__(self):\r
 \r
+        self.PciVendorId = None\r
+        self.PciClassCode = None\r
+        self.PciDeviceId = None\r
+        self.PciRevision = None\r
+        self.NeedCompress = None\r