mirror of https://github.com/acidanthera/audk.git
MdeModulePkg/AtaBus: AtaBusDxe module would ignore ATA Pass Thru Protocol instances that do not have the LOGICAL attribute set
Signed-off-by: Michael Kinney <michael.d.kinney@intel.com> Reviewed-by: Feng Tian <feng.tian@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com> git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@14284 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
772b601158
commit
8908e764fe
|
@ -4,7 +4,7 @@
|
|||
This file implements protocol interfaces: Driver Binding protocol,
|
||||
Block IO protocol and DiskInfo protocol.
|
||||
|
||||
Copyright (c) 2009 - 2012, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2009 - 2013, Intel Corporation. All rights reserved.<BR>
|
||||
This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions of the BSD License
|
||||
which accompanies this distribution. The full text of the license may be found at
|
||||
|
@ -629,12 +629,37 @@ AtaBusDriverBindingSupported (
|
|||
return Status;
|
||||
}
|
||||
|
||||
//
|
||||
// Test to see if this ATA Pass Thru Protocol is for a LOGICAL channel
|
||||
//
|
||||
if ((AtaPassThru->Mode->Attributes & EFI_ATA_PASS_THRU_ATTRIBUTES_LOGICAL) == 0) {
|
||||
//
|
||||
// Close the I/O Abstraction(s) used to perform the supported test
|
||||
//
|
||||
gBS->CloseProtocol (
|
||||
Controller,
|
||||
&gEfiAtaPassThruProtocolGuid,
|
||||
This->DriverBindingHandle,
|
||||
Controller
|
||||
);
|
||||
return EFI_UNSUPPORTED;
|
||||
}
|
||||
|
||||
//
|
||||
// Test RemainingDevicePath is valid or not.
|
||||
//
|
||||
if ((RemainingDevicePath != NULL) && !IsDevicePathEnd (RemainingDevicePath)) {
|
||||
Status = AtaPassThru->GetDevice (AtaPassThru, RemainingDevicePath, &Port, &PortMultiplierPort);
|
||||
if (EFI_ERROR (Status)) {
|
||||
//
|
||||
// Close the I/O Abstraction(s) used to perform the supported test
|
||||
//
|
||||
gBS->CloseProtocol (
|
||||
Controller,
|
||||
&gEfiAtaPassThruProtocolGuid,
|
||||
This->DriverBindingHandle,
|
||||
Controller
|
||||
);
|
||||
return Status;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue