git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10626
6f19259b-4bc3-4df7-8a09-
765794883524
EFI_STATUS Status;\r
EFI_PCI_IO_PROTOCOL *PciIo;\r
PCI_TYPE00 Pci;\r
EFI_STATUS Status;\r
EFI_PCI_IO_PROTOCOL *PciIo;\r
PCI_TYPE00 Pci;\r
+ UINTN SegmentNumber;\r
+ UINTN BusNumber;\r
+ UINTN DeviceNumber;\r
+ UINTN FunctionNumber;\r
\r
//\r
// Get PciIo protocol instance\r
\r
//\r
// Get PciIo protocol instance\r
//\r
// See if this is an Intel PCI to ISA bridge in Positive Decode Mode\r
//\r
//\r
// See if this is an Intel PCI to ISA bridge in Positive Decode Mode\r
//\r
- if (Pci.Hdr.ClassCode[1] == PCI_CLASS_BRIDGE_ISA_PDECODE &&\r
- Pci.Hdr.VendorId == 0x8086 && \r
- (Pci.Hdr.DeviceId & 0xF000) == 0x7000) {\r
- Status = EFI_SUCCESS;\r
+ if (Pci.Hdr.ClassCode[1] == PCI_CLASS_BRIDGE_ISA_PDECODE && \r
+ Pci.Hdr.VendorId == 0x8086 ) {\r
+ //\r
+ // See if this is on Function #0 to avoid false positives on \r
+ // PCI_CLASS_BRIDGE_OTHER that has the same value as \r
+ // PCI_CLASS_BRIDGE_ISA_PDECODE\r
+ //\r
+ Status = PciIo->GetLocation (\r
+ PciIo, \r
+ &SegmentNumber, \r
+ &BusNumber, \r
+ &DeviceNumber, \r
+ &FunctionNumber\r
+ );\r
+ if (!EFI_ERROR (Status) && FunctionNumber == 0) {\r
+ Status = EFI_SUCCESS;\r
+ } else {\r
+ Status = EFI_UNSUPPORTED;\r
+ }\r