Problem seems to be to be commented out option xf86HandleColormaps.
Bool drmmode_setup_colormap(ScreenPtr pScreen, ScrnInfoPtr pScrn) { xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, RADEON_LOGLEVEL_DEBUG, "Initializing kms color map\n"); if (!miCreateDefColormap(pScreen)) return FALSE; /* all radeons support 10 bit CLUTs */ if (!xf86HandleColormaps(pScreen, 256, 10, drmmode_load_palette, NULL, CMAP_PALETTED_TRUECOLOR #if 0 /* This option messes up text mode! (<email address hidden>) */ | CMAP_LOAD_EVEN_IF_OFFSCREEN #endif | CMAP_RELOAD_ON_MODE_SWITCH)) return FALSE; return TRUE; }
If I enable the disabled option lut is restored correctly when switching back from VT.
But there is still problem that lut is not restored when switching away from xserver. So this is not correct fix to the problem.
Problem seems to be to be commented out option xf86HandleColor maps.
Bool drmmode_ setup_colormap( ScreenPtr pScreen, ScrnInfoPtr pScrn) erb(pScrn- >scrnIndex, X_INFO, RADEON_ LOGLEVEL_ DEBUG,
"Initializi ng kms color map\n"); lormap( pScreen) ) ormaps( pScreen, 256, 10,
drmmode_ load_palette, NULL,
CMAP_PALETTED_ TRUECOLOR
| CMAP_LOAD_ EVEN_IF_ OFFSCREEN
| CMAP_RELOAD_ ON_MODE_ SWITCH) )
{
xf86DrvMsgV
if (!miCreateDefCo
return FALSE;
/* all radeons support 10 bit CLUTs */
if (!xf86HandleCol
#if 0 /* This option messes up text mode! (<email address hidden>) */
#endif
return FALSE;
return TRUE;
}
If I enable the disabled option lut is restored correctly when
switching back from VT.
But there is still problem that lut is not restored when switching
away from xserver. So this is not correct fix to the problem.