From: Jani Nikula Date: Wed, 18 Sep 2013 14:19:45 +0000 (+0300) Subject: drm/i915: register backlight device also when backlight class is a module X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=912e8b12eedb41c69717deda2b2a08e7292945fc;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git drm/i915: register backlight device also when backlight class is a module Ville and I were wondering why his laptop was missing the intel_backlight sysfs interface. Turns out we never register it when CONFIG_BACKLIGHT_CLASS_DEVICE=m. This has been broken ever since the i915 native backlight interface was added. CC: Ville Syrjälä Signed-off-by: Jani Nikula Reviewed-by: Damien Lespiau Signed-off-by: Daniel Vetter --- diff --git a/drivers/gpu/drm/i915/intel_panel.c b/drivers/gpu/drm/i915/intel_panel.c index e36149d578fa..0aaeb8b6d6ed 100644 --- a/drivers/gpu/drm/i915/intel_panel.c +++ b/drivers/gpu/drm/i915/intel_panel.c @@ -658,7 +658,7 @@ intel_panel_detect(struct drm_device *dev) } } -#ifdef CONFIG_BACKLIGHT_CLASS_DEVICE +#if IS_ENABLED(CONFIG_BACKLIGHT_CLASS_DEVICE) static int intel_panel_update_status(struct backlight_device *bd) { struct drm_device *dev = bl_get_data(bd);