[PATCH 1/3] input: uapi: Add trigger_left and trigger_right to ff_rumble_effect struct
From: Guillaume Casal
Date: Thu Jul 30 2026 - 06:23:38 EST
From: Daniel Bomar <dbdaniel42@xxxxxxxxx>
This adds two variables to control the trigger motors to the struct that
is passed in from userspace. This is ABI compatible because it does not
change the total size of the union that contains this struct: the union
is sized by struct ff_periodic_effect, which is larger.
Originally posted in 2022 and never merged:
https://lore.kernel.org/lkml/20220410220449.5071-1-dbdaniel42@xxxxxxxxx/
Rebased onto v7.2-rc5 with no functional change; the kernel-doc entries for
the two new members are the only addition.
Signed-off-by: Daniel Bomar <dbdaniel42@xxxxxxxxx>
Signed-off-by: Guillaume Casal <guillaume.casal.42@xxxxxxxxx>
---
diff --git a/include/uapi/linux/input.h b/include/uapi/linux/input.h
--- a/include/uapi/linux/input.h
+++ b/include/uapi/linux/input.h
@@ -420,6 +420,8 @@
* struct ff_rumble_effect - defines parameters of a periodic force-feedback effect
* @strong_magnitude: magnitude of the heavy motor
* @weak_magnitude: magnitude of the light one
+ * @trigger_left: magnitude of the motor behind the left trigger
+ * @trigger_right: magnitude of the motor behind the right trigger
*
* Some rumble pads have two motors of different weight. Strong_magnitude
* represents the magnitude of the vibration generated by the heavy one.
@@ -427,6 +429,8 @@
struct ff_rumble_effect {
__u16 strong_magnitude;
__u16 weak_magnitude;
+ __u16 trigger_left;
+ __u16 trigger_right;
};
/**