Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

leds: apu: extend support for PC Engines APU1 with newer firmware

The DMI_PRODUCT_NAME entry on current firmware of PC Engines APU1 changed
from "APU" to "apu1"

This modification adds the missing DMI data and thereby the LED support for
the PC Engines APU1 with firmware versions >= 4.6.8.

Signed-off-by: Andreas Eberlein <foodeas@aeberlein.de>
Tested-by: Zbyněk Kocur <zbynek.kocur@fel.cvut.cz>
Signed-off-by: Pavel Machek <pavel@ucw.cz>

authored by

Andreas Eberlein and committed by
Pavel Machek
1b40faf7 6039b7e8

+10 -1
+10 -1
drivers/leds/leds-apu.c
··· 83 83 }; 84 84 85 85 static const struct dmi_system_id apu_led_dmi_table[] __initconst = { 86 + /* PC Engines APU with factory bios "SageBios_PCEngines_APU-45" */ 86 87 { 87 88 .ident = "apu", 88 89 .matches = { 89 90 DMI_MATCH(DMI_SYS_VENDOR, "PC Engines"), 90 91 DMI_MATCH(DMI_PRODUCT_NAME, "APU") 92 + } 93 + }, 94 + /* PC Engines APU with "Mainline" bios >= 4.6.8 */ 95 + { 96 + .ident = "apu", 97 + .matches = { 98 + DMI_MATCH(DMI_SYS_VENDOR, "PC Engines"), 99 + DMI_MATCH(DMI_PRODUCT_NAME, "apu1") 91 100 } 92 101 }, 93 102 {} ··· 182 173 int err; 183 174 184 175 if (!(dmi_match(DMI_SYS_VENDOR, "PC Engines") && 185 - dmi_match(DMI_PRODUCT_NAME, "APU"))) { 176 + (dmi_match(DMI_PRODUCT_NAME, "APU") || dmi_match(DMI_PRODUCT_NAME, "apu1")))) { 186 177 pr_err("No PC Engines APUv1 board detected. For APUv2,3 support, enable CONFIG_PCENGINES_APU2\n"); 187 178 return -ENODEV; 188 179 }