summaryrefslogtreecommitdiff
path: root/src/smi501_crtc.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/smi501_crtc.c')
-rw-r--r--src/smi501_crtc.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/smi501_crtc.c b/src/smi501_crtc.c
index 54152fc..3fc0912 100644
--- a/src/smi501_crtc.c
+++ b/src/smi501_crtc.c
@@ -65,8 +65,7 @@ SMI501_CrtcVideoInit_lcd(xf86CrtcPtr crtc)
mode->panel_fb_width.f.offset = pitch >> 4;
mode->panel_fb_width.f.width = width >> 4;
- if (pSmi->Bpp > 1)
- mode->panel_display_ctl.f.gamma = 1;
+ mode->panel_display_ctl.f.gamma = pSmi->Bpp > 1;
WRITE_SCR(pSmi, PANEL_DISPLAY_CTL, mode->panel_display_ctl.value);
WRITE_SCR(pSmi, PANEL_FB_WIDTH, mode->panel_fb_width.value);
@@ -100,8 +99,7 @@ SMI501_CrtcVideoInit_crt(xf86CrtcPtr crtc)
mode->crt_fb_width.f.offset = pitch >> 4;
mode->crt_fb_width.f.width = width >> 4;
- if (pSmi->Bpp > 1)
- mode->crt_display_ctl.f.gamma = 1;
+ mode->crt_display_ctl.f.gamma = pSmi->Bpp > 1;
WRITE_SCR(pSmi, CRT_DISPLAY_CTL, mode->crt_display_ctl.value);
WRITE_SCR(pSmi, CRT_FB_WIDTH, mode->crt_fb_width.value);