Re: [PATCH v4] HID: generic: add LampArray support via hid-lamparray helper
From: Cristian Mazzotta
Date: Thu Aug 27 2026 - 14:48:56 EST
Am 25.03.26 um 11:35 schrieb Werner Sembach:
> as Tim went on to other endeavors, I'm taking over this patch. I have
> yet to test it myself, but i was already in the feedback loop while he
> was writing it, so I'm not unfamiliar with the code.
Hi Werner,
I recently got a new laptop (Acer Predator PT14-52T) with absolutely zero
support for any RGB outside of Windows 11; while studying the behavior of
the Windows driver, I found out about LampArray devices and so I ended up
landing here.
This laptop has 2 LampArray devices: a USB attached keyboard (05AF:767A)
and an I2C ENE controller (0CF2:5130) for 3 zones in total. The original
motivation was power draw during s2idle; the lights would stay on and
constantly draw power. I measured 12.35W drop to 2.84W when I
blanked the lights and measured with a simple usb power meter, so I've
been working off of Tim's code for the past little bit.
Getting full support required touching most of the driver:
- Multi-zone support with individual zone states instead of a single
monolithic zone taking every device.
- lamparray_read_lamp_count() used hid_hw_request(), which is
asynchronous, so the value was read before the transfer completed.
Switched to hid_hw_raw_request()
- lamparray_parse_update_report() would bind to the last HID_LAIP_LAMP_COUNT
(usage 0x0003) parsed rather than the first, so LampCount ended up
being on the wrong field. This has been fixed by binding the first match.
- Added suspend and resume hooks, including an autonomous mode refresh
on S4 that my laptop needed
- use_leds_uapi=0 now leaves the LED class devs registered, but ignores
all writes rather than unregistering them.
- Also added ABI documentation since it was missing previously
About half of the driver changed, so I don't think it would be easily
reviewable as a delta from v4.
Would you prefer that I post it as a v5 with Tim's patch as a base, or
should I just send you the changes that you can add to your own version?
I don't want to duplicate work if you already have a v5 in progress.
I have hardware in front of me so I can test whatever is useful.
Thank you,
Cristian Mazzotta