From: Carsey, Jaben Date: Thu, 29 Mar 2018 00:02:19 +0000 (+0800) Subject: BaseTools: remove loop and variables. X-Git-Tag: edk2-stable201903~2009 X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=commitdiff_plain;h=5fbb0f9908ded1944aa4bba599ccc4c605987cb7;hp=0a014fba41b631258687f56e630518b54817d062 BaseTools: remove loop and variables. this loop does nothing. none of Key, Item, nor DevicePathList are ever used. Cc: Yonghong Zhu Cc: Liming Gao Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Jaben Carsey Reviewed-by: Yonghong Zhu --- diff --git a/BaseTools/Source/Python/Common/Misc.py b/BaseTools/Source/Python/Common/Misc.py index 4c33e645fa..d1752d8a62 100644 --- a/BaseTools/Source/Python/Common/Misc.py +++ b/BaseTools/Source/Python/Common/Misc.py @@ -1495,21 +1495,8 @@ def AnalyzePcdExpression(Setting): return FieldList def ParseDevPathValue (Value): - DevPathList = [ "Path","HardwarePath","Pci","PcCard","MemoryMapped","VenHw","Ctrl","BMC","AcpiPath","Acpi","PciRoot", - "PcieRoot","Floppy","Keyboard","Serial","ParallelPort","AcpiEx","AcpiExp","AcpiAdr","Msg","Ata","Scsi", - "Fibre","FibreEx","I1394","USB","I2O","Infiniband","VenMsg","VenPcAnsi","VenVt100","VenVt100Plus", - "VenUtf8","UartFlowCtrl","SAS","SasEx","NVMe","UFS","SD","eMMC","DebugPort","MAC","IPv4","IPv6","Uart", - "UsbClass","UsbAudio","UsbCDCControl","UsbHID","UsbImage","UsbPrinter","UsbMassStorage","UsbHub", - "UsbCDCData","UsbSmartCard","UsbVideo","UsbDiagnostic","UsbWireless","UsbDeviceFirmwareUpdate", - "UsbIrdaBridge","UsbTestAndMeasurement","UsbWwid","Unit","iSCSI","Vlan","Uri","Bluetooth","Wi-Fi", - "MediaPath","HD","CDROM","VenMedia","Media","Fv","FvFile","Offset","RamDisk","VirtualDisk","VirtualCD", - "PersistentVirtualDisk","PersistentVirtualCD","BbsPath","BBS","Sata" ] if '\\' in Value: Value.replace('\\', '/').replace(' ', '') - for Item in Value.split('/'): - Key = Item.strip().split('(')[0] - if Key not in DevPathList: - pass Cmd = 'DevicePath ' + '"' + Value + '"' try: