From 45df8dd096fd13be5f19b6f123f63f98cc38d3e4 Mon Sep 17 00:00:00 2001 From: Kevin Brace Date: Sat, 23 Jan 2016 06:02:20 -0600 Subject: [PATCH 09/10] General improvement of via_dp_detect function Added debug messages to via_dp_detect function inside via_outputs.c in order to aid the debugging effort. Made small adjustments to better handle error conditions as well. --- src/via_outputs.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/via_outputs.c b/src/via_outputs.c index d5169a2..52bbaeb 100644 --- a/src/via_outputs.c +++ b/src/via_outputs.c @@ -622,13 +622,20 @@ via_dp_detect(xf86OutputPtr output) VIAPtr pVia = VIAPTR(pScrn); xf86MonPtr mon; + DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO, "Entered via_dp_detect.\n")); + xf86DrvMsg(pScrn->scrnIndex, X_PROBED, + "Probing for a DP.\n"); mon = xf86OutputGetEDID(output, pVia->pI2CBus2); if (mon && DIGITAL(mon->features.input_type)) { xf86OutputSetEDID(output, mon); - DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_PROBED, - "DDC pI2CBus2 detected a DP\n")); + xf86DrvMsg(pScrn->scrnIndex, X_PROBED, + "I2C Bus 2 detected a DP.\n"); status = XF86OutputStatusConnected; + } else { + xf86DrvMsg(pScrn->scrnIndex, X_PROBED, + "Did not detect a DP.\n"); } + DEBUG(xf86DrvMsg(pScrn->scrnIndex, X_INFO, "Exiting via_dp_detect.\n")); return status; } -- 1.7.9.5