aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMario Kleiner <mario.kleiner.de@gmail.com>2017-04-21 11:05:08 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2017-05-25 09:44:48 -0400
commit5438f89529065a936f31803e263adfd843f09bf8 (patch)
treef0ac7d932a2e3d30ee26c3d17fa8808eaf26c0f2
parent5956b2815f90e0749d98ea0baedc49b1792f598b (diff)
drm/edid: Add 10 bpc quirk for LGD 764 panel in HP zBook 17 G2
commit e345da82bd6bdfa8492f80b3ce4370acfd868d95 upstream. The builtin eDP panel in the HP zBook 17 G2 supports 10 bpc, as advertised by the Laptops product specs and verified via injecting a fixed edid + photometer measurements, but edid reports unknown depth, so drivers fall back to 6 bpc. Add a quirk to get the full 10 bpc. Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com> Acked-by: Harry Wentland <harry.wentland@amd.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1492787108-23959-1-git-send-email-mario.kleiner.de@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/gpu/drm/drm_edid.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/gpu/drm/drm_edid.c b/drivers/gpu/drm/drm_edid.c
index 0bc0afb6321e..0151ed2de770 100644
--- a/drivers/gpu/drm/drm_edid.c
+++ b/drivers/gpu/drm/drm_edid.c
@@ -76,6 +76,8 @@
76#define EDID_QUIRK_FORCE_12BPC (1 << 9) 76#define EDID_QUIRK_FORCE_12BPC (1 << 9)
77/* Force 6bpc */ 77/* Force 6bpc */
78#define EDID_QUIRK_FORCE_6BPC (1 << 10) 78#define EDID_QUIRK_FORCE_6BPC (1 << 10)
79/* Force 10bpc */
80#define EDID_QUIRK_FORCE_10BPC (1 << 11)
79 81
80struct detailed_mode_closure { 82struct detailed_mode_closure {
81 struct drm_connector *connector; 83 struct drm_connector *connector;
@@ -118,6 +120,9 @@ static const struct edid_quirk {
118 { "FCM", 13600, EDID_QUIRK_PREFER_LARGE_75 | 120 { "FCM", 13600, EDID_QUIRK_PREFER_LARGE_75 |
119 EDID_QUIRK_DETAILED_IN_CM }, 121 EDID_QUIRK_DETAILED_IN_CM },
120 122
123 /* LGD panel of HP zBook 17 G2, eDP 10 bpc, but reports unknown bpc */
124 { "LGD", 764, EDID_QUIRK_FORCE_10BPC },
125
121 /* LG Philips LCD LP154W01-A5 */ 126 /* LG Philips LCD LP154W01-A5 */
122 { "LPL", 0, EDID_QUIRK_DETAILED_USE_MAXIMUM_SIZE }, 127 { "LPL", 0, EDID_QUIRK_DETAILED_USE_MAXIMUM_SIZE },
123 { "LPL", 0x2a00, EDID_QUIRK_DETAILED_USE_MAXIMUM_SIZE }, 128 { "LPL", 0x2a00, EDID_QUIRK_DETAILED_USE_MAXIMUM_SIZE },
@@ -4105,6 +4110,9 @@ int drm_add_edid_modes(struct drm_connector *connector, struct edid *edid)
4105 if (quirks & EDID_QUIRK_FORCE_8BPC) 4110 if (quirks & EDID_QUIRK_FORCE_8BPC)
4106 connector->display_info.bpc = 8; 4111 connector->display_info.bpc = 8;
4107 4112
4113 if (quirks & EDID_QUIRK_FORCE_10BPC)
4114 connector->display_info.bpc = 10;
4115
4108 if (quirks & EDID_QUIRK_FORCE_12BPC) 4116 if (quirks & EDID_QUIRK_FORCE_12BPC)
4109 connector->display_info.bpc = 12; 4117 connector->display_info.bpc = 12;
4110 4118