From 65172a08ab202b757f8d418d8a03d4b874c09118 Mon Sep 17 00:00:00 2001 From: Hao Wu Date: Mon, 24 Apr 2017 13:32:04 +0800 Subject: MdeModulePkg/UfsPciHc: Avoid overriding return value in BindingStart In function UfsHcDriverBindingStart(), the return value 'Status' may be overridden during the original PCI attributes restore process. This commit refines the logic to avoid such override. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hao Wu Reviewed-by: Star Zeng (cherry picked from commit 1a5ae661754625b8f4bba39214006e87216747e9) --- Core/MdeModulePkg/Bus/Pci/UfsPciHcDxe/UfsPciHcDxe.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'Core') diff --git a/Core/MdeModulePkg/Bus/Pci/UfsPciHcDxe/UfsPciHcDxe.c b/Core/MdeModulePkg/Bus/Pci/UfsPciHcDxe/UfsPciHcDxe.c index 373e55b4c2..96cf39adc1 100644 --- a/Core/MdeModulePkg/Bus/Pci/UfsPciHcDxe/UfsPciHcDxe.c +++ b/Core/MdeModulePkg/Bus/Pci/UfsPciHcDxe/UfsPciHcDxe.c @@ -671,13 +671,12 @@ Done: // // Restore original PCI attributes // - Status = PciIo->Attributes ( - PciIo, - EfiPciIoAttributeOperationSet, - Private->PciAttributes, - NULL - ); - ASSERT_EFI_ERROR (Status); + PciIo->Attributes ( + PciIo, + EfiPciIoAttributeOperationSet, + Private->PciAttributes, + NULL + ); } gBS->CloseProtocol ( Controller, -- cgit v1.2.3