Commit c6cb1b19 authored by Chris Wilson's avatar Chris Wilson 🤔

sna: Squelch compiler warning for unused var

sna_display.c: In function ‘crtc_init_gamma’:
sna_display.c:7462:28: warning: unused variable ‘lut’ [-Wunused-variable]
sna_display.c:7444:14: warning: unused variable ‘sna’ [-Wunused-variable]
Signed-off-by: Chris Wilson's avatarChris Wilson <chris@chris-wilson.co.uk>
parent 581ddc5d
......@@ -7441,7 +7441,6 @@ static bool crtc_get_gamma_legacy(xf86CrtcPtr crtc,
static void crtc_init_gamma(xf86CrtcPtr crtc)
{
struct sna *sna = to_sna(crtc->scrn);
struct sna_crtc *sna_crtc = to_sna_crtc(crtc);
uint16_t *gamma;
int size;
......@@ -7459,11 +7458,10 @@ static void crtc_init_gamma(xf86CrtcPtr crtc)
if (gamma == NULL)
gamma = malloc(3 * size * sizeof(uint16_t));
if (gamma) {
struct drm_mode_crtc_lut lut;
bool gamma_set;
uint16_t *red = gamma;
uint16_t *green = gamma + size;
uint16_t *blue = gamma + 2 * size;
bool gamma_set;
if (sna_crtc->gamma_lut_size)
gamma_set = crtc_get_gamma_lut(crtc, red,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment