DTC tools, correct SYSCON LEDs

This commit is contained in:
Ciro Santilli
2017-07-03 08:58:14 +01:00
parent c5e32b60bf
commit e06bf63e08
4 changed files with 26 additions and 13 deletions

View File

@@ -58,17 +58,11 @@ CONFIG_TRACER_SNAPSHOT=y
# cat /sys/kernel/debug/kernel_page_tables
CONFIG_X86_PTDUMP=y
# LEDs.
# LEDs. ARM only.
#
# modprobe led-class
# modprobe leds-versatile
# ls /sys/class/leds
#
# TODO: the LEDs don't appear there. There are some entires under:
#
# /sys/devices/platform/10000000.core-module/10000000.core-module:led@08.0/
#
# but they don't have brightness file.
# cd /sys/class/leds/versatile:0
# cat max_brightness
# echo 255 >brightness
#
# https://raspberrypi.stackexchange.com/questions/697/how-do-i-control-the-system-leds-using-my-software
#
@@ -81,10 +75,24 @@ CONFIG_X86_PTDUMP=y
#
# - arch/arm/boot/dts/versatile-pb.dts
# - drivers/leds/led-class.c
# - drivers/leds/leds-versatile.c
# - drivers/leds/leds-sysctl.c
#
# Try hacking QEMU's `hw/misc/arm_sysctl.c` with a printf:
#
# static void arm_sysctl_write(void *opaque, hwaddr offset,
# uint64_t val, unsigned size)
# {
# arm_sysctl_state *s = (arm_sysctl_state *)opaque;
#
# switch (offset) {
# case 0x08: /* LED */
# printf("LED val = %llx\n", (unsigned long long)val);
#
# to obeserve when the callback is made. But beware that one of the LEDs
# has a heartbeat trigger by default (specified on dts), so it will produce a lot of output.
CONFIG_LEDS_CLASS=y
CONFIG_LEDS_CLASS_FLASH=y
CONFIG_LEDS_SYSCON=y
CONFIG_LEDS_TRIGGERS=y
CONFIG_LEDS_TRIGGER_BACKLIGHT=y
CONFIG_LEDS_TRIGGER_CPU=y
@@ -93,7 +101,6 @@ CONFIG_LEDS_TRIGGER_GPIO=y
CONFIG_LEDS_TRIGGER_HEARTBEAT=y
CONFIG_LEDS_TRIGGER_ONESHOT=y
CONFIG_LEDS_TRIGGER_TIMER=y
CONFIG_LEDS_VERSATILE=y
CONFIG_NEW_LEDS=y
# GPIO.