\r
**/\r
\r
+#include <IndustryStandard/FusionMptScsi.h>\r
+#include <IndustryStandard/Pci.h>\r
+#include <Library/UefiBootServicesTableLib.h>\r
#include <Library/UefiLib.h>\r
+#include <Protocol/PciIo.h>\r
#include <Uefi/UefiSpec.h>\r
\r
//\r
IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath OPTIONAL\r
)\r
{\r
- return EFI_UNSUPPORTED;\r
+ EFI_STATUS Status;\r
+ EFI_PCI_IO_PROTOCOL *PciIo;\r
+ PCI_TYPE00 Pci;\r
+\r
+ Status = gBS->OpenProtocol (\r
+ ControllerHandle,\r
+ &gEfiPciIoProtocolGuid,\r
+ (VOID **)&PciIo,\r
+ This->DriverBindingHandle,\r
+ ControllerHandle,\r
+ EFI_OPEN_PROTOCOL_BY_DRIVER\r
+ );\r
+ if (EFI_ERROR (Status)) {\r
+ return Status;\r
+ }\r
+\r
+ Status = PciIo->Pci.Read (\r
+ PciIo,\r
+ EfiPciIoWidthUint32,\r
+ 0,\r
+ sizeof (Pci) / sizeof (UINT32),\r
+ &Pci\r
+ );\r
+ if (EFI_ERROR (Status)) {\r
+ goto Done;\r
+ }\r
+\r
+ if (Pci.Hdr.VendorId == LSI_LOGIC_PCI_VENDOR_ID &&\r
+ (Pci.Hdr.DeviceId == LSI_53C1030_PCI_DEVICE_ID ||\r
+ Pci.Hdr.DeviceId == LSI_SAS1068_PCI_DEVICE_ID ||\r
+ Pci.Hdr.DeviceId == LSI_SAS1068E_PCI_DEVICE_ID)) {\r
+ Status = EFI_SUCCESS;\r
+ } else {\r
+ Status = EFI_UNSUPPORTED;\r
+ }\r
+\r
+Done:\r
+ gBS->CloseProtocol (\r
+ ControllerHandle,\r
+ &gEfiPciIoProtocolGuid,\r
+ This->DriverBindingHandle,\r
+ ControllerHandle\r
+ );\r
+ return Status;\r
}\r
\r
STATIC\r