summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/gma500/opregion.c
diff options
context:
space:
mode:
authorMasahiro Yamada <yamada.masahiro@socionext.com>2016-08-23 18:42:54 +0200
committerDaniel Vetter <daniel.vetter@ffwll.ch>2016-08-24 07:43:42 +0200
commitb7a0c7c5ba289a7d063d92c162b53e110757e331 (patch)
treed6d115942e3f7fb4af9be3808d9a08f26862c7a1 /drivers/gpu/drm/gma500/opregion.c
parentdrm/doc: Document uapi requirements in DRM (diff)
downloadlinux-b7a0c7c5ba289a7d063d92c162b53e110757e331.tar.xz
linux-b7a0c7c5ba289a7d063d92c162b53e110757e331.zip
drm/gma500: remove unnecessary config_enabled() guard
Commit d112a8163f83 ("gma500/cdv: Add eDP support") replaced the code inside this if-conditional with gma_backlight_set(), which becomes a nop stub if CONFIG_BACKLIGHT_CLASS_DEVICE is disabled. So, there is no need to guard the caller with config_enabled(). Note: This is one of remaining TODOs to deprecate config_enabled() macro. Refer to commit 97f2645f358b ("tree-wide: replace config_enabled() with IS_ENABLED()"). Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1471970574-23906-1-git-send-email-yamada.masahiro@socionext.com
Diffstat (limited to 'drivers/gpu/drm/gma500/opregion.c')
-rw-r--r--drivers/gpu/drm/gma500/opregion.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/gpu/drm/gma500/opregion.c b/drivers/gpu/drm/gma500/opregion.c
index ab696ca7eeec..eab6d889bde9 100644
--- a/drivers/gpu/drm/gma500/opregion.c
+++ b/drivers/gpu/drm/gma500/opregion.c
@@ -163,10 +163,7 @@ static u32 asle_set_backlight(struct drm_device *dev, u32 bclp)
if (bclp > 255)
return ASLE_BACKLIGHT_FAILED;
- if (config_enabled(CONFIG_BACKLIGHT_CLASS_DEVICE)) {
- int max = bd->props.max_brightness;
- gma_backlight_set(dev, bclp * max / 255);
- }
+ gma_backlight_set(dev, bclp * bd->props.max_brightness / 255);
asle->cblv = (bclp * 0x64) / 0xff | ASLE_CBLV_VALID;