Skip to content
  • Aaron Plattner's avatar
    modesetting: Use GAMMA_LUT when available · 245b9db0
    Aaron Plattner authored
    
    
    If the kernel exposes GAMMA_LUT and GAMMA_LUT_SIZE properties and the size is
    not what the server has pre-configured for the crtc, free the old gamma ramp
    memory allocated by the server and replace it with new allocations of the
    appropriate size.
    
    In addition, when GAMMA_LUT is available, use drmModeCreatePropertyBlob() and
    drmModeObjectSetProperty() to set the gamma ramp rather than using the legacy
    drmModeCrtcSetGamma() function.
    
    Add a new option "UseGammaLUT" to allow disabling this new behavior and falling
    back to drmModeCrtcSetGamma() unconditionally.
    
    Signed-off-by: Aaron Plattner's avatarAaron Plattner <aplattner@nvidia.com>
    245b9db0