SM8750: AYN Odin 3 - expose the two back paddles as gpio-keys#2940
Open
aanze wants to merge 1 commit into
Open
SM8750: AYN Odin 3 - expose the two back paddles as gpio-keys#2940aanze wants to merge 1 commit into
aanze wants to merge 1 commit into
Conversation
The Odin 3's two back "macro" paddles (M1, M2) do nothing on stock ROCKNIX because there is no driver for them. They are not on the gamepad MCU UART (rsinput) and not ADC despite AYN's Android "adckey"/keydetect.ko naming - they are plain active-low SoC TLMM GPIOs (M1 = GPIO 3, M2 = GPIO 7), reverse-engineered from AYN's Android keydetect.ko (gpio_request 515/519 = TLMM base 512 + offsets 3/7). Add a gpio-keys node to the Odin 3 dts exposing them as BTN_Z (M1, left) and BTN_C (M2, right) - the spare gamepad codes AYN's own firmware uses and which the existing InputPlumber map (ayn_mcu.yaml) already routes to Left/RightPaddle1, so they become usable paddle buttons in games and Steam.
f093e17 to
aa0c8d8
Compare
loki666
reviewed
Jun 28, 2026
Contributor
There was a problem hiding this comment.
thanks, could you merge this with 0047-arm64-dts-qcom-Add-AYN-Odin3.patch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
gpio-keysnode to the Odin 3 dts so they report buttons.rsinput) and not ADC despite AYN's Androidadckey/keydetect.konaming — they are plain active-low SoC TLMM GPIOs: M1 (left) = GPIO 3 →BTN_Z, M2 (right) = GPIO 7 →BTN_C(TLMM base 512 + offsets 3/7, RE'd from AYN'skeydetect.ko).BTN_Z/BTN_Care what AYN's firmware uses and what the existingayn_mcu.yamlalready maps to Left/RightPaddle1, so no InputPlumber change is needed.Testing
evtest) with no chatter; left →BTN_Z, right →BTN_C. Pins verified UNCLAIMED before use.Additional Context
<&tlmm 3>,<&tlmm 7>), input + pull-up, 15ms debounce.AI Usage
Did you use AI tools to help write this code? PARTIALLY — reverse-engineering and patch authoring assisted by AI; hardware findings verified on-device.