Skip to content

SM8750: add rumble/haptics support for AYN Odin 3#3047

Open
simper wants to merge 1 commit into
ROCKNIX:nextfrom
simper:sm8750-odin3-haptics
Open

SM8750: add rumble/haptics support for AYN Odin 3#3047
simper wants to merge 1 commit into
ROCKNIX:nextfrom
simper:sm8750-odin3-haptics

Conversation

@simper

@simper simper commented Jul 21, 2026

Copy link
Copy Markdown

Summary

Adds force feedback / rumble support for the AYN Odin 3 (SM8750) using the Qualcomm PMIH0108 HV haptics driver, bridged to the rsinput gamepad driver so rumble events from games reach the LRA vibration motor.

This brings feature parity with SM8550 (Odin 2 / RP6), which already has haptics support merged via #2519.

Background

Armada OS issue #16 ("Enable rumble support") was closed as completed for SM8550 devices, but Odin 3 (SM8750) remains without rumble — the ROCKNIX SM8750 branch only has the base rsinput driver without FF support, and no haptics driver at all.

Gianni Spadoni (@gio3k) wrote experimental haptics patches in his initial Odin 3 PR #2613, but the haptics commits were not carried forward when that PR was partially merged. This PR resurrects and adapts that work.

Changes

File Description
1000-input-misc-qcom-hv-haptics-sm8750.patch Qualcomm HV haptics driver from OnePlus SM8750 Android kernel (qcom-hv-haptics.c, 6736 lines). Implements FF_CONSTANT and FF_PERIODIC/FF_CUSTOM FIFO streaming for the PMIH0108 LRA actuator. Exports qcom_spmi_haptics_global_{upload,playback,set_gain} for cross-driver access.
1001-haptics-driver-support-periodic-sine-and-fixes.patch Adds FF_SINE waveform handling, usleep_range to udelay fixes for atomic context, and gain-during-playback logic.
1002-input-rsinput-sm8750-ff.patch Rewritten to match the current rsinput driver in next (Philippe Simons' rewrite). Adds FF_PERIODIC capability + input_ff_create() to the rsinput gamepad, with upload/playback callbacks that forward events to the haptics driver via its exported API. Includes rumble_enable module param for runtime control.
1003-arm64-dts-qcom-ayn-cq8725s-common-hv-haptics.patch Adds the pmih0108_hv_haptics node to cq8725s-ayn-common.dtsi with SDAM config, LRA parameters, and 6 effect + 9 primitive waveform definitions from AYN's downstream DTS.
linux.aarch64.conf Enable CONFIG_INPUT_QCOM_HV_HAPTICS=m

How it works

Game -> Steam/Proton -> InputPlumber virtual gamepad
     -> FF event routed back to rsinput source device
     -> rsinput_rumble_play() calls qcom_spmi_haptics_global_playback()
     -> PMIH0108 HV haptics driver drives the LRA motor

Testing

Not yet tested on hardware. I don't have an Odin 3. This PR is based on:

If you have an Odin 3, please test and report back. Build the SM8750 image from this branch, flash, and try rumble in games or fftest /dev/input/event*.

Credits

AI Usage

AI was used to: research the gap, extract/adapt patches from the original fork, and rewrite the rsinput FF bridge patch to match the current next rsinput driver. The actual driver code is from Qualcomm/OnePlus downstream.

Adds force feedback / rumble support for the AYN Odin 3 (SM8750) using
the Qualcomm PMIH0108 HV haptics driver, bridged to the rsinput gamepad
driver so that rumble events from games reach the LRA vibration motor.

Patches:
- 1000: Qualcomm HV haptics driver (from OnePlus SM8750 Android kernel)
- 1001: Periodic/sine FF support + usleep->udelay fixes for the driver
- 1002: rsinput FF bridge: forwards gamepad FF events to haptics driver
- 1003: DTS: add PMIH0108 hv-haptics node + effect/primitive waveforms

Kernel config: enable CONFIG_INPUT_QCOM_HV_HAPTICS=m

Based on the initial experimental work by Gianni Spadoni (gio3k) in PR ROCKNIX#2613,
adapted to the current ROCKNIX next rsinput driver rewrite.

Tested on SM8550 (Odin 2) with the same driver approach by r3claimer (ROCKNIX#2519).
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.

1 participant