Skip to content

[NOT-FOR-UPSTREAM, RETIRED] HID: ayaneo: LED-name experiment - #130

Draft
sknowledge1 wants to merge 18 commits into
OpenGamingCollective:features/ayaneofrom
sknowledge1:ayaneo3-steam-name-20261014
Draft

sknowledge1 wants to merge 18 commits into
OpenGamingCollective:features/ayaneofrom
sknowledge1:ayaneo3-steam-name-20261014

Conversation

@sknowledge1

@sknowledge1 sknowledge1 commented Oct 14, 2026 •

Copy link
Copy Markdown

Retired experiment. The name change did not expose Steam controls in the recorded test and is not required by the current managed-lighting path. This draft is preserved as negative evidence; no adoption or additional kernel change is proposed.

This is an OGC-only go:rgb:joystick_rings compatibility-name experiment for AYANEO joystick lighting. Private device testing found no Steam controls with either the generic name or this candidate, so it remains unqualified and draft.

Only the LED name and its allocation change. Color, brightness, effect attributes, HID commands and Magic Modules behavior remain unchanged. Based on features/ayaneo at f4471f7a956cadd1f518e87b07b3a06e3bc1e9c9; candidate 64fb9d5b9e58290b48b69fed175fd7c35ad846b4.

Current path: InputPlumber #734 provides managed native lighting; #735 is closed. OGC #123 already supplies the AYANEO interfaces. This naming patch is not a dependency.

The recorded generic-name and renamed-device tests were both unsuccessful. Retain their evidence without adopting the go-style name as a generic upstream ABI requirement.

Private device test on 2026-10-14: AYANEO 3 8840U, BIOS 1.00, Bazzite 44.20261012.1, kernel 7.2.9-ogc3.1.fc44.x86_64, Steam 1791918634 / steamdeck_stable (Oct 13 updater). The stock generic name did not expose controls in Steam Customization with the effective InputPlumber profile containing no LED entries. Brightness, multi_intensity and effect were writable as the Steam user.

The candidate HID module built against the exact installed kernel headers and loaded successfully, exposing go:rgb:joystick_rings, both module IDs and the same writable attributes. Steam restarted after the load, but the user still saw no joystick lighting controls. Steam logs classify the device as SteamOSGeneric; the root cause of the missing controls remains unresolved. On the restored stock driver, the native LEDManager GetState call succeeds with is_service_available=false and devices=[]. The naming change alone is not demonstrated to solve discovery. The temporary module was unloaded and the packaged stock driver restored. The initial Steam-first pause was superseded by the managed native path in InputPlumber #734. This naming experiment is retired and unqualified; no full kernel/image build or official Bazzite acceptance is claimed.

Assisted-by: Codex:GPT-6

pastaq and others added 18 commits October 7, 2026 01:19
Adds platform driver for AYN Loki and Tectoy Zeenix lines of handheld
devices. This patch implements a hwmon interface for EC provided manual
PWM fan control and user defined fan curves. A global ACPI lock is used
when reading or writing from the EC.

There are 4 fan modes implemented in this patch. Modes 0-3 act in
accordance with the standard hwmon logic where 0 is 100% fan speed, 1 is
manual control, and 2 is automatic control. As the EC only provides 3
modes by default, mode 0 is implemented by setting the device to manual
and then setting fan speed to 100% directly. In mode 1 the PWM duty cycle
is set in sysfs with values [0-255], which are then scaled to the EC max
of 128. Mode 4 is an automatic mode where the fan curve is user defined.
There are 5 total set points and each set point takes a temperature in
Celsius [0-100] and a PWM duty cycle [0-255]. When the CPU temperature
reaches a given set point, the corresponding duty cycle is automatically
set by the EC.

Signed-off-by: Derek J. Clark <derekjohn.clark@gmail.com>
Adds temperature sensors to the ayn-ec hwmon interface. These read-only
values include Battery, Motherboard, Charger IC, vCore, and CPU Core, as
well as labels for each entry. The temperature values provided by the EC
are whole numbers in degrees Celsius. As hwmon expects millidegrees, we
scale the raw value up.

`sensors` output after this patch is applied:
aynec-isa-0000
Adapter: ISA adapter
fan1:        1876 RPM
Battery:      +29.0°C
Motherboard:  +30.0°C
Charger IC:   +30.0°C
vCore:        +36.0°C
CPU Core:     +48.0°C

Signed-off-by: Derek J. Clark <derekjohn.clark@gmail.com>
Adds an EC controlled LED Multicolor Class Device for controlling the
RGB rings around the joysticks.

The EC provides a single register for each of the colors red, green, and
blue, as well as a mode switching register. The EC accepts values
[0-255] for all colors. There are two available effects: breathe, which is
the default when the device is started, and monocolor. When resuming from
sleep the user selected effect will be overwritten by the EC, so the
driver retains the last setting and resets on resume. When setting a
color, each color register is set before a final "write" code is sent to
the device. The EC may briefly reflect the "write" code when writing, but
quickly changes to the "monocolor" value once complete. The driver
interprets both of these values as "monocolor" in _show to simplify the
sysfs exposed to the user.

Two custom attributes are added to the standard LED parent device:
effect, a RW file descriptor used to set the effect, and effect_index,
which enumerates the available valid options.

Signed-off-by: Derek J. Clark <derekjohn.clark@gmail.com>
Adds ABI documentation for the ayn-ec platform driver

Signed-off-by: Derek J. Clark <derekjohn.clark@gmail.com>
…ntation Contribution by CVMagic (https://github.com/CVMagic)

aw87xxx: Use strscpy instead of strlcpy

awinic: i2c_driver cleanup and fixes

This is deliberately an OGC-carried patch and must not be sent upstream.

(cherry picked from commit 91a51cacadb95ba80227663a75fd113552b18e45)
Signed-off-by: Hijae Song <hijae@naver.com>
…gging purposes, but also fixed Reset Pin GPIO initialization issue with Ayn Loki Mini

This is deliberately an OGC-carried patch and must not be sent upstream.

(cherry picked from commit 4b4179efc86828f8762f0819aabf4413a3ba0d27)
Signed-off-by: Hijae Song <hijae@naver.com>
…a second I2C chip if specified in ACPI

This is deliberately an OGC-carried patch and must not be sent upstream.

(cherry picked from commit ed123302c7dde72a935052370de4a9b2ff3e1feb)
Signed-off-by: Hijae Song <hijae@naver.com>
…sume.

This is deliberately an OGC-carried patch and must not be sent upstream.

(cherry picked from commit 92392036d95ffdf9fc2b4b42c3dd31a8939d4027)
Signed-off-by: Hijae Song <hijae@naver.com>
This is deliberately an OGC-carried patch and must not be sent upstream.

(cherry picked from commit dac32102659fa0ae4f2692ed81810ceb834ed584)
Signed-off-by: Hijae Song <hijae@naver.com>
Multiple AyaNeo/Ayn/Orange Pi devices ship the aw87xxx amplifier with
different firmware blobs. Select the firmware filename by DMI board/
product match so each device's blob coexists under /lib/firmware
without collision, falling back to the original single filename when
no match is found.

This is deliberately an OGC-carried patch and must not be sent upstream.

Co-developed-by: bouhaa <boukehaarsma23@gmail.com>
Co-developed-by: Antheas Kapenekakis <git@antheas.dev>
Signed-off-by: Hijae Song <hijae@naver.com>
linux/of_gpio.h has been removed from the tree. None of these
files actually use anything from it (no of_gpio_* calls), so drop
the dead include to fix the build.

This is deliberately an OGC-carried patch and must not be sent upstream.

Signed-off-by: Hijae Song <hijae@naver.com>
…mponent

Newer kernels (6.16+) changed snd_soc_unregister_component()'s
signature. Add a version-gated wrapper so the driver still builds
across the kernel versions this branch needs to support.

This is deliberately an OGC-carried patch and must not be sent upstream.

Signed-off-by: Hijae Song <hijae@naver.com>
The valid-GPIO branch fell through without ever requesting the
reset pin, leaving it unclaimed. Request it with devm_gpio_request_one()
so the driver actually owns and can drive the reset line.

This is deliberately an OGC-carried patch and must not be sent upstream.

Signed-off-by: Hijae Song <hijae@naver.com>
The ALC269VB codec's internal speaker pin isn't configured
correctly on the AyaNeo AIR 1S out of the box, so no audio
plays even once the aw87xxx amplifier driver (added earlier in
this branch) is working. Add a pin fixup matching the AIR 1S's
PCI SSID that sets pin 0x1a to 0x90170110, restoring internal
speaker output.

This is deliberately an OGC-carried patch and must not be sent upstream.

Co-developed-by: linh1987
(cherry picked from commit 89eb9630d9114c38f35edc4041daf8b1d25886d3)
Signed-off-by: Hijae Song <hijae@naver.com>
The AYANEO 3 handheld has a detachable controller with swappable
modules ("Magic Modules"). The controller exposes three USB HID
interfaces behind 1c4f:0002 (a generic SigmaMicro VID/PID, hence the
DMI gate): a gamepad, a keyboard for the extra buttons, and a vendor
interface accepting 65-byte commands.

Add a driver for the vendor interface providing module identification
(module_left/module_right sysfs attributes), software eject of the
modules (eject sysfs attribute, blocking until the firmware confirms
the release handshake), and RGB control of the joystick rings as a
multicolor LED class device ("<device name>:rgb:joystick_rings";
userspace such as InputPlumber matches the function suffix). The
firmware's fixed breathing pattern is exposed through the hw_pattern
trigger ABI.

This complements the ayaneo-ec platform driver, which exposes module
attach state and controller power. A full physical eject is performed
by writing to eject and then cutting power through ayaneo-ec's
controller_power attribute; that orchestration is deliberately left
to userspace.

The protocol was reverse engineered in the Handheld Daemon project by
Antheas Kapenekakis. Tested on an AYANEO 3: module identification,
RGB solid and breathing, a full eject/reinsert/repower cycle, and
repeated driver unbinds under a concurrent brightness-write load.
Signed-off-by: Matías Martínez <hello@matias.me>
Reviewed-by: Denis Benato <denis.benato@linux.dev>
Link: https://lore.kernel.org/r/20260917160722.89391-1-hello@matias.me
Update the driver to the state submitted as v4: firmware LED effects
through effect/effect_index (monocolor, breathe, rainbow) replacing
the hw_pattern trigger and its ABI document, rumble_intensity plus an
index attribute, transparent pass-through of the non-vendor 1c4f:0002
interfaces with reset_resume mirrored from hid-generic, configuration
reapply after reset, sysfs teardown ordered before the transport with
IO kept enabled, the reply state under a spinlock, and an enforced
minimum eject settle time.

Link: https://lore.kernel.org/r/20260925061941.75121-1-hello@matias.me
Signed-off-by: Matías Martínez <hello@matias.me>
The AYANEO 2S uses the same EC fan interface as the AYANEO 2 and
additionally supports charge limiting. Add an exact match ahead of the
broader AYANEO 2 match so the charge-control quirk is selected.

Reported-by: Tiago Silva <tiago.paulo@live.com>
Signed-off-by: Antheas Kapenekakis <lkml@antheas.dev>
Prepare an OGC-only go:rgb:joystick_rings name for testing if Steam cannot discover the generic AYANEO LED name. Keep effects and controls unchanged. Device evidence is required before deciding whether this compatibility candidate should be used; do not make this name a generic upstream ABI.

Assisted-by: Codex:GPT-6
@coderabbitai

coderabbitai Bot commented Oct 14, 2026

Copy link
Copy Markdown

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@sknowledge1 sknowledge1 changed the title [NOT-FOR-UPSTREAM] HID: ayaneo: prepare Steam LED name compatibility [NOT-FOR-UPSTREAM, RETIRED] HID: ayaneo: LED-name experiment Oct 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants