Linux Documentation
 help / color / mirror / Atom feed
From: "Tomasz Pakuła" <tomasz.pakula.oficjalny@gmail.com>
To: dmitry.torokhov@gmail.com, corbet@lwn.net, jikos@kernel.org,
	bentiss@kernel.org
Cc: linux-input@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-doc@vger.kernel.org, vi@endrift.com,
	linux-kernel@altimeter.info, peter.hutterer@who-t.net
Subject: [RFC PATCH 1/6] Input: Introduce EV_BTN event for generic buttons
Date: Sun,  4 Jan 2026 22:31:27 +0100	[thread overview]
Message-ID: <20260104213132.163904-2-tomasz.pakula.oficjalny@gmail.com> (raw)
In-Reply-To: <20260104213132.163904-1-tomasz.pakula.oficjalny@gmail.com>

This will be used to fire generic button events that only transmit
button number and it's value, not related to any defined usage.

Made for HID joysticks but could be adopted by other devices.

Signed-off-by: Tomasz Pakuła <tomasz.pakula.oficjalny@gmail.com>
---
 Documentation/input/event-codes.rst    | 5 +++++
 include/uapi/linux/input-event-codes.h | 1 +
 2 files changed, 6 insertions(+)

diff --git a/Documentation/input/event-codes.rst b/Documentation/input/event-codes.rst
index 4424cbff251f..c387eaa63dfb 100644
--- a/Documentation/input/event-codes.rst
+++ b/Documentation/input/event-codes.rst
@@ -59,6 +59,11 @@ Codes section for details on valid codes for each type.
 
   - Used to describe binary state input switches.
 
+* EV_BTN:
+
+  - Used to describe state changes generic, numbered buttons without defined
+    usages.
+
 * EV_LED:
 
   - Used to turn LEDs on devices on and off.
diff --git a/include/uapi/linux/input-event-codes.h b/include/uapi/linux/input-event-codes.h
index 30f3c9eaafaa..1c853c37b58a 100644
--- a/include/uapi/linux/input-event-codes.h
+++ b/include/uapi/linux/input-event-codes.h
@@ -42,6 +42,7 @@
 #define EV_ABS			0x03
 #define EV_MSC			0x04
 #define EV_SW			0x05
+#define EV_BTN			0x06
 #define EV_LED			0x11
 #define EV_SND			0x12
 #define EV_REP			0x14
-- 
2.52.0


  reply	other threads:[~2026-01-04 21:31 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-01-04 21:31 [RFC PATCH 0/6] Input: New EV_BTN event for generic buttons Tomasz Pakuła
2026-01-04 21:31 ` Tomasz Pakuła [this message]
2026-01-04 22:30   ` [RFC PATCH 1/6] Input: Introduce " Randy Dunlap
2026-01-04 21:31 ` [RFC PATCH 2/6] Input: Add info about EV_BTN Tomasz Pakuła
2026-01-04 21:31 ` [RFC PATCH 3/6] Input: Fire EV_BTN if found in ev_bit Tomasz Pakuła
2026-01-08 10:48   ` Benjamin Tissoires
2026-01-04 21:31 ` [RFC PATCH 4/6] Input: Assign EV_BTN event to HID Joysticks Tomasz Pakuła
2026-01-08 10:50   ` Benjamin Tissoires
2026-01-04 21:31 ` [RFC PATCH 5/6] Input: Realign rest of the HID_UP_BUTTON cases Tomasz Pakuła
2026-01-04 21:31 ` [RFC PATCH 6/6] Input: Add EVIOCGBTNCNT Tomasz Pakuła
2026-01-07  5:44 ` [RFC PATCH 0/6] Input: New EV_BTN event for generic buttons Ivan Gorinov
2026-01-08  3:24 ` Peter Hutterer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260104213132.163904-2-tomasz.pakula.oficjalny@gmail.com \
    --to=tomasz.pakula.oficjalny@gmail.com \
    --cc=bentiss@kernel.org \
    --cc=corbet@lwn.net \
    --cc=dmitry.torokhov@gmail.com \
    --cc=jikos@kernel.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@altimeter.info \
    --cc=linux-kernel@vger.kernel.org \
    --cc=peter.hutterer@who-t.net \
    --cc=vi@endrift.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox