public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] backlight: use of_find_backlight_by_node stub when backlight class disabled
@ 2014-10-29  0:20 Heiko Stübner
  2014-10-30  4:44 ` Jingoo Han
  2014-11-03 17:17 ` Lee Jones
  0 siblings, 2 replies; 9+ messages in thread
From: Heiko Stübner @ 2014-10-29  0:20 UTC (permalink / raw)
  To: Jingoo Han, Bryan Wu, Lee Jones; +Cc: linux-kernel

Drivers may want to search for an optional backlight even when the backlight
class is disabled. In this case the linker would miss the function referenced
in the backlight header.

Therefore use the stub function also when the backlight class is disabled.

Signed-off-by: Heiko Stuebner <heiko@sntech.de>
---
 include/linux/backlight.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/linux/backlight.h b/include/linux/backlight.h
index adb14a8..d9cb644 100644
--- a/include/linux/backlight.h
+++ b/include/linux/backlight.h
@@ -157,7 +157,7 @@ struct generic_bl_info {
 	void (*kick_battery)(void);
 };
 
-#ifdef CONFIG_OF
+#if defined(CONFIG_OF) && defined(CONFIG_BACKLIGHT_CLASS_DEVICE)
 struct backlight_device *of_find_backlight_by_node(struct device_node *node);
 #else
 static inline struct backlight_device *
-- 
2.0.1



^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2014-11-10 23:37 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-10-29  0:20 [PATCH] backlight: use of_find_backlight_by_node stub when backlight class disabled Heiko Stübner
2014-10-30  4:44 ` Jingoo Han
2014-11-03 17:17 ` Lee Jones
2014-11-04  9:07   ` Lee Jones
2014-11-04 10:18     ` Jingoo Han
2014-11-04 14:42       ` Lee Jones
2014-11-04 15:02         ` Heiko Stübner
2014-11-04 17:15           ` Lee Jones
2014-11-10 23:41             ` Heiko Stübner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox