diff --git a/hw/xfree86/ddc/edid.h b/hw/xfree86/ddc/edid.h index 198794eaa..2496e19e6 100644 --- a/hw/xfree86/ddc/edid.h +++ b/hw/xfree86/ddc/edid.h @@ -326,11 +326,15 @@ #define DPMS_SUSPEND(x) (x & 0x02) #define DPMS_OFF(x) (x & 0x01) -/* display type */ +/* display type, analog */ #define DISP_MONO 0 #define DISP_RGB 1 #define DISP_MULTCOLOR 2 +/* display color encodings, digital */ +#define DISP_YCRCB444 0x01 +#define DISP_YCRCB422 0x02 + /* Msc stuff EDID Ver > 1.1 */ #define STD_COLOR_SPACE(x) (x & 0x4) #define PREFERRED_TIMING_MODE(x) (x & 0x2) diff --git a/hw/xfree86/ddc/print_edid.c b/hw/xfree86/ddc/print_edid.c index 880ca073c..30cd17588 100644 --- a/hw/xfree86/ddc/print_edid.c +++ b/hw/xfree86/ddc/print_edid.c @@ -128,20 +128,29 @@ print_dpms_features(int scrnIndex, struct disp_features *c, if (DPMS_OFF(c->dpms)) xf86ErrorF(" Off"); } else xf86DrvMsg(scrnIndex,X_INFO,"No DPMS capabilities specified"); - switch (c->display_type){ - case DISP_MONO: - xf86ErrorF("; Monochorome/GrayScale Display\n"); - break; - case DISP_RGB: - xf86ErrorF("; RGB/Color Display\n"); - break; - case DISP_MULTCOLOR: - xf86ErrorF("; Non RGB Multicolor Display\n"); - break; - default: - xf86ErrorF("\n"); - break; + if (!c->input_type) { /* analog */ + switch (c->display_type){ + case DISP_MONO: + xf86ErrorF("; Monochorome/GrayScale Display\n"); + break; + case DISP_RGB: + xf86ErrorF("; RGB/Color Display\n"); + break; + case DISP_MULTCOLOR: + xf86ErrorF("; Non RGB Multicolor Display\n"); + break; + default: + xf86ErrorF("\n"); + break; + } + } else { + int enc = c->display_type; + xf86DrvMsg(scrnIndex, X_INFO, "\nSupported color encodings: " + "RGB 4:4:4 %s%s\n", + enc & DISP_YCRCB444 ? "YCrCb 4:4:4 " : "", + enc & DISP_YCRCB422 ? "YCrCb 4:2:2" : ""); } + if (STD_COLOR_SPACE(c->msc)) xf86DrvMsg(scrnIndex,X_INFO, "Default color space is primary color space\n");