intel-gfx.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] drm: Add support for EDID injection.
@ 2016-03-23 17:06 Marius Vlad
  2016-03-24  8:02 ` ✗ Fi.CI.BAT: warning for " Patchwork
  0 siblings, 1 reply; 2+ messages in thread
From: Marius Vlad @ 2016-03-23 17:06 UTC (permalink / raw)
  To: dri-devel, intel-gfx

Allow the possibility to return an copy of the injected EDID when the connector
has been forced and an EDID has been specified over the debugfs interface.

Signed-off-by: Marius Vlad <marius.c.vlad@intel.com>
---
 drivers/gpu/drm/drm_edid.c | 23 ++++++++++++++++++++---
 1 file changed, 20 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/drm_edid.c b/drivers/gpu/drm/drm_edid.c
index 414d7f6..239f9b1 100644
--- a/drivers/gpu/drm/drm_edid.c
+++ b/drivers/gpu/drm/drm_edid.c
@@ -1075,6 +1075,19 @@ static bool drm_edid_is_zero(const u8 *in_edid, int length)
 	return true;
 }
 
+static struct edid *
+drm_do_get_override_edid(struct drm_connector *connector)
+{
+	struct edid *edid = NULL;
+
+	if (connector->override_edid && connector->edid_blob_ptr->data) {
+		edid = kmemdup(connector->edid_blob_ptr->data,
+			       connector->edid_blob_ptr->length, GFP_KERNEL);
+	}
+
+	return edid;
+}
+
 /**
  * drm_edid_block_valid - Sanity check the EDID block (base or extension)
  * @raw_edid: pointer to raw EDID block
@@ -1385,10 +1398,14 @@ struct edid *drm_get_edid(struct drm_connector *connector,
 {
 	struct edid *edid;
 
-	if (!drm_probe_ddc(adapter))
-		return NULL;
+	if (!connector->override_edid) {
+		if (!drm_probe_ddc(adapter))
+			return NULL;
+		edid = drm_do_get_edid(connector, drm_do_probe_ddc_edid, adapter);
+	} else {
+		edid = drm_do_get_override_edid(connector);
+	}
 
-	edid = drm_do_get_edid(connector, drm_do_probe_ddc_edid, adapter);
 	if (edid)
 		drm_get_displayid(connector, edid);
 	return edid;
-- 
2.5.0

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* ✗ Fi.CI.BAT: warning for drm: Add support for EDID injection.
  2016-03-23 17:06 [PATCH] drm: Add support for EDID injection Marius Vlad
@ 2016-03-24  8:02 ` Patchwork
  0 siblings, 0 replies; 2+ messages in thread
From: Patchwork @ 2016-03-24  8:02 UTC (permalink / raw)
  To: marius vlad; +Cc: intel-gfx

== Series Details ==

Series: drm: Add support for EDID injection.
URL   : https://patchwork.freedesktop.org/series/4818/
State : warning

== Summary ==

Series 4818v1 drm: Add support for EDID injection.
http://patchwork.freedesktop.org/api/1.0/series/4818/revisions/1/mbox/

Test kms_flip:
        Subgroup basic-flip-vs-modeset:
                pass       -> DMESG-WARN (ilk-hp8440p) UNSTABLE
Test kms_pipe_crc_basic:
        Subgroup suspend-read-crc-pipe-c:
                dmesg-warn -> PASS       (bsw-nuc-2)
                pass       -> SKIP       (hsw-gt2)
Test pm_rpm:
        Subgroup basic-pci-d3-state:
                dmesg-warn -> PASS       (bsw-nuc-2)
                pass       -> DMESG-WARN (byt-nuc)
        Subgroup basic-rte:
                dmesg-warn -> PASS       (byt-nuc) UNSTABLE

bdw-nuci7        total:192  pass:180  dwarn:0   dfail:0   fail:0   skip:12 
bdw-ultra        total:192  pass:171  dwarn:0   dfail:0   fail:0   skip:21 
bsw-nuc-2        total:192  pass:155  dwarn:0   dfail:0   fail:0   skip:37 
byt-nuc          total:192  pass:156  dwarn:1   dfail:0   fail:0   skip:35 
hsw-brixbox      total:192  pass:170  dwarn:0   dfail:0   fail:0   skip:22 
hsw-gt2          total:192  pass:174  dwarn:0   dfail:0   fail:0   skip:18 
ilk-hp8440p      total:192  pass:128  dwarn:1   dfail:0   fail:0   skip:63 
ivb-t430s        total:192  pass:167  dwarn:0   dfail:0   fail:0   skip:25 
skl-i7k-2        total:192  pass:169  dwarn:0   dfail:0   fail:0   skip:23 
snb-dellxps      total:192  pass:158  dwarn:0   dfail:0   fail:0   skip:34 
snb-x220t        total:192  pass:158  dwarn:0   dfail:0   fail:1   skip:33 

Results at /archive/results/CI_IGT_test/Patchwork_1697/

8f2e9bbc15607f56261aefd7a1f8caf6909c6b9d drm-intel-nightly: 2016y-03m-23d-17h-03m-10s UTC integration manifest
e0174c7b8c92e7b71b0db41fe86e6c91f5843486 drm: Add support for EDID injection.

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-03-24  8:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-03-23 17:06 [PATCH] drm: Add support for EDID injection Marius Vlad
2016-03-24  8:02 ` ✗ Fi.CI.BAT: warning for " Patchwork

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).