summaryrefslogtreecommitdiff
path: root/IntelFrameworkModulePkg/Csm
diff options
context:
space:
mode:
authorli-elvin <li-elvin@6f19259b-4bc3-4df7-8a09-765794883524>2013-01-22 06:37:06 +0000
committerli-elvin <li-elvin@6f19259b-4bc3-4df7-8a09-765794883524>2013-01-22 06:37:06 +0000
commit7f7dba5c86cddb56e4df9121d08aac53f5b2c78d (patch)
treeb62ddacb77269e349e54eb8d6d0fb8e742aa1dd3 /IntelFrameworkModulePkg/Csm
parent0666b5e858fdbad3275b85b8987dd60f2dffec9f (diff)
downloadedk2-platforms-7f7dba5c86cddb56e4df9121d08aac53f5b2c78d.tar.xz
Take the highest horizontal resolution as highest video resolution.
Signed-off-by: Li Elvin <elvin.li@intel.com> Reviewed-by: Ni Ruiyu <ruiyu.ni@intel.com> Reviewed-by: Tian Hot <hot.tian@intel.com> git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@14075 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'IntelFrameworkModulePkg/Csm')
-rw-r--r--IntelFrameworkModulePkg/Csm/BiosThunk/VideoDxe/BiosVideo.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/IntelFrameworkModulePkg/Csm/BiosThunk/VideoDxe/BiosVideo.c b/IntelFrameworkModulePkg/Csm/BiosThunk/VideoDxe/BiosVideo.c
index f38c968943..fc9672651c 100644
--- a/IntelFrameworkModulePkg/Csm/BiosThunk/VideoDxe/BiosVideo.c
+++ b/IntelFrameworkModulePkg/Csm/BiosThunk/VideoDxe/BiosVideo.c
@@ -1580,6 +1580,9 @@ BiosVideoCheckForVbe (
continue;
}
+ DEBUG ((EFI_D_INFO, "Video Controller Mode 0x%x: %d x %d\n",
+ VbeModeNumber, BiosVideoPrivate->VbeModeInformationBlock->XResolution, BiosVideoPrivate->VbeModeInformationBlock->YResolution));
+
if (EdidFound && (ValidEdidTiming.ValidNumber > 0)) {
//
// EDID exist, check whether this mode match with any mode in EDID
@@ -1623,8 +1626,9 @@ BiosVideoCheckForVbe (
//
// Record the highest resolution mode to set later
//
- if ((BiosVideoPrivate->VbeModeInformationBlock->XResolution >= HighestHorizontalResolution) &&
- (BiosVideoPrivate->VbeModeInformationBlock->YResolution >= HighestVerticalResolution)) {
+ if ((BiosVideoPrivate->VbeModeInformationBlock->XResolution > HighestHorizontalResolution) ||
+ ((BiosVideoPrivate->VbeModeInformationBlock->XResolution == HighestHorizontalResolution) &&
+ (BiosVideoPrivate->VbeModeInformationBlock->YResolution > HighestVerticalResolution))) {
HighestHorizontalResolution = BiosVideoPrivate->VbeModeInformationBlock->XResolution;
HighestVerticalResolution = BiosVideoPrivate->VbeModeInformationBlock->YResolution;
HighestResolutionMode = ModeNumber;