• Mario Kleiner's avatar
    drm/amd/display: Enable support for 16 bpc fixed-point framebuffers. · 58020403
    Mario Kleiner authored
    This is intended to enable direct high-precision scanout and pageflip
    of Vulkan swapchain images in format VK_FORMAT_R16G16B16A16_UNORM.
    
    Expose DRM_FORMAT_XRGB16161616, DRM_FORMAT_ARGB16161616,
    DRM_FORMAT_XBGR16161616 and DRM_FORMAT_ABGR16161616 as 16 bpc
    unsigned normalized formats. These allow to take full advantage
    of the maximum precision of the display hardware, ie. currently
    up to 12 bpc.
    
    Searching through old AMD M56, M76 and RV630 hw programming docs
    suggests that these 16 bpc formats are supported by all DCE and
    DCN display engines, so we can expose the formats unconditionally.
    
    Successfully tested on AMD Polaris11 DCE-11.2 an RavenRidge DCN-1.0
    with a HDR-10 monitor over 10 bpc DP output with spatial dithering
    enabled by the driver. Picture looks good, and my photometer
    measurement procedure confirms an effective 12 bpc color
    reproduction.
    Signed-off-by: default avatarMario Kleiner <mario.kleiner.de@gmail.com>
    Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
    58020403
amdgpu_dm.c 310 KB