- 08 4月, 2019 1 次提交
-
-
由 Dan Murphy 提交于
Introduce the Texas Instruments LM3532 White LED driver. The driver supports ALS configurability or manual brightness control. The driver also supports associating LED strings with specific control banks in a group or as individually controlled strings. Signed-off-by: NDan Murphy <dmurphy@ti.com> Tested-by: NTony Lindgren <tony@atomide.com> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 04 4月, 2019 1 次提交
-
-
由 Dan Murphy 提交于
Fix misspelling and capitalization of LED in the Kconfig. Reported-by: NRandy Dunlap <rdunlap@infradead.org> Signed-off-by: NDan Murphy <dmurphy@ti.com> Acked-by: NPavel Machek <pavel@ucw.cz> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 03 4月, 2019 1 次提交
-
-
由 Colin Ian King 提交于
Currently data->i2c_addr is being assigned twice, first with the value 0x09 and then immediately afterwards with the value 0x08. The first assignment is redundant and can be removed. Signed-off-by: NColin Ian King <colin.king@canonical.com> Reviewed-by: NMukesh Ojha <mojha@codeaurora.org> Acked-by: NPavel Machek <pavel@ucw.cz> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 01 4月, 2019 7 次提交
-
-
由 Andy Shevchenko 提交于
Make use of device property API in this driver so that both OF based system and ACPI based system can use this driver. Signed-off-by: NAndy Shevchenko <andriy.shevchenko@linux.intel.com> Acked-by: NPavel Machek <pavel@ucw.cz> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
由 Andy Shevchenko 提交于
Make use of device property API in this driver so that both OF based system and ACPI based system can use this driver. Signed-off-by: NAndy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
由 YueHaibing 提交于
As the chip can't be queried for it's current state, the "keep" option doesn't make sense. The only option in DT should be turn the LED on or off at probe time. Also 'flags' is never used since introduction. Signed-off-by: NYueHaibing <yuehaibing@huawei.com> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
由 Daniel Mack 提交于
The only user of this driver in mainline has now moved to DTS, so the pdata code is no longer in use by anyone. Let's drop some dead code, and make the driver depend on CONFIG_OF. Signed-off-by: NDaniel Mack <daniel@zonque.org> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
由 Andy Shevchenko 提交于
There is no evidence of officially registered ACPI IDs for these devices. Thus, revert commit 44b3e31d. Signed-off-by: NAndy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
由 Andy Shevchenko 提交于
There is no evidence of officially registered ACPI IDs for these devices. Thus, revert commit f26dab9f. Signed-off-by: NAndy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
Clean up spaces before tabs. Signed-off-by: NEnrico Weigelt, metux IT consult <info@metux.net> Acked-by: NPavel Machek <pavel@ucw.cz> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 19 3月, 2019 1 次提交
-
-
由 Sakari Ailus 提交于
Switch the as3645a from OF to the fwnode property API. Also add ACPI support. Signed-off-by: NSakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 24 2月, 2019 1 次提交
-
-
由 Vadim Pasternak 提交于
Add support for capability register in order to distinct between the systems with minor LED configuration differences. It reduces the amount of code describing systems' LED configuration. For example one system can be equipped with six LED, while the other with only four. Reading this information from the capability registers allows to use the same LED structure for such systems and set the relevant configuration dynamically based on capability register content. Signed-off-by: NVadim Pasternak <vadimp@mellanox.com> Acked-by: NJacek Anaszewski <jacek.anaszewski@gmail.com> Signed-off-by: NDarren Hart (VMware) <dvhart@infradead.org>
-
- 15 2月, 2019 1 次提交
-
-
由 Michal Kazior 提交于
I've stumbled upon a kernel crash and the logs pointed me towards the lp5562 driver: > <4>[306013.841294] lp5562 0-0030: Direct firmware load for lp5562 failed with error -2 > <4>[306013.894990] lp5562 0-0030: Falling back to user helper > ... > <3>[306073.924886] lp5562 0-0030: firmware request failed > <1>[306073.939456] Unable to handle kernel NULL pointer dereference at virtual address 00000000 > <4>[306074.251011] PC is at _raw_spin_lock+0x1c/0x58 > <4>[306074.255539] LR is at release_firmware+0x6c/0x138 > ... After taking a look I noticed firmware_release() could be called with either NULL or a dangling pointer. Fixes: 10c06d17 ("leds-lp55xx: support firmware interface") Signed-off-by: NMichal Kazior <michal@plume.com> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 18 1月, 2019 1 次提交
-
-
由 Kangjie Lu 提交于
When lp55xx_read() fails, "status" is an uninitialized variable and thus may contain random value; using it leads to undefined behaviors. The fix inserts a check for the return value of lp55xx_read: if it fails, returns with its error code. Signed-off-by: NKangjie Lu <kjlu@umn.edu> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 17 1月, 2019 4 次提交
-
-
由 Krzysztof Kozlowski 提交于
Allow initialization of delays used in timer trigger from Device Tree property. This is especially useful for embedded systems where the trigger might be used early, before bringing up user-space. Signed-off-by: NKrzysztof Kozlowski <krzk@kernel.org> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
由 Krzysztof Kozlowski 提交于
Allow initialization of delays used in oneshot trigger from Device Tree property. This is especially useful for embedded systems where the trigger might be used early, before bringing up user-space. Signed-off-by: NKrzysztof Kozlowski <krzk@kernel.org> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
由 Krzysztof Kozlowski 提交于
Allow initialization of pattern used in pattern trigger from Device Tree property. This is especially useful for embedded systems where the pattern trigger would be used to indicate the process of boot status in a nice, user-friendly blinking way. This initialization pattern will be used till user-space is brought up and sets its own pattern, indicating the boot status is for example finished. Signed-off-by: NKrzysztof Kozlowski <krzk@kernel.org> Acked-by: NPavel Machek <pavel@ucw.cz> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
由 Krzysztof Kozlowski 提交于
Multiple LED triggers might need to access default pattern so add a helper for that. Signed-off-by: NKrzysztof Kozlowski <krzk@kernel.org> Acked-by: NPavel Machek <pavel@ucw.cz> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 11 12月, 2018 3 次提交
-
-
由 Krzysztof Kozlowski 提交于
Trigger driver can be initialized after the LED class device driver. In such case led_trigger_set_default() won't be called and flag LED_INIT_DEFAULT_TRIGGER should be set from led_trigger_register(). Signed-off-by: NKrzysztof Kozlowski <krzk@kernel.org> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
由 Jacek Anaszewski 提交于
Add the flag LED_INIT_DEFAULT_TRIGGER for indicating that trigger being set is a default trigger for the LED class device, and thus it should be initialized with settings provided in the fwnode. Set the flag in the led_trigger_set_default(). It is expected to be cleared in the activate() op of a trigger after trigger fwnode initialization data is parsed and applied. This should happen only once after LED class device registration, to allow leaving triggers in the idle state on re-apply and let the users apply their own settings without interference from the default ones. Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com> Acked-by: NPavel Machek <pavel@ucw.cz> Signed-off-by: NKrzysztof Kozlowski <krzk@kernel.org>
-
由 Jacek Anaszewski 提交于
It is of no avail to continue iterating through registered triggers in the led_trigger_set_default() after the trigger to set has been found. Add "break" statement to fix this omission. Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com> Acked-by: NPavel Machek <pavel@ucw.cz> Signed-off-by: NKrzysztof Kozlowski <krzk@kernel.org>
-
- 09 12月, 2018 3 次提交
-
-
由 Krzysztof Kozlowski 提交于
The PWM leds can be instantiated from Device Tree so pass the respective device node to LED core. This provides the LED system with proper device node and exposes it through uevent. Signed-off-by: NKrzysztof Kozlowski <krzk@kernel.org> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
由 Krzysztof Kozlowski 提交于
Simplify the exit path with resource-managed version of registering LED class device. The code should be functionally the same, except that on device removal the led_pwm_priv->num_leds is not decremented to zero (which should not have any effect as device is going away). Signed-off-by: NKrzysztof Kozlowski <krzk@kernel.org> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
由 Krzysztof Kozlowski 提交于
This reverts the main change of commit bff23714 ("leds: leds-gpio: Set of_node for created LED devices") because of_node assignment is handled by core since commit 7ea79ae8 ("leds: gpio: use OF variant of LED registering function"). Basically the code was overwriting the of_node with same value. No functional change expected. Signed-off-by: NKrzysztof Kozlowski <krzk@kernel.org> Tested-by: NRafał Miłecki <rafal@milecki.pl> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 07 12月, 2018 1 次提交
-
-
由 Rob Herring 提交于
Convert string compares of DT node names to use of_node_name_eq helper instead. This removes direct access to the node name pointer. For instances using of_node_cmp, this has the side effect of now using case sensitive comparisons. This should not matter for any FDT based system which this is. Cc: linux-leds@vger.kernel.org Signed-off-by: NRob Herring <robh@kernel.org> Acked-by: NPavel Machek <pavel@ucw.cz> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 28 11月, 2018 1 次提交
-
-
由 Takashi Iwai 提交于
This patch adds a new LED trigger for coupling the audio mixer change with the LED on laptops or other devices. Currently there are two trigger types, "audio-mute" and "audio-micmute". The audio driver triggers the LED brightness change via ledtrig_audio_set() call with the proper type (either mute or mic-mute). OTOH, the consumers may call ledtrig_audio_get() for the initial brightness value that may have been set by the audio driver beforehand. This new stuff will be used by HD-audio codec driver and some platform drivers (thinkpad_acpi and dell-laptop, also upcoming huawei-wmi). Acked-by: NJacek Anaszewski <jacek.anaszewski@gmail.com> Acked-by: NPavel Machek <pavel@ucw.cz> Acked-by: NPali Rohár <pali.rohar@gmail.com> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
- 22 11月, 2018 1 次提交
-
-
由 Yangtao Li 提交于
of_find_node_by_path() acquires a reference to the node returned by it and that reference needs to be dropped by its caller. powernv_led_probe() doesn't do that, so fix it. Signed-off-by: NYangtao Li <tiny.windzz@gmail.com> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 08 11月, 2018 1 次提交
-
-
由 Baolin Wang 提交于
We will meet below issue due to mutex_lock() is called in interrupt context. The mutex lock is used to protect the pattern trigger data, but before changing new pattern trigger data (pattern values or repeat value) by users, we always cancel the timer firstly to clear previous patterns' performance. That means there is no race in pattern_trig_timer_function(), so we can drop the mutex lock in pattern_trig_timer_function() to avoid this issue. Moreover we can move the timer cancelling into mutex protection, since there is no deadlock risk if we remove the mutex lock in pattern_trig_timer_function(). BUG: sleeping function called from invalid context at kernel/locking/mutex.c:254 in_atomic(): 1, irqs_disabled(): 0, pid: 0, name: swapper/1 CPU: 1 PID: 0 Comm: swapper/1 Not tainted 4.20.0-rc1-koelsch-00841-ga338c8181013c1a9 #171 Hardware name: Generic R-Car Gen2 (Flattened Device Tree) [<c020f19c>] (unwind_backtrace) from [<c020aecc>] (show_stack+0x10/0x14) [<c020aecc>] (show_stack) from [<c07affb8>] (dump_stack+0x7c/0x9c) [<c07affb8>] (dump_stack) from [<c02417d4>] (___might_sleep+0xf4/0x158) [<c02417d4>] (___might_sleep) from [<c07c92c4>] (mutex_lock+0x18/0x60) [<c07c92c4>] (mutex_lock) from [<c067b28c>] (pattern_trig_timer_function+0x1c/0x11c) [<c067b28c>] (pattern_trig_timer_function) from [<c027f6fc>] (call_timer_fn+0x1c/0x90) [<c027f6fc>] (call_timer_fn) from [<c027f944>] (expire_timers+0x94/0xa4) [<c027f944>] (expire_timers) from [<c027fc98>] (run_timer_softirq+0x108/0x15c) [<c027fc98>] (run_timer_softirq) from [<c02021cc>] (__do_softirq+0x1d4/0x258) [<c02021cc>] (__do_softirq) from [<c0224d24>] (irq_exit+0x64/0xc4) [<c0224d24>] (irq_exit) from [<c0268dd0>] (__handle_domain_irq+0x80/0xb4) [<c0268dd0>] (__handle_domain_irq) from [<c045e1b0>] (gic_handle_irq+0x58/0x90) [<c045e1b0>] (gic_handle_irq) from [<c02019f8>] (__irq_svc+0x58/0x74) Exception stack(0xeb483f60 to 0xeb483fa8) 3f60: 00000000 00000000 eb9afaa0 c0217e80 00000000 ffffe000 00000000 c0e06408 3f80: 00000002 c0e0647c c0c6a5f0 00000000 c0e04900 eb483fb0 c0207ea8 c0207e98 3fa0: 60020013 ffffffff [<c02019f8>] (__irq_svc) from [<c0207e98>] (arch_cpu_idle+0x1c/0x38) [<c0207e98>] (arch_cpu_idle) from [<c0247ca8>] (do_idle+0x138/0x268) [<c0247ca8>] (do_idle) from [<c0248050>] (cpu_startup_entry+0x18/0x1c) [<c0248050>] (cpu_startup_entry) from [<402022ec>] (0x402022ec) Fixes: 5fd752b6 ("leds: core: Introduce LED pattern trigger") Signed-off-by: NBaolin Wang <baolin.wang@linaro.org> Reported-by: NGeert Uytterhoeven <geert+renesas@glider.be> Tested-by: NGeert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 27 10月, 2018 1 次提交
-
-
由 Liviu Dudau 提交于
Commit 45d4c6de ("leds: gpio: Try to lookup gpiod from device") removed the common code path that set the led_dat->gpiod pointer in create_gpio_led(), but only added it back for the devices that have a valid gpio_led_platform_data structure. Calling gpio_leds_create() in gpio_led_probe() is not enough to get a valid gpiod pointer. Fortunately enough, gpio_leds_create() already gets the needed pointer, we just need to assign it to the relevant gpio_led_data structure. Fixes: 45d4c6de ("leds: gpio: Try to lookup gpiod from device") Signed-off-by: NLiviu Dudau <liviu@dudau.co.uk> Reviewed-by: NLinus Walleij <linus.walleij@linaro.org> Acked-by: NPavel Machek <pavel@ucw.cz> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 26 10月, 2018 1 次提交
-
-
由 Pavel Machek 提交于
Check for zero duration before skipping step. This fixes pattern echo "0 1000 10 2550 0 1000" > pattern which should do [ .-xXx-.] but does [ Xx-.] Signed-off-by: NPavel Machek <pavel@ucw.cz> Suggested-by: NJacek Anaszewski <jacek.anaszewski@gmail.com> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 12 10月, 2018 2 次提交
-
-
由 Baolin Wang 提交于
This patch implements the 'pattern_set'and 'pattern_clear' interfaces to support SC27XX LED breathing mode. Signed-off-by: NBaolin Wang <baolin.wang@linaro.org> Acked-by: NPavel Machek <pavel@ucw.c> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
由 Baolin Wang 提交于
This patch adds a new LED trigger that LED device can configure to employ software or hardware pattern engine. Consumers can write 'pattern' file to enable the software pattern which alters the brightness for the specified duration with one software timer. Moreover consumers can write 'hw_pattern' file to enable the hardware pattern for some LED controllers which can autonomously control brightness over time, according to some preprogrammed hardware patterns. Signed-off-by: NRaphael Teysseyre <rteysseyre@gmail.com> Signed-off-by: NBaolin Wang <baolin.wang@linaro.org> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 11 9月, 2018 2 次提交
-
-
由 Simon Shields 提交于
AN30259A is a 3-channel LED driver which uses I2C. It supports timed operation via an internal PWM clock, and variable brightness. This driver offers support for basic hardware-based blinking and brightness control. The datasheet is freely available: https://www.alliedelec.com/m/d/a9d2b3ee87c2d1a535a41dd747b1c247.pdfSigned-off-by: NSimon Shields <simon@lineageos.org> Acked-by: NPavel Machek <pavel@ucw.cz> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
由 Linus Walleij 提交于
This augments the GPIO lookup code in the GPIO LEDs to attempt to look up a GPIO descriptor from the device with index. This makes it possible to use GPIO machine look-up tables and stop passing global GPIO numbers through platform data. Using this we can stepwise convert existing board files to use machine descriptor tables and then eventually drop the legacy GPIO support and only include <linux/gpio/consumer.h> and use descriptors exclusively. Signed-off-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 09 9月, 2018 1 次提交
-
-
由 Jerome Brunet 提交于
When probing, if we fail to get the pwm due to probe deferal, we shouldn't print an error message. Just be silent in this case. Signed-off-by: NJerome Brunet <jbrunet@baylibre.com> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 29 8月, 2018 1 次提交
-
-
由 Rob Herring 提交于
In preparation to remove the node name pointer from struct device_node, convert printf users to use the %pOFn format specifier. Signed-off-by: NRob Herring <robh@kernel.org> Cc: linux-leds@vger.kernel.org Acked-by: NSakari Ailus <sakari.ailus@linux.intel.com> Acked-by: NPavel Machek <pavel@ucw.cz> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 07 8月, 2018 1 次提交
-
-
由 Kitone Elvis Peter 提交于
Use unsigned int, because it's preferred to unsigned. Signed-off-by: NKitone Elvis Peter <elviskitone@gmail.com> Acked-by: NPavel Machek <pavel@ucw.cz> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
- 06 7月, 2018 3 次提交
-
-
由 Uwe Kleine-König 提交于
The trigger core learned error handling for the activate callback and to handle device attributes. Also make use of the module_led_trigger() helper to simplify trigger registration. Signed-off-by: NUwe Kleine-König <u.kleine-koenig@pengutronix.de> Acked-by: NPavel Machek <pavel@ucw.cz> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
由 Uwe Kleine-König 提交于
Use the new module_led_trigger() helper. Also use attribute support from the trigger core. Drop error message on allocation failure as kzalloc() already screams loudly when failing. Use wrappers to get and set trigger data. Signed-off-by: NUwe Kleine-König <u.kleine-koenig@pengutronix.de> Acked-by: NPavel Machek <pavel@ucw.cz> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-
由 Uwe Kleine-König 提交于
The trigger core learned error handling for the activate callback and can handle device attributes now. This allows simplifying the driver considerably. Note that .deactivate() is only called when .activate() succeeded, so the check for .activated can go away in .deactivate(). Also make use of module_led_trigger() and the accessor function to get and set trigger_data. Signed-off-by: NUwe Kleine-König <u.kleine-koenig@pengutronix.de> Acked-by: NPavel Machek <pavel@ucw.cz> Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
-