Signed-off-by: Ari Zigler <ariz@mellanox.com>
Reviewed-by: Ye Ting <ting.ye@intel.com>
Reviewed-by: Fu Siyuan <siyuan.fu@intel.com>
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@14115
6f19259b-4bc3-4df7-8a09-
765794883524
/** @file\r
Implementation of driver entry point and driver binding protocol.\r
\r
/** @file\r
Implementation of driver entry point and driver binding protocol.\r
\r
-Copyright (c) 2004 - 2012, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2004 - 2013, Intel Corporation. All rights reserved.<BR>\r
This program and the accompanying materials are licensed\r
and made available under the terms and conditions of the BSD License which\r
accompanies this distribution. The full text of the license may be found at\r
This program and the accompanying materials are licensed\r
and made available under the terms and conditions of the BSD License which\r
accompanies this distribution. The full text of the license may be found at\r
device to start.\r
\r
@retval EFI_SUCCESS This driver is added to ControllerHandle\r
device to start.\r
\r
@retval EFI_SUCCESS This driver is added to ControllerHandle\r
- @retval EFI_ALREADY_STARTED This driver is already running on ControllerHandle\r
+ @retval EFI_DEVICE_ERROR This driver could not be started due to a device error\r
@retval other This driver does not support this device\r
\r
**/\r
@retval other This driver does not support this device\r
\r
**/\r
- Status = mPciIo->FreeBuffer (\r
- mPciIo,\r
- SNP_MEM_PAGES (4096),\r
- Snp->Cpb\r
- );\r
+ mPciIo->FreeBuffer (\r
+ mPciIo,\r
+ SNP_MEM_PAGES (4096),\r
+ Snp->Cpb\r
+ );\r
+ //\r
+ // If we got here that means we are in error state.\r
+ //\r
+ if (!EFI_ERROR (Status)) {\r
+ Status = EFI_DEVICE_ERROR;\r
+ }\r
+\r