Skip to content

Commit d16e57b

Browse files
HaihongxLisysopenci
authored andcommitted
Marking External Connector as Internal Connector
To fix issue: The secondary screen resolution we observed doesn’t match that we got in displayinfo when connected 2 or more displays with dGPU PT only mode Because SurfaceFlinger will set density with constant value(213) if CONNECTOR is External. Tracked-On: OAM-131571 Signed-off-by: Li, HaihongX <haihongx.li@intel.com>
1 parent dc6a740 commit d16e57b

File tree

1 file changed

+10
-8
lines changed

1 file changed

+10
-8
lines changed

hwc2_device/HwcDisplay.cpp

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -869,15 +869,17 @@ HWC2::Error HwcDisplay::GetDisplayConnectionType(uint32_t *outType) {
869869
*outType = static_cast<uint32_t>(HWC2::DisplayConnectionType::Internal);
870870
return HWC2::Error::None;
871871
}
872-
/* Primary display should be always internal,
873-
* otherwise SF will be unhappy and will crash
872+
/*
873+
* To fix issue:
874+
* The secondary screen resolution we observed doesn’t match that
875+
* we got in displayinfo when connected 2 or more displays with
876+
* dGPU PT only mode
877+
*
878+
* Because SurfaceFlinger will set density with constant value(213) if CONNECTOR is External.
879+
* So need marking External Connector as Internal Connector.
880+
* In another word, all connectors are Internal.
874881
*/
875-
if (GetPipe().connector->Get()->IsInternal() || handle_ == kPrimaryDisplay)
876-
*outType = static_cast<uint32_t>(HWC2::DisplayConnectionType::Internal);
877-
else if (GetPipe().connector->Get()->IsExternal())
878-
*outType = static_cast<uint32_t>(HWC2::DisplayConnectionType::External);
879-
else
880-
return HWC2::Error::BadConfig;
882+
*outType = static_cast<uint32_t>(HWC2::DisplayConnectionType::Internal);
881883

882884
return HWC2::Error::None;
883885
}

0 commit comments

Comments
 (0)