xf86-video-intel: src/i810_reg.h src/i830_driver.c

Alan Hourihane alanh at kemper.freedesktop.org
Tue Aug 29 06:54:34 PDT 2006


 src/i810_reg.h    |   11 +++++------
 src/i830_driver.c |   22 ++++++++++------------
 2 files changed, 15 insertions(+), 18 deletions(-)

New commits:
diff-tree 1feb733eb8b09a8b07b7a6987add5149c53b0157 (from 26e6c074c17b2d4e9b9f165468ad45a3b0ecc0ef)
Author: Alan Hourihane <alanh at fairlite.demon.co.uk>
Date:   Tue Aug 29 14:54:15 2006 +0100

    Fix bug with probing info of DFP2 and LFP2 connected
    devices (Aaron Ridout)

diff --git a/src/i810_reg.h b/src/i810_reg.h
index 05710c4..4bb5bf1 100644
--- a/src/i810_reg.h
+++ b/src/i810_reg.h
@@ -1238,12 +1238,11 @@ typedef enum {
    TvIndex,
    DfpIndex,
    LfpIndex,
+   Crt2Index,
    Tv2Index,
    Dfp2Index,
-   UnknownIndex,
-   Unknown2Index,
-   NumDisplayTypes,
-   NumKnownDisplayTypes = UnknownIndex
+   Lfp2Index,
+   NumDisplayTypes
 } DisplayType;
 
 /* What's connected to the pipes (as reported by the BIOS) */
@@ -1252,10 +1251,10 @@ typedef enum {
 #define PIPE_TV_ACTIVE			(1 << TvIndex)
 #define PIPE_DFP_ACTIVE			(1 << DfpIndex)
 #define PIPE_LCD_ACTIVE			(1 << LfpIndex)
+#define PIPE_CRT2_ACTIVE		(1 << Crt2Index)
 #define PIPE_TV2_ACTIVE			(1 << Tv2Index)
 #define PIPE_DFP2_ACTIVE		(1 << Dfp2Index)
-#define PIPE_UNKNOWN_ACTIVE		((1 << UnknownIndex) |	\
-					 (1 << Unknown2Index))
+#define PIPE_LCD2_ACTIVE		(1 << Lfp2Index)
 
 #define PIPE_SIZED_DISP_MASK		(PIPE_DFP_ACTIVE |	\
 					 PIPE_LCD_ACTIVE |	\
diff --git a/src/i830_driver.c b/src/i830_driver.c
index cebb379..a05fb17 100644
--- a/src/i830_driver.c
+++ b/src/i830_driver.c
@@ -2852,12 +2852,14 @@ GetDisplayInfo(ScrnInfoPtr pScrn, int de
    DPRINTF(PFX, "GetDisplayInfo: device: 0x%x\n", device);
 
    switch (device & 0xff) {
-   case 0x01:
-   case 0x02:
-   case 0x04:
-   case 0x08:
-   case 0x10:
-   case 0x20:
+   case PIPE_CRT:
+   case PIPE_TV:
+   case PIPE_DFP:
+   case PIPE_LFP:
+   case PIPE_CRT2:
+   case PIPE_TV2:
+   case PIPE_DFP2:
+   case PIPE_LFP2:
       break;
    default:
       xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
@@ -2964,10 +2966,6 @@ PrintDisplayDeviceInfo(ScrnInfoPtr pScrn
 	    name = DeviceToString(-1);
 	 } while (name);
 
-	 if (pipe & PIPE_UNKNOWN_ACTIVE)
-	    xf86DrvMsg(pScrn->scrnIndex, X_INFO,
-		       "\tSome unknown display devices may also be present\n");
-
       } else {
 	 xf86DrvMsg(pScrn->scrnIndex, X_INFO,
 		    "No active displays on Pipe %c.\n", PIPE_NAME(n));
@@ -3000,7 +2998,7 @@ GetPipeSizes(ScrnInfoPtr pScrn)
       pipe = (pI830->operatingDevices >> PIPE_SHIFT(n)) & PIPE_ACTIVE_MASK;
       pI830->pipeDisplaySize[n].x1 = pI830->pipeDisplaySize[n].y1 = 0;
       pI830->pipeDisplaySize[n].x2 = pI830->pipeDisplaySize[n].y2 = 4096;
-      for (i = 0; i < NumKnownDisplayTypes; i++) {
+      for (i = 0; i < NumDisplayTypes; i++) {
          if (pipe & (1 << i) & PIPE_SIZED_DISP_MASK) {
 	    if (pI830->displaySize[i].x2 != 0) {
 	       xf86DrvMsg(pScrn->scrnIndex, X_INFO,
@@ -3037,7 +3035,7 @@ I830DetectDisplayDevice(ScrnInfoPtr pScr
 		  "\t      If you encounter this problem please add \n"
 		  "\t\t Option \"DisplayInfo\" \"FALSE\"\n"
 		  "\t      to the Device section of your XF86Config file.\n");
-      for (i = 0; i < NumKnownDisplayTypes; i++) {
+      for (i = 0; i < NumDisplayTypes; i++) {
          if (GetDisplayInfo(pScrn, 1 << i, &pI830->displayAttached[i],
 			 &pI830->displayPresent[i],
 			 &pI830->displaySize[i].x2,



More information about the xorg-commit mailing list