[OpenWrt-Devel] [PATCH] CC-x86: add support for LEDs on PCEngines APU
Ben Pfountz
netprince at vt.edu
Thu Oct 1 11:21:37 EDT 2015
These 2 patches add support for the front 3 LEDs on the PCEngines APU board:
- Create a subtarget for the PCEngines APU, which selects all the
supported options I could find for this board.
- Adds a kmod-leds-apu kernel module package which supports the 3 front
LEDs on the PCEngines APU.
- Corrects the aes-i586 kernel package to better check for a 64bit
configuration.
This work is based on code published here: http://daduke.org/linux/apu/
Tested with CC r47065 on a PCEngines apu1d
Signed-off-by: Ben Pfountz <netprince (at) vt (dot) edu>
-------------- next part --------------
diff -urN target.old/linux/generic/files/drivers/leds/leds-apu.c target/linux/generic/files/drivers/leds/leds-apu.c
--- target.old/linux/generic/files/drivers/leds/leds-apu.c 1969-12-31 19:00:00.000000000 -0500
+++ target/linux/generic/files/drivers/leds/leds-apu.c 2015-09-29 20:14:49.852056800 -0400
@@ -0,0 +1,234 @@
+/*
+ * LEDs driver for PCEngines apu
+ *
+ * Copyright (C) 2013 Christian Herzog <daduke at daduke.org>, based on
+ * Petr Leibman's leds-alix
+ * Based on leds-wrap.c
+ * Hardware info taken from http://www.dpie.com/manuals/miniboards/kontron/KTD-S0043-0_KTA55_SoftwareGuide.pdf
+ *
+ * 2014-12-8: Mark Schank
+ * - Added GPIO support for the APU push-button switch.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+#define APU_BUTTON // Enable gpio support for the APU button switch
+
+#include <linux/kernel.h>
+#include <linux/module.h>
+#include <linux/init.h>
+#include <linux/platform_device.h>
+#include <linux/leds.h>
+#ifdef APU_BUTTON
+#include <linux/gpio.h>
+#endif
+#include <linux/err.h>
+#include <asm/io.h>
+
+#define DRVNAME "apu-led"
+#define BASEADDR (0xFED801BD)
+#define LEDON (0x8)
+#define LEDOFF (0xC8)
+
+static struct platform_device *pdev;
+unsigned int *p1;
+unsigned int *p2;
+unsigned int *p3;
+
+#ifdef APU_BUTTON
+#define BUTTONADDR (0xFED801BB)
+unsigned int *b1;
+#endif
+
+static void apu_led_set_1(struct led_classdev *led_cdev,
+ enum led_brightness value) {
+ if (value)
+ iowrite8(LEDON, p1);
+ else
+ iowrite8(LEDOFF, p1);
+}
+
+static void apu_led_set_2(struct led_classdev *led_cdev,
+ enum led_brightness value) {
+ if (value)
+ iowrite8(LEDON, p2);
+ else
+ iowrite8(LEDOFF, p2);
+}
+
+static void apu_led_set_3(struct led_classdev *led_cdev,
+ enum led_brightness value) {
+ if (value)
+ iowrite8(LEDON, p3);
+ else
+ iowrite8(LEDOFF, p3);
+}
+
+static struct led_classdev apu_led_1 = {
+ .name = "apu:1",
+ .brightness_set = apu_led_set_1,
+};
+
+static struct led_classdev apu_led_2 = {
+ .name = "apu:2",
+ .brightness_set = apu_led_set_2,
+};
+
+static struct led_classdev apu_led_3 = {
+ .name = "apu:3",
+ .brightness_set = apu_led_set_3,
+};
+
+#ifdef APU_BUTTON
+static int gpio_apu_button_direction_in(struct gpio_chip *gc, unsigned gpio_num)
+{
+ u8 curr_state;
+
+ curr_state = ioread8(b1);
+ iowrite8(curr_state | (1 << 5), b1);
+
+ return 0;
+}
+
+static int gpio_apu_button_get(struct gpio_chip *gc, unsigned gpio_num)
+{
+ u8 curr_state;
+
+ curr_state = ioread8(b1);
+
+ return((curr_state & (1 << 7)) == (1 << 7));
+}
+
+static struct gpio_chip apu_gpio_button = {
+ .label = "apu_button",
+ .owner = THIS_MODULE,
+ .get = gpio_apu_button_get,
+ .direction_input = gpio_apu_button_direction_in,
+ .base = 187,
+ .ngpio = 1,
+};
+#endif
+
+
+#ifdef CONFIG_PM
+static int apu_led_suspend(struct platform_device *dev,
+ pm_message_t state)
+{
+ led_classdev_suspend(&apu_led_1);
+ led_classdev_suspend(&apu_led_2);
+ led_classdev_suspend(&apu_led_3);
+ return 0;
+}
+
+static int apu_led_resume(struct platform_device *dev)
+{
+ led_classdev_resume(&apu_led_1);
+ led_classdev_resume(&apu_led_2);
+ led_classdev_resume(&apu_led_3);
+ return 0;
+}
+#else
+#define apu_led_suspend NULL
+#define apu_led_resume NULL
+#endif
+
+static int apu_led_probe(struct platform_device *pdev)
+{
+ int ret;
+
+ ret = led_classdev_register(&pdev->dev, &apu_led_1);
+ if (ret == 0)
+ {
+ ret = led_classdev_register(&pdev->dev, &apu_led_2);
+ if (ret >= 0)
+ {
+ ret = led_classdev_register(&pdev->dev, &apu_led_3);
+ if (ret >= 0)
+ {
+#ifdef APU_BUTTON
+ ret = gpiochip_add(&apu_gpio_button);
+ if(ret == 0){
+ if(!gpio_request_one(187, GPIOF_IN, "Button")){
+ gpio_export(187, 0);
+ }
+ }
+ if (ret < 0)
+ led_classdev_unregister(&apu_led_3);
+#endif
+ }
+ if (ret < 0)
+ led_classdev_unregister(&apu_led_2);
+ }
+ if (ret < 0)
+ led_classdev_unregister(&apu_led_1);
+ }
+ return ret;
+}
+
+static int apu_led_remove(struct platform_device *pdev)
+{
+#ifdef APU_BUTTON
+ int ret;
+#endif
+ led_classdev_unregister(&apu_led_1);
+ led_classdev_unregister(&apu_led_2);
+ led_classdev_unregister(&apu_led_3);
+
+#ifdef APU_BUTTON
+ gpiochip_remove(&apu_gpio_button);
+#else
+ return 0;
+#endif
+}
+
+static struct platform_driver apu_led_driver = {
+ .probe = apu_led_probe,
+ .remove = apu_led_remove,
+ .suspend = apu_led_suspend,
+ .resume = apu_led_resume,
+ .driver = {
+ .name = DRVNAME,
+ .owner = THIS_MODULE,
+ },
+};
+
+static int __init apu_led_init(void)
+{
+ int ret;
+
+#ifdef APU_BUTTON
+ b1 = ioremap(BUTTONADDR, 1);
+#endif
+
+ ret = platform_driver_register(&apu_led_driver);
+ if (ret < 0)
+ goto out;
+
+ pdev = platform_device_register_simple(DRVNAME, -1, NULL, 0);
+ if (IS_ERR(pdev)) {
+ ret = PTR_ERR(pdev);
+ platform_driver_unregister(&apu_led_driver);
+ goto out;
+ }
+
+ p1 = ioremap(BASEADDR, 1);
+ p2 = ioremap(BASEADDR+1, 1);
+ p3 = ioremap(BASEADDR+2, 1);
+
+out:
+ return ret;
+}
+
+static void __exit apu_led_exit(void)
+{
+ platform_device_unregister(pdev);
+ platform_driver_unregister(&apu_led_driver);
+}
+
+module_init(apu_led_init);
+module_exit(apu_led_exit);
+
+MODULE_AUTHOR("Christian Herzog");
+MODULE_DESCRIPTION("PCEngines apu LED driver");
+MODULE_LICENSE("GPL");
diff -urN target.old/linux/generic/patches-3.18/835-led_apu.patch target/linux/generic/patches-3.18/835-led_apu.patch
--- target.old/linux/generic/patches-3.18/835-led_apu.patch 1969-12-31 19:00:00.000000000 -0500
+++ target/linux/generic/patches-3.18/835-led_apu.patch 2015-09-29 19:25:28.700056800 -0400
@@ -0,0 +1,28 @@
+diff -urN linux-3.18.21.old/drivers/leds/Kconfig linux-3.18.21/drivers/leds/Kconfig
+--- linux-3.18.21.old/drivers/leds/Kconfig 2015-09-29 18:44:17.804056800 -0400
++++ linux-3.18.21/drivers/leds/Kconfig 2015-09-29 19:21:36.780056800 -0400
+@@ -112,6 +112,13 @@
+ help
+ This option enables support for the PCEngines WRAP programmable LEDs.
+
++config LEDS_APU
++ tristate "LED Support for the PCEngines APU board"
++ depends on LEDS_CLASS
++ depends on GPIOLIB
++ help
++ This option enables support for the three LEDs on the PCEngines APU board.
++
+ config LEDS_COBALT_QUBE
+ tristate "LED Support for the Cobalt Qube series front LED"
+ depends on LEDS_CLASS
+diff -urN linux-3.18.21.old/drivers/leds/Makefile linux-3.18.21/drivers/leds/Makefile
+--- linux-3.18.21.old/drivers/leds/Makefile 2015-09-29 18:44:17.892056800 -0400
++++ linux-3.18.21/drivers/leds/Makefile 2015-09-29 19:11:36.572056800 -0400
+@@ -56,6 +56,7 @@
+ obj-$(CONFIG_LEDS_SYSCON) += leds-syscon.o
+ obj-$(CONFIG_LEDS_VERSATILE) += leds-versatile.o
+ obj-$(CONFIG_LEDS_MENF21BMC) += leds-menf21bmc.o
++obj-$(CONFIG_LEDS_APU) += leds-apu.o
+
+ # LED SPI Drivers
+ obj-$(CONFIG_LEDS_DAC124S085) += leds-dac124s085.o
diff -urN target.old/linux/x86/apu/config-default target/linux/x86/apu/config-default
--- target.old/linux/x86/apu/config-default 1969-12-31 19:00:00.000000000 -0500
+++ target/linux/x86/apu/config-default 2015-09-29 17:25:00.795389600 -0400
@@ -0,0 +1,223 @@
+CONFIG_64BIT=y
+CONFIG_ACPI=y
+CONFIG_ACPI_AC=y
+CONFIG_ACPI_BATTERY=y
+CONFIG_ACPI_BUTTON=y
+# CONFIG_ACPI_CMPC is not set
+# CONFIG_ACPI_CONTAINER is not set
+# CONFIG_ACPI_CUSTOM_DSDT is not set
+# CONFIG_ACPI_DEBUG is not set
+# CONFIG_ACPI_DOCK is not set
+# CONFIG_ACPI_EC_DEBUGFS is not set
+CONFIG_ACPI_FAN=y
+# CONFIG_ACPI_INITRD_TABLE_OVERRIDE is not set
+CONFIG_ACPI_LEGACY_TABLES_LOOKUP=y
+# CONFIG_ACPI_PCI_SLOT is not set
+CONFIG_ACPI_PROCESSOR=y
+# CONFIG_ACPI_PROCESSOR_AGGREGATOR is not set
+# CONFIG_ACPI_PROCFS_POWER is not set
+# CONFIG_ACPI_SBS is not set
+CONFIG_ACPI_THERMAL=y
+# CONFIG_ACPI_WMI is not set
+CONFIG_ARCH_DEFCONFIG="arch/x86/configs/x86_64_defconfig"
+CONFIG_ARCH_DMA_ADDR_T_64BIT=y
+CONFIG_ARCH_ENABLE_MEMORY_HOTPLUG=y
+CONFIG_ARCH_ENABLE_SPLIT_PMD_PTLOCK=y
+CONFIG_ARCH_HWEIGHT_CFLAGS="-fcall-saved-rdi -fcall-saved-rsi -fcall-saved-rdx -fcall-saved-rcx -fcall-saved-r8 -fcall-saved-r9 -fcall-saved-r10 -fcall-saved-r11"
+CONFIG_ARCH_MIGHT_HAVE_ACPI_PDC=y
+CONFIG_ARCH_PHYS_ADDR_T_64BIT=y
+CONFIG_ARCH_SPARSEMEM_DEFAULT=y
+CONFIG_ARCH_SUPPORTS_INT128=y
+CONFIG_ARCH_SUPPORTS_NUMA_BALANCING=y
+CONFIG_ARCH_USE_CMPXCHG_LOCKREF=y
+# CONFIG_ASUS_LAPTOP is not set
+# CONFIG_ATA_SFF is not set
+CONFIG_AUDIT_ARCH=y
+CONFIG_AVERAGE=y
+CONFIG_BLK_DEV_INTEGRITY=y
+CONFIG_CALGARY_IOMMU=y
+CONFIG_CALGARY_IOMMU_ENABLED_BY_DEFAULT=y
+CONFIG_CPU_RMAP=y
+CONFIG_CRC_T10DIF=y
+# CONFIG_CRYPTO_AES_X86_64 is not set
+# CONFIG_CRYPTO_BLOWFISH_X86_64 is not set
+# CONFIG_CRYPTO_CAMELLIA_AESNI_AVX2_X86_64 is not set
+# CONFIG_CRYPTO_CAMELLIA_AESNI_AVX_X86_64 is not set
+# CONFIG_CRYPTO_CAMELLIA_X86_64 is not set
+# CONFIG_CRYPTO_CAST5_AVX_X86_64 is not set
+# CONFIG_CRYPTO_CAST6_AVX_X86_64 is not set
+CONFIG_CRYPTO_CRCT10DIF=y
+# CONFIG_CRYPTO_CRCT10DIF_PCLMUL is not set
+# CONFIG_CRYPTO_DES3_EDE_X86_64 is not set
+# CONFIG_CRYPTO_SALSA20_X86_64 is not set
+# CONFIG_CRYPTO_SERPENT_AVX2_X86_64 is not set
+# CONFIG_CRYPTO_SERPENT_AVX_X86_64 is not set
+# CONFIG_CRYPTO_SERPENT_SSE2_X86_64 is not set
+# CONFIG_CRYPTO_SHA1_MB is not set
+# CONFIG_CRYPTO_SHA1_SSSE3 is not set
+# CONFIG_CRYPTO_SHA256_SSSE3 is not set
+# CONFIG_CRYPTO_SHA512_SSSE3 is not set
+# CONFIG_CRYPTO_SKEIN is not set
+# CONFIG_CRYPTO_THREEFISH is not set
+# CONFIG_CRYPTO_TWOFISH_AVX_X86_64 is not set
+# CONFIG_CRYPTO_TWOFISH_X86_64 is not set
+# CONFIG_CRYPTO_TWOFISH_X86_64_3WAY is not set
+CONFIG_DIRECT_GBPAGES=y
+# CONFIG_EFI is not set
+CONFIG_FB=y
+CONFIG_FB_CMDLINE=y
+CONFIG_FB_MODE_HELPERS=y
+CONFIG_FB_TILEBLITTING=y
+# CONFIG_FB_VESA is not set
+# CONFIG_FONTS is not set
+CONFIG_FONT_8x16=y
+CONFIG_FONT_8x8=y
+CONFIG_FONT_SUPPORT=y
+CONFIG_FRAMEBUFFER_CONSOLE=y
+# CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY is not set
+# CONFIG_FRAMEBUFFER_CONSOLE_ROTATION is not set
+CONFIG_GART_IOMMU=y
+CONFIG_GENERIC_BUG_RELATIVE_POINTERS=y
+CONFIG_GENERIC_CPU=y
+CONFIG_GENERIC_PENDING_IRQ=y
+CONFIG_HAVE_ACPI_APEI=y
+CONFIG_HAVE_ACPI_APEI_NMI=y
+# CONFIG_HAVE_AOUT is not set
+CONFIG_HAVE_ARCH_SOFT_DIRTY=y
+CONFIG_HAVE_BPF_JIT=y
+CONFIG_HAVE_CONTEXT_TRACKING=y
+CONFIG_HAVE_FENTRY=y
+# CONFIG_HAVE_GENERIC_DMA_COHERENT is not set
+CONFIG_HAVE_IRQ_EXIT_ON_IRQ_STACK=y
+CONFIG_HAVE_MEMORY_PRESENT=y
+CONFIG_HAVE_VIRT_CPU_ACCOUNTING_GEN=y
+CONFIG_HID=y
+CONFIG_HID_BATTERY_STRENGTH=y
+CONFIG_HPET=y
+CONFIG_HPET_MMAP=y
+# CONFIG_HP_ACCEL is not set
+CONFIG_HW_RANDOM_INTEL=y
+# CONFIG_HW_RANDOM_VIRTIO is not set
+CONFIG_HYPERVISOR_GUEST=y
+# CONFIG_I7300_IDLE is not set
+# CONFIG_IA32_EMULATION is not set
+CONFIG_ILLEGAL_POINTER_VALUE=0xdead000000000000
+# CONFIG_INTEL_IPS is not set
+# CONFIG_INTEL_MENLOW is not set
+# CONFIG_INTEL_MIC_BUS is not set
+# CONFIG_IOMMU_DEBUG is not set
+CONFIG_IOMMU_HELPER=y
+# CONFIG_ISCSI_IBFT_FIND is not set
+# CONFIG_ITCO_VENDOR_SUPPORT is not set
+CONFIG_ITCO_WDT=y
+# CONFIG_KVM_DEBUG_FS is not set
+CONFIG_KVM_GUEST=y
+CONFIG_LPC_ICH=y
+# CONFIG_MAXSMP is not set
+CONFIG_MEMORY_BALLOON=y
+# CONFIG_MEMORY_HOTPLUG is not set
+CONFIG_MFD_CORE=y
+CONFIG_MODULES_USE_ELF_RELA=y
+# CONFIG_MPSC is not set
+CONFIG_MUTEX_SPIN_ON_OWNER=y
+CONFIG_NEED_DMA_MAP_STATE=y
+CONFIG_NET_FLOW_LIMIT=y
+CONFIG_NLS=y
+CONFIG_NR_CPUS=8
+# CONFIG_NUMA is not set
+CONFIG_OUTPUT_FORMAT="elf64-x86-64"
+CONFIG_PARAVIRT=y
+CONFIG_PARAVIRT_CLOCK=y
+# CONFIG_PARAVIRT_DEBUG is not set
+# CONFIG_PARAVIRT_SPINLOCKS is not set
+# CONFIG_PARAVIRT_TIME_ACCOUNTING is not set
+CONFIG_PCIEAER=y
+CONFIG_PCIEPORTBUS=y
+# CONFIG_PCI_IOAPIC is not set
+CONFIG_PCI_LABEL=y
+# CONFIG_PCI_MMCONFIG is not set
+CONFIG_PHYSICAL_ALIGN=0x1000000
+CONFIG_PHYS_ADDR_T_64BIT=y
+CONFIG_PNP=y
+CONFIG_PNPACPI=y
+CONFIG_PNP_DEBUG_MESSAGES=y
+# CONFIG_PVPANIC is not set
+CONFIG_QUEUE_RWLOCK=y
+CONFIG_RAS=y
+CONFIG_RCU_STALL_COMMON=y
+CONFIG_RFS_ACCEL=y
+CONFIG_RPS=y
+CONFIG_RWSEM_SPIN_ON_OWNER=y
+# CONFIG_SAMSUNG_Q10 is not set
+CONFIG_SATA_AHCI=y
+CONFIG_SCSI_VIRTIO=y
+CONFIG_SERIAL_8250_PNP=y
+CONFIG_SLUB_CPU_PARTIAL=y
+CONFIG_SMP=y
+CONFIG_SPARSEMEM=y
+CONFIG_SPARSEMEM_ALLOC_MEM_MAP_TOGETHER=y
+CONFIG_SPARSEMEM_EXTREME=y
+CONFIG_SPARSEMEM_MANUAL=y
+# CONFIG_SPARSEMEM_VMEMMAP is not set
+CONFIG_SPARSEMEM_VMEMMAP_ENABLE=y
+CONFIG_STOP_MACHINE=y
+CONFIG_SWIOTLB=y
+# CONFIG_THINKPAD_ACPI is not set
+# CONFIG_TOPSTAR_LAPTOP is not set
+# CONFIG_TOSHIBA_BT_RFKILL is not set
+CONFIG_TREE_RCU=y
+# CONFIG_UNISYSSPAR is not set
+CONFIG_USB=y
+CONFIG_USB_COMMON=y
+CONFIG_USB_EHCI_HCD=y
+# CONFIG_USB_EHCI_HCD_PLATFORM is not set
+CONFIG_USB_EHCI_PCI=y
+CONFIG_USB_OHCI_HCD=y
+CONFIG_USB_OHCI_HCD_PCI=y
+# CONFIG_USB_OHCI_HCD_PLATFORM is not set
+CONFIG_USB_STORAGE=y
+CONFIG_USB_UHCI_HCD=y
+CONFIG_USB_XHCI_HCD=y
+CONFIG_USB_XHCI_PCI=y
+CONFIG_VGACON_SOFT_SCROLLBACK=y
+CONFIG_VGACON_SOFT_SCROLLBACK_SIZE=64
+CONFIG_VIRTIO=y
+CONFIG_VIRTIO_BALLOON=y
+CONFIG_VIRTIO_BLK=y
+CONFIG_VIRTIO_CONSOLE=y
+CONFIG_VIRTIO_MMIO=y
+# CONFIG_VIRTIO_MMIO_CMDLINE_DEVICES is not set
+CONFIG_VIRTIO_NET=y
+CONFIG_VIRTIO_PCI=y
+CONFIG_VIRT_DRIVERS=y
+CONFIG_VMWARE_BALLOON=y
+CONFIG_VMWARE_PVSCSI=y
+CONFIG_VMWARE_VMCI=y
+CONFIG_VMWARE_VMCI_VSOCKETS=y
+CONFIG_VMXNET3=y
+CONFIG_VSOCKETS=y
+CONFIG_WATCHDOG_CORE=y
+CONFIG_X86_64=y
+CONFIG_X86_64_SMP=y
+# CONFIG_X86_ACPI_CPUFREQ is not set
+CONFIG_X86_CMOV=y
+CONFIG_X86_CMPXCHG64=y
+CONFIG_X86_DEBUGCTLMSR=y
+CONFIG_X86_DEV_DMA_OPS=y
+CONFIG_X86_HT=y
+# CONFIG_X86_INTEL_LPSS is not set
+CONFIG_X86_MINIMUM_CPU_FAMILY=64
+# CONFIG_X86_MSR is not set
+# CONFIG_X86_PCC_CPUFREQ is not set
+CONFIG_X86_PM_TIMER=y
+CONFIG_X86_TSC=y
+# CONFIG_XEN is not set
+CONFIG_XPS=y
+CONFIG_ZONE_DMA32=y
+CONFIG_GPIOLIB=y
+# CONFIG_GPIO_F7188X is not set
+# CONFIG_GPIO_LYNXPOINT is not set
+# CONFIG_GPIO_INTEL_MID is not set
+CONFIG_GPIO_SYSFS=y
+CONFIG_LEDS_GPIO=y
+CONFIG_LEDS_APU=m
diff -urN target.old/linux/x86/apu/target.mk target/linux/x86/apu/target.mk
--- target.old/linux/x86/apu/target.mk 1969-12-31 19:00:00.000000000 -0500
+++ target/linux/x86/apu/target.mk 2015-09-29 19:27:21.552056800 -0400
@@ -0,0 +1,16 @@
+ARCH:=x86_64
+BOARDNAME:=PCEngines APU
+FEATURES:=squashfs ext4 pci usb gpio
+ARCH_PACKAGES:=x86_64
+
+define Target/Description
+ Build images for pcengines APU
+endef
+
+DEFAULT_PACKAGES += \
+ kmod-r8169 kmod-sound-core kmod-pcspkr hwclock \
+ kmod-button-hotplug \
+ kmod-leds-apu kmod-ledtrig-heartbeat kmod-ledtrig-gpio kmod-ledtrig-netdev \
+ kmod-i2c-core kmod-i2c-piix4 \
+ kmod-usb-core kmod-usb-ohci kmod-usb2 kmod-usb3 \
+ libsensors lm-sensors
diff -urN target.old/linux/x86/Makefile target/linux/x86/Makefile
--- target.old/linux/x86/Makefile 2015-09-29 09:25:08.991389600 -0400
+++ target/linux/x86/Makefile 2015-09-29 09:31:41.471389600 -0400
@@ -10,7 +10,7 @@
BOARD:=x86
BOARDNAME:=x86
FEATURES:=squashfs ext4 vdi vmdk pcmcia targz
-SUBTARGETS=generic xen_domu ep80579 geode kvm_guest rdc 64
+SUBTARGETS=generic xen_domu ep80579 geode apu kvm_guest rdc 64
MAINTAINER:=Felix Fietkau <nbd at openwrt.org>
KERNEL_PATCHVER:=3.18
-------------- next part --------------
diff -urN package.old/kernel/linux/modules/leds.mk package/kernel/linux/modules/leds.mk
--- package.old/kernel/linux/modules/leds.mk 2015-09-29 19:31:50.888056800 -0400
+++ package/kernel/linux/modules/leds.mk 2015-09-29 19:44:24.204056800 -0400
@@ -183,6 +183,22 @@
$(eval $(call KernelPackage,ledtrig-oneshot))
+define KernelPackage/leds-apu
+ SUBMENU:=$(LEDS_MENU)
+ TITLE:=PCengines APU LED support
+ DEPENDS:=@TARGET_x86
+ KCONFIG:=CONFIG_LEDS_APU
+ FILES:=$(LINUX_DIR)/drivers/leds/leds-apu.ko
+ AUTOLOAD:=$(call AutoLoad,50,leds-apu)
+endef
+
+define KernelPackage/leds-apu/description
+ Kernel module for PCengines APU LEDs
+endef
+
+$(eval $(call KernelPackage,leds-apu))
+
+
define KernelPackage/leds-pca963x
SUBMENU:=$(LEDS_MENU)
TITLE:=PCA963x LED support
diff -urN package.old/kernel/linux/modules/crypto.mk package/kernel/linux/modules/crypto.mk
--- package.old/kernel/linux/modules/crypto.mk 2015-09-30 15:24:54.526261200 -0400
+++ package/kernel/linux/modules/crypto.mk 2015-09-30 15:35:04.354261200 -0400
@@ -262,7 +262,7 @@
$(call AddDepends/crypto)
endef
-ifndef CONFIG_TARGET_x86_64
+ifndef CONFIG_x86_64
define KernelPackage/crypto-aes/x86
FILES+=$(LINUX_DIR)/arch/x86/crypto/aes-i586.ko
AUTOLOAD:=$(call AutoLoad,09,aes-i586)
@@ -541,7 +541,7 @@
$(call AddDepends/crypto)
endef
-ifndef CONFIG_TARGET_x86_64
+ifndef CONFIG_x86_64
define KernelPackage/crypto-misc/x86
FILES+=$(LINUX_DIR)/arch/x86/crypto/twofish-i586.ko
endef
-------------- next part --------------
_______________________________________________
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