summaryrefslogtreecommitdiff
path: root/IntelFrameworkModulePkg
diff options
context:
space:
mode:
authorli-elvin <li-elvin@6f19259b-4bc3-4df7-8a09-765794883524>2011-09-26 06:01:07 +0000
committerli-elvin <li-elvin@6f19259b-4bc3-4df7-8a09-765794883524>2011-09-26 06:01:07 +0000
commita1f7e1e34fb3341a9e28a5bf9cb04ee64bff1869 (patch)
tree57b43314cdf634de685663149d5163d83c07ce01 /IntelFrameworkModulePkg
parent9703e347292551a3bb79d4da9284b081041cbf4d (diff)
downloadedk2-platforms-a1f7e1e34fb3341a9e28a5bf9cb04ee64bff1869.tar.xz
The ParentDevicePath is not initialized when error happened and went to Done. So the ParentDevicePath is moved to the beginning of Start ().
Signed-off-by: li-elvin Reviewed-by: niruiyu, rsun3 git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12441 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'IntelFrameworkModulePkg')
-rw-r--r--IntelFrameworkModulePkg/Csm/BiosThunk/VideoDxe/BiosVideo.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/IntelFrameworkModulePkg/Csm/BiosThunk/VideoDxe/BiosVideo.c b/IntelFrameworkModulePkg/Csm/BiosThunk/VideoDxe/BiosVideo.c
index f2ad95d9fc..bb05ecb191 100644
--- a/IntelFrameworkModulePkg/Csm/BiosThunk/VideoDxe/BiosVideo.c
+++ b/IntelFrameworkModulePkg/Csm/BiosThunk/VideoDxe/BiosVideo.c
@@ -269,6 +269,18 @@ BiosVideoDriverBindingStart (
return Status;
}
+ //
+ // Prepare for status code
+ //
+ Status = gBS->HandleProtocol (
+ Controller,
+ &gEfiDevicePathProtocolGuid,
+ (VOID **) &ParentDevicePath
+ );
+ if (EFI_ERROR (Status)) {
+ return Status;
+ }
+
PciAttributesSaved = FALSE;
//
// Save original PCI attributes
@@ -304,18 +316,6 @@ BiosVideoDriverBindingStart (
goto Done;
}
- //
- // Prepare for status code
- //
- Status = gBS->HandleProtocol (
- Controller,
- &gEfiDevicePathProtocolGuid,
- (VOID **) &ParentDevicePath
- );
- if (EFI_ERROR (Status)) {
- goto Done;
- }
-
REPORT_STATUS_CODE_WITH_DEVICE_PATH (
EFI_PROGRESS_CODE,
EFI_PERIPHERAL_LOCAL_CONSOLE | EFI_P_PC_ENABLE,