[OpenWrt-Devel] [OpenWrt-devel] [PATCH v3 2/4] kernel: add backlight kernel module support

Tim Harvey tharvey at gateworks.com
Tue Dec 29 18:07:27 EST 2015


Signed-off-by: Tim Harvey <tharvey at gateworks.com>
---
v3:
- added support for Linux 4.3 (new driver needs to be disabled by default)
v2:
- no changes

Signed-off-by: Tim Harvey <tharvey at gateworks.com>
---
 package/kernel/linux/modules/backlight.mk | 49 +++++++++++++++++++++++++++++++
 1 file changed, 49 insertions(+)
 create mode 100644 package/kernel/linux/modules/backlight.mk

diff --git a/package/kernel/linux/modules/backlight.mk b/package/kernel/linux/modules/backlight.mk
new file mode 100644
index 0000000..62aedaa
--- /dev/null
+++ b/package/kernel/linux/modules/backlight.mk
@@ -0,0 +1,49 @@
+#
+# Copyright (C) 2015 OpenWrt.org
+#
+# This is free software, licensed under the GNU General Public License v2.
+# See /LICENSE for more information.
+#
+
+BACKLIGHT_MENU:=Video Support
+
+define KernelPackage/backlight
+	SUBMENU:=$(BACKLIGHT_MENU)
+	TITLE:=Backlight support
+	KCONFIG:=CONFIG_BACKLIGHT_CLASS_DEVICE=m \
+		CONFIG_BACKLIGHT_LCD_SUPPORT=y \
+		CONFIG_LCD_CLASS_DEVICE=n \
+		CONFIG_BACKLIGHT_PWM=n \
+		CONFIG_BACKLIGHT_GENERIC=n \
+		CONFIG_BACKLIGHT_ADP8860=n \
+		CONFIG_BACKLIGHT_ADP8870=n \
+		CONFIG_BACKLIGHT_PM8941_WLED=n
+	FILES:=$(LINUX_DIR)/drivers/video/backlight/backlight.ko
+	AUTOLOAD:=$(call AutoProbe,video backlight)
+endef
+
+define KernelPackage/backlight/description
+	Kernel module for Backlight support.
+endef
+
+$(eval $(call KernelPackage,backlight))
+
+define AddDepends/backlight
+	SUBMENU:=$(BACKLIGHT_MENU)
+	DEPENDS+=kmod-backlight $(1)
+endef
+
+define KernelPackage/backlight-pwm
+	TITLE:=PWM Backlight support
+	DEPENDS:=+kmod-pwm
+	KCONFIG:=CONFIG_BACKLIGHT_PWM=m
+	FILES:=$(LINUX_DIR)/drivers/video/backlight/pwm_bl.ko
+	AUTOLOAD:=$(call AutoProbe,video pwm_bl)
+	$(call AddDepends/backlight)
+endef
+
+define KernelPackage/backlight/backlight-pwm
+	Kernel module for PWM based Backlight support.
+endef
+
+$(eval $(call KernelPackage,backlight-pwm))
-- 
1.9.1
_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel



More information about the openwrt-devel mailing list