On 30/10/17 01:26 PM, Yu, Qiang wrote: > >>> Or maybe it's better to enlarge the crtc gamma size according to randr crtc >>> and let kernel driver to do the resize fit. >> >> Yes, that needs to happen anyway to make the display hardware actually >> take advantage of 30 bits per pixel, doesn't it? > But for randr crtc gamma size < 256, I see you don't shrink the crtc gamma > size. Any reason?
There has traditionally been an assumption that the gamma CLUT has 256 entries. I didn't change anything about that. It also works at depth 15/16, even though in that case the hardware only actually uses a fraction of the ramp's entries. >>> But I see driver like amdgpu with old KMS driver only has 256 entries and >>> the >>> gamma set syscall won't work correctly for size>256. >> >> That needs to be fixed then, and the userspace driver should probably >> only allow setting depth 30 when it knows the kernel driver can handle it. > That's the DDX work. For amdgpu, seems we can support it in DC KMS. Right, let's handle this in the driver, and drop this patch. -- Earthling Michel Dänzer | http://www.amd.com Libre software enthusiast | Mesa and X developer _______________________________________________ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: https://lists.x.org/mailman/listinfo/xorg-devel