mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v2 0/5] HID: hidraw: Encapsulate struct hidraw and make hidraw.h private
@ 2026-10-16 22:41 Dmitry Torokhov
  2026-10-16 22:41 ` [PATCH v2 1/5] HID: core: Move internal declarations and drop unused exports Dmitry Torokhov
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Dmitry Torokhov @ 2026-10-16 22:41 UTC (permalink / raw)
  To: Jiri Kosina, Benjamin Tissoires
  Cc: Marcel Holtmann, Luiz Augusto von Dentz, Michael Zaidman,
	Rishi Gupta, Heiner Kallweit, Andrej Shadura, Johannes Roith,
	linux-input, linux-bluetooth, linux-kernel

This series cleans up internal HID core and hidraw header boundaries.

First, internal HID core declarations and unused symbol exports are
moved out of include/linux/hid.h into a private drivers/hid/hid-core.h
header. Next, a hidraw_instance() accessor is introduced in
include/linux/hidraw.h so HID drivers that only need the hidraw minor
number for naming or debug logging no longer dereference struct hidraw
directly. After converting the drivers and dropping unused
linux/hidraw.h includes, hidraw.h is moved to drivers/hid/hidraw.h and
struct hidraw along with its internal buffer and list structures are
made private to drivers/hid/hidraw.c.

Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
---
Changes in v2:
- Rebased onto latest linux-next (next-20261016) / hid.git for-next
- Updated hidinput_connect() declaration in drivers/hid/hid-core.h in
  patch 1/5 to use unsigned int connect_mask instead of unsigned int
  force to match upstream changes
- Link to v1: https://patch.msgid.link/20261014051326.3784498-1-dmitry.torokhov@gmail.com

---
Dmitry Torokhov (5):
      HID: core: Move internal declarations and drop unused exports
      HID: hidraw: Introduce hidraw_instance() helper
      HID: Use hidraw_instance() in drivers
      HID: Drop unused linux/hidraw.h includes
      HID: hidraw: Make hidraw.h private to HID subsystem

 drivers/hid/Kconfig                     |  3 +++
 drivers/hid/hid-core.c                  |  7 +++--
 drivers/hid/hid-core.h                  | 20 ++++++++++++++
 drivers/hid/hid-cp2112.c                | 15 ++++++-----
 drivers/hid/hid-ft260.c                 |  2 +-
 drivers/hid/hid-input.c                 |  4 +--
 drivers/hid/hid-led.c                   | 10 ++++---
 drivers/hid/hid-mcp2200.c               |  1 -
 drivers/hid/hid-mcp2221.c               |  1 -
 drivers/hid/hid-quirks.c                |  1 +
 drivers/hid/hid-u2fzero.c               | 10 ++++---
 drivers/hid/hid-winwing.c               |  1 -
 drivers/hid/hidraw.c                    | 48 ++++++++++++++++++++++++++++++---
 {include/linux => drivers/hid}/hidraw.h | 32 +++-------------------
 drivers/hid/usbhid/hid-core.c           |  1 -
 include/linux/hid.h                     |  8 ------
 net/bluetooth/hidp/core.c               |  1 -
 17 files changed, 100 insertions(+), 65 deletions(-)
---
base-commit: 2efb7a11f1aa4d2dc285fe2680cca22cb9f72f64
change-id: 20261014-test-hidraw-base-f965f4656c9a

Thanks.

-- 
Dmitry


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2026-10-16 22:42 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-10-16 22:41 [PATCH v2 0/5] HID: hidraw: Encapsulate struct hidraw and make hidraw.h private Dmitry Torokhov
2026-10-16 22:41 ` [PATCH v2 1/5] HID: core: Move internal declarations and drop unused exports Dmitry Torokhov
2026-10-16 22:41 ` [PATCH v2 2/5] HID: hidraw: Introduce hidraw_instance() helper Dmitry Torokhov
2026-10-16 22:41 ` [PATCH v2 3/5] HID: Use hidraw_instance() in drivers Dmitry Torokhov
2026-10-16 22:41 ` [PATCH v2 4/5] HID: Drop unused linux/hidraw.h includes Dmitry Torokhov
2026-10-16 22:41 ` [PATCH v2 5/5] HID: hidraw: Make hidraw.h private to HID subsystem Dmitry Torokhov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®