OSDN Git Service

drm/nouveau: Enable stereoscopic 3D output over HDMI
authorAlastair Bridgewater <alastair.bridgewater@gmail.com>
Tue, 11 Apr 2017 17:11:25 +0000 (13:11 -0400)
committerBen Skeggs <bskeggs@redhat.com>
Fri, 16 Jun 2017 04:04:19 +0000 (14:04 +1000)
Enable stereoscopic output for HDMI and DisplayPort connectors on
NV50+ (G80+) hardware.  We do not enable stereoscopy on older
hardware in case there is some older board that still has HDMI
output but for which we have no logic for setting the Vendor
InfoFrame.

With this, I get an obvious 3D output when using the "testdisplay"
program from intel-gpu-tools with the "-3" parameter and outputting
to a 3D-capable HDMI display, for all available 3D modes (be they
TB, SBSH, or FP) on all four G80+ DISPs.

Signed-off-by: Alastair Bridgewater <alastair.bridgewater@gmail.com>
drivers/gpu/drm/nouveau/nouveau_connector.c

index 9a91e79..147b221 100644 (file)
@@ -1324,6 +1324,13 @@ nouveau_connector_create(struct drm_device *dev, int index)
                break;
        }
 
+       /* HDMI 3D support */
+       if ((disp->disp.oclass >= G82_DISP)
+           && ((type == DRM_MODE_CONNECTOR_DisplayPort)
+               || (type == DRM_MODE_CONNECTOR_eDP)
+               || (type == DRM_MODE_CONNECTOR_HDMIA)))
+               connector->stereo_allowed = true;
+
        /* defaults, will get overridden in detect() */
        connector->interlace_allowed = false;
        connector->doublescan_allowed = false;