summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2006-11-03 15:55:10 -0800
committerEric Anholt <eric@anholt.net>2006-11-03 16:39:49 -0800
commit27df2ff7908ea7ea2943a5f3445e12dbc24d97c9 (patch)
treea79cc2cf1270e5ed78abafa4ad77f601194ca392
parentecbe73b940b2d642115de4b73c2f757eb46ff956 (diff)
Report pipe status (and status mismatches) in i830DescribeOutputConfiguration()
-rw-r--r--src/i830_display.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/i830_display.c b/src/i830_display.c
index e3db8ad7..e36b5efc 100644
--- a/src/i830_display.c
+++ b/src/i830_display.c
@@ -796,12 +796,32 @@ i830DescribeOutputConfiguration(ScrnInfoPtr pScrn)
for (i = 0; i < pI830->availablePipes; i++) {
CARD32 dspcntr = INREG(DSPACNTR + (DSPBCNTR - DSPACNTR) * i);
+ CARD32 pipeconf = INREG(PIPEACONF + (PIPEBCONF - PIPEACONF) * i);
+ Bool hw_plane_enable = (dspcntr & DISPLAY_PLANE_ENABLE) != 0;
+ Bool hw_pipe_enable = (pipeconf & PIPEACONF_ENABLE) != 0;
xf86DrvMsg(pScrn->scrnIndex, X_INFO,
+ " Pipe %c is %s\n",
+ 'A' + i, pI830->pipes[i].planeEnabled ? "on" : "off");
+ xf86DrvMsg(pScrn->scrnIndex, X_INFO,
" Display plane %c is now %s and connected to pipe %c.\n",
'A' + i,
pI830->pipes[i].planeEnabled ? "enabled" : "disabled",
dspcntr & DISPPLANE_SEL_PIPE_MASK ? 'B' : 'A');
+ if (hw_pipe_enable != pI830->pipes[i].planeEnabled) {
+ xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
+ " Hardware claims pipe %c is %s while software "
+ "believes it is %s\n",
+ 'A' + i, hw_pipe_enable ? "on" : "off",
+ pI830->pipes[i].planeEnabled ? "on" : "off");
+ }
+ if (hw_plane_enable != pI830->pipes[i].planeEnabled) {
+ xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
+ " Hardware claims plane %c is %s while software "
+ "believes it is %s\n",
+ 'A' + i, hw_plane_enable ? "on" : "off",
+ pI830->pipes[i].planeEnabled ? "on" : "off");
+ }
}
for (i = 0; i < pI830->num_outputs; i++) {