Skip to content

HID: apple: J700 DockChannel keyboard and trackpad (reworked, 22 patches) - #27

Merged
RyanTheTide merged 22 commits into
aurora-wipfrom
series/neo-j700-hid-20260926
Sep 25, 2026
Merged

RyanTheTide merged 22 commits into
aurora-wipfrom
series/neo-j700-hid-20260926

Conversation

@RyanTheTide

@RyanTheTide RyanTheTide commented Sep 25, 2026 •

Copy link
Copy Markdown
Contributor

HID: apple: support J700 DockChannel keyboard and trackpad (rework of #27)

Rework of draft PR #27 (40b64367331b, 9 commits) into 22 commits on
aurora-wip, following its review, rebased onto the current aurora-wip.

Compile- and schema-checked only; not run on any hardware in this form.
The J700 hardware facts (pcIO encoding, power method 2 sequence, C1FE report
layout) are those recorded during the bring-up that #27 described; nothing
here is a new measurement.

What the series does

  • Bindings first (3 patches): apple,rtk-helper-asc4, apple,dockchannel
    and apple,dockchannel-hid, one schema per patch with examples, covering
    every in-tree SoC (t6020/t6030/t6031/t8112/t8122) plus t8140, both
    reg-names orders the tree uses, the stm/actuator/tp_accel children
    and apple,stm-reset-gpios. J700 additions: apple,no-stm,
    apple,j700-multitouch on the multi-touch child and apple,power-method
    (default 1). dtbs_check on t8112-j413/j493, t6020-j414s, t6030-j514s,
    t6031-j514c, t8122-j613 and t8140-j700: 42 warnings resolved, none new.
  • Nine fixes to the DockChannel HID transport, eight with
    Fixes: 18cedb745333: ifaces[] out-of-bounds index, sub-header read past
    a short body (and a leaked work item), unterminated init name, event/init
    block lengths, firmware header size, GET_REPORT return length (the
    replacement for 40b64367's -EMSGSIZE, which broke the STM device-ID
    prefix read), receive path deaf after ENOMEM, interface allocation leaks,
    TX length bound; plus driver removal (ordered teardown instead of
    BUG_ON(1), with suppress_bind_attrs and the stated module-reload
    limitation) and GPIO id 0 handling.
  • gpio: macsmc: the valid-mask off-by-one (Fixes: 9b21051b0885) and
    the J700 pcIO AFE reset line as GPIO 19 (pin 19 only; the pin-8 property
    is gone).
  • Power method 2 with one sequence, DT-gated, logical GPIO values, the
    reset line requested in probe; power method 1 and the SET_REPORT wire type
    are byte-for-byte the base on M2/M3. Command encoders in a header with
    four KUnit cases.
  • apple,no-stm, the C1FE decoder in hid-magicmouse (validator in the
    driver, no extra header), a separate kernel-doc fix, and a trimmed
    Documentation/hid/apple-j700-multitouch.rst (protocol only).

What changed since 40b64367331b

  • Power method 1 is restored exactly: OFF then ON after firmware, results
    ignored. dchid_raw_request() keeps sending SET_REPORT as OUTPUT.
  • The 40b64367 -EMSGSIZE rejection is replaced by copying
    min(reply, buffer) and returning the bytes copied (+ report ID).
  • The three bindings are rewritten to accept every existing DTB, one per
    patch, first in the series, with examples, the real maintainer address and
    MAINTAINERS lines in the T8140/J700 entry (not the Asahi block).
  • apple,j700-pcio-pin8, dchid_j700_power_v2(), dchid_j700_set_power(),
    the unreachable generic PM2 branch, the iface->index == 1 test,
    gpiod_set_raw_value_cansleep(), startup_failed, the traces, and
    hid-magicmouse-c1fe.h are gone. The PM2 line is requested in probe
    (GPIOD_ASIS) so -EPROBE_DEFER works.
  • The DT must describe the AFE reset as <&smc_gpio 19 GPIO_ACTIVE_HIGH>
    (see PR arm64: dts: apple: t8140/j700: keyboard, trackpad and USB-C topology (reworked, 5 patches) #30).
  • b947372e is split into ten patches; f84bfd85, 5817de29, 824cca96 and
    40b64367 are folded into the commits they fixed; the kernel-doc fix is its
    own patch; the Makefile de-duplication is its own patch.
  • The dev_info → dev_dbg demotions on every machine are not carried
    (only "No OF node for subdevice" is demoted, for every interface).
  • The rst is reduced to the protocol; Eryk Wieliczko (PM2
    encoder, KUnit cases) and LiamRay11 (C1FE report description) are credited
    in prose with "Signed-off-by is outstanding". Author, committer and
    Signed-off-by are all [email protected].

Checks run (per commit)

  • make ARCH=arm64 LLVM=1 W=1 C=1 with upstream sparse on
    dockchannel-hid.o, hid-magicmouse.o, hid-apple.o, gpio-macsmc.o
    (J700 config): no warnings at any commit; the pre-existing kernel-doc
    warnings in hid-magicmouse.c are gone after patch 20.
  • The KUnit object built W=1 C=1 in a Rust-free arm64 config (this tree's
    Rust KUnit code does not compile under CONFIG_KUNIT, unrelated). Tests
    not run.
  • checkpatch.pl --strict --codespell: 0 errors; only the known noise
    (7.1 Assisted-by format, Co-authored-by, "Unknown commit id" for
    Fixes:, CamelCase pcIO).
  • dt_binding_check on the three schemas: clean. CHECK_DTBS=y on the seven
    boards above, re-validated at the head: no new warnings.
  • git diff --check: clean.

Not tested

Nothing was booted. Before merging is declared done on hardware, these must be run: J700 probe without deferral loops, both interfaces
ready, the PM2 OFF/ON sequence with the GPIO_ACTIVE_HIGH line (polarity is
the first suspect if the trackpad stays down), keyboard/click/scroll,
released contacts on lift, no pressure/size axes advertised, a retried open
after a failed start, hidraw GET_REPORT with a short buffer, clean shutdown;
and on an M2/M3 laptop unchanged trackpad/keyboard behaviour with a nonzero
STM product ID.

Follow-ups

  • dockchannel.c: dockchannel_recv() calls disable_irq() from its own
    IRQ thread on a body timeout (deadlock); reachable from the new remove()
    during a half-received packet. Pre-existing.
  • dchid_handle_ack() writes the response fields without out_mutex
    (late-ACK race). Pre-existing.
  • Restart the MTP helper from Linux so unbind/rebind and module reload work.
  • The probe-time GPIO deferral loop only scans child nodes; the M2/M3 reset
    lines live on the parent. Pre-existing.
  • Rust KUnit code (rust/kernel/iosys_map.rs:549) breaks CONFIG_KUNIT=y.

🤖 Generated with Claude Code

RyanTheTide and others added 22 commits September 26, 2026 03:20
The MTP coprocessor that serves the keyboard and trackpad of Apple
laptops runs RTKit firmware that the operating system only has to boot
and keep running; the DockChannel HID transport then talks to it over a
FIFO pair. The T8112, T8122, T6020, T6030 and T6031 device trees have
carried apple,rtk-helper-asc4 nodes for it without a binding, and the
T8140 (J700, MacBook Neo) adds a sixth SoC.

Describe the node: the ASC control window, the optional SRAM window
from which the firmware may ask the host to map buffers, the mailbox,
the IOMMU stream and the #helper-cells property that the existing
device trees carry although nothing consumes it. The compatible list
covers every in-tree user, including the T6031 node, whose second entry
is the T8122 helper compatible, so the existing device trees validate
unchanged. No bare apple,rtk-helper-asc4 form is allowed: no device
tree uses one, and a node needs its SoC-specific compatibles.

Compile-tested only: dt_binding_check on the schema, and dtbs_check on
t8112-j413, t8112-j493, t6020-j414s, t6030-j514s, t6031-j514c,
t8122-j613 and t8140-j700 with no new warnings.

Assisted-by: LLM checkpatch dt_binding_check
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
Apple laptops from the M2 generation on connect the built-in keyboard
and trackpad to the MTP coprocessor, which announces them as HID
interfaces over a DockChannel FIFO pair. The apple,dockchannel-hid node
has been in the T8112, T8122, T6020, T6030 and T6031 device trees
without a binding. Describe it with the properties those trees use: the
four FIFO windows, in either of the two orders the trees have; the
tx/rx interrupts; the IOMMU stream; the FIFO size; the helper phandle;
the AFE and STM reset lines; and the keyboard, multi-touch, stm,
actuator and tp_accel children.

Add what the T8140 (J700, MacBook Neo) needs on top. apple,no-stm says
that the firmware has no STM interface to report the machine
identifiers, so the transport must not wait for one. The
apple,j700-multitouch compatible on the multi-touch child says that the
trackpad sends a different report layout (a 32-byte header instead of
38 bytes, and an 8-byte trailer). apple,power-method selects the power
sequencing protocol of the firmware: with method 1, used by every
earlier laptop and therefore the default, the coprocessor sequences the
trackpad and asks the host to pulse the reset line; with method 2 the
host announces each transition, drives the AFE reset line itself and
confirms the transition. The reset line is described with the level
that asserts the reset as its active level, so that the driver can use
logical GPIO values for both methods.

Compile-tested only: dt_binding_check on the schema, and dtbs_check on
t8112-j413, t8112-j493, t6020-j414s, t6030-j514s, t6031-j514c,
t8122-j613 and t8140-j700 with no new warnings.

Assisted-by: LLM checkpatch dt_binding_check
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
DockChannel is a set of byte FIFOs between the application processor
and a coprocessor. Each channel has a host side and a remote side with
a configuration window and a data window each, and the channels of one
block share an interrupt window whose interrupts signal FIFO threshold
events. The apple,dockchannel node maps that interrupt window,
translates the channel windows for its children and is their interrupt
controller; the HID transport of the MTP coprocessor is its child.

The node has been in the T8112, T8122, T6020, T6030 and T6031 device
trees without a binding, and the T8140 (J700, MacBook Neo) adds a sixth
SoC. Describe it, with every in-tree SoC compatible, so that the
existing device trees validate unchanged.

Compile-tested only: dt_binding_check on the schema, and dtbs_check on
t8112-j413, t8112-j493, t6020-j414s, t6030-j514s, t6031-j514c,
t8122-j613 and t8140-j700 with no new warnings.

Assisted-by: LLM checkpatch dt_binding_check
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
dchid_handle_packet() checks the interface number of a received packet
against MAX_INTERFACES, logs an error and then indexes ifaces[] with it
anyway. The number is a byte from the coprocessor, so any value from
16 to 255 reads past the 16-entry array and uses whatever pointer it
finds there.

Drop the packet after logging the error, and re-arm the receive
callback as for every other malformed packet.

Compile-tested only; not run on hardware.

Fixes: 18cedb7 ("HID: Add Apple DockChannel HID transport driver")
Assisted-by: LLM checkpatch sparse
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
Every packet body starts with an eight-byte sub-header, but nothing
checked that the body was that long. dchid_packet_work() copies the
body into a work item sized exactly by the header's length field, so a
packet shorter than eight bytes made it read the sub-header past the
end of the allocation. dchid_handle_ack() read the sub-header from the
stale contents of the packet buffer. On top of that,
dchid_packet_work() returned without freeing the work item when the
sub-header's length did not fit the packet.

Reject bodies shorter than a sub-header in both paths, and free the
work item on every exit.

Compile-tested only; not run on hardware.

Fixes: 18cedb7 ("HID: Add Apple DockChannel HID transport driver")
Assisted-by: LLM checkpatch sparse
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
The init packet carries the interface name in a 16-byte field that the
firmware need not NUL-terminate. dchid_get_interface() compares it with
strcmp(), duplicates it with devm_kstrdup() and passes it to
alloc_ordered_workqueue(), all of which read on until they find a NUL,
so a 16-character name makes them read past the packet.

Copy the name into a terminated local buffer first.

Compile-tested only; not run on hardware.

Fixes: 18cedb7 ("HID: Add Apple DockChannel HID transport driver")
Assisted-by: LLM checkpatch sparse
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
Three places in the receive path trusted a length that the coprocessor
supplies. dchid_handle_event() reads the event type byte before
checking that the payload has one, so an empty payload read one byte
past the end of the work item. The GPIO request handler checked the
request structure against the bytes left in the packet instead of
against its own block length, so a short block was parsed from the
bytes of the blocks that follow it. The product name handler indexed
product[blk->length - 1], which for an empty block is the byte before
the name.

Return on an empty event payload, ignore a GPIO request block that is
shorter than the request structure, and treat an empty product name as
unterminated.

Compile-tested only; not run on hardware.

Fixes: 18cedb7 ("HID: Add Apple DockChannel HID transport driver")
Assisted-by: LLM checkpatch sparse
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
dchid_get_firmware() casts the start of the firmware file to its
20-byte header and checks the header's fields against the file size,
but never checks that the file holds a whole header. A truncated file
made it read past the end of the firmware data.

Reject files shorter than the header.

Compile-tested only; not run on hardware.

Fixes: 18cedb7 ("HID: Add Apple DockChannel HID transport driver")
Assisted-by: LLM checkpatch sparse
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
dchid_handle_ack() copies at most the caller's buffer size out of an
acknowledgment, but then records the full wire length of the reply as
the response size, which dchid_cmd() returns to its callers. A
GET_REPORT through dchid_raw_request() whose reply is longer than the
buffer therefore reports more bytes than it delivered. __hid_request()
passes that count to hid_input_report() as the size of a buffer it
allocated for the report's own length, so the excess is read from
beyond the buffer.

Record the number of bytes copied, plus the report ID byte, as the
response size instead. Callers that deliberately read a prefix of a
longer report, such as the 11-byte STM device ID read, still get the
bytes they asked for.

Compile-tested only; not run on hardware.

Fixes: 18cedb7 ("HID: Add Apple DockChannel HID transport driver")
Assisted-by: LLM checkpatch sparse
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
dchid_handle_packet() re-arms the receive callback at the end of every
packet, whether it was handled or dropped, except when the work item
for a report cannot be allocated: that path returns without re-arming,
and the transport never receives another packet. One failed allocation
therefore leaves the keyboard and trackpad dead until the next boot.

Drop the packet and re-arm the callback like every other error path.

Compile-tested only; not run on hardware.

Fixes: 18cedb7 ("HID: Add Apple DockChannel HID transport driver")
Assisted-by: LLM checkpatch sparse
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
dchid_get_interface() allocates an interface's ordered workqueue before
it looks for the interface's device tree node, and returns without
destroying the workqueue when there is no node. Every interface that
the coprocessor announces and the device tree does not describe leaks
a workqueue on every boot. The result of devm_kstrdup() is not checked
either, the device tree node reference is never dropped on failure,
and dockchannel_hid_probe() leaks the creation workqueue when the comm
interface cannot be set up.

Look the node up first, so that nothing is allocated for an interface
that is going to be ignored, check the name duplication, drop the node
reference on the remaining failure paths and destroy the creation
workqueue on the probe failure path.

Compile-tested only; not run on hardware.

Fixes: 18cedb7 ("HID: Add Apple DockChannel HID transport driver")
Assisted-by: LLM checkpatch sparse
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
The packet header's length field and the sub-header's length field are
both 16 bits wide. dchid_send() stores the padded message length plus
the sub-header size in the first and the message length in the second
without checking that they fit, so an oversized message goes out with
wrapped lengths and the coprocessor sees a corrupt packet. The GPIO
acknowledgment echoes the command it answers at whatever length the
coprocessor sent it, so such a message is not out of reach.

Return -EMSGSIZE for a message the header cannot describe.

Compile-tested only; not run on hardware.

Assisted-by: LLM checkpatch sparse
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
dockchannel_hid_remove() is BUG_ON(1): unloading the module or removing
the device crashes the machine. Replace it with an ordered teardown.
Mark the transport as stopping and disable the receive interrupt, so
that no new packet is parsed, no new work is queued and a receive
callback that is still running does not re-arm the interrupt behind
the teardown's back. Then flush and destroy the per-interface
workqueues, on which packets are parsed and interface creation is
queued, then the creation workqueue, and only then destroy the HID
devices and drop the device tree node references. Opens and raw
requests that arrive during the teardown fail with -ESHUTDOWN instead
of waiting for acknowledgments that cannot come.

The MTP coprocessor announces its interfaces only when it boots. After
an unbind the driver binds again, but the coprocessor is already
running and announces nothing, so the keyboard and trackpad stay
absent until the next boot. Disable the sysfs bind and unbind
attributes, and say in the Kconfig help that unloading and reloading
the module has the same effect. Restarting the coprocessor from Linux,
which would make both work, is separate work.

Compile-tested only; not run on hardware.

Assisted-by: LLM checkpatch sparse
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
The coprocessor's init packet can announce one GPIO per interface, with
an identifier that its GPIO commands then refer to. The driver used the
identifier itself as the marker that a GPIO was announced, so an
announcement with identifier 0 was forgotten: the interface start did
not request the line, a second announcement was not rejected, and the
first GPIO command requested the line on the spot.

Track the announcement in a flag of its own, so that identifier 0 is
handled like any other and a GPIO command for an interface that
announced no GPIO is rejected. For a GPIO announced with identifier 0
the line is now requested when the interface starts, as it already was
for every other identifier, instead of when the first GPIO command
arrives; the request leaves the line at its inactive level in both
cases. dchid_request_gpio() also returns the error it got instead of
-1, which is -EPERM.

Compile-tested only; not run on hardware.

Assisted-by: LLM checkpatch sparse
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
drivers/hid/Makefile adds the dockchannel-hid directory twice, four
lines apart. Keep the first entry.

Assisted-by: LLM checkpatch
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
macsmc_gpio_init_valid_mask() rejects a GPIO number greater than
MAX_GPIO, which lets number 64 through to set_bit() on the 64-bit valid
mask. The loop stops at the key of GPIO 63 before such a key can be
reached, so the out-of-bounds bit is not set in practice; make the
check match the mask all the same.

Compile-tested only; not run on hardware.

Fixes: 9b21051 ("gpio: Add new gpio-macsmc driver for Apple Macs")
Assisted-by: LLM checkpatch sparse
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
The J700 (MacBook Neo) resets its trackpad analog front end through the
SMC, but not through a gPxx GPIO key. The machine's Apple device tree
describes the reset as the platform function pKW8("pcIO", 0x10000,
0x130000): an eight-byte write to the pcIO key with 0x10000 in the low
word, 0x130000 in the high word and the requested level in bits 15:0.
Bits 23:16 of the high word hold the pin number, 19. The SMC has no
gP13 key for the pin, so the line is invisible to the GPIO provider as
it stands.

Expose it as GPIO 19 of the apple,smc-gpio chip on J700 and turn writes
to it into the pcIO payload. The pcIO key cannot be read back, so the
value returned for the line is the last one written, which is 0 after
boot whatever the hardware state is. Nothing changes on other machines,
and nothing changes for the other lines of the J700 chip. The
DockChannel HID driver drives this line during the trackpad's power
method 2 transitions.

Compile-tested only; not run on hardware.

Assisted-by: LLM checkpatch sparse
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
The MTP firmware of the M2 and M3 laptops powers the trackpad with what
Apple calls power method 1: after the host has sent the trackpad
firmware it sends a four-byte RESET_INTERFACE command for the OFF state
and one for the ON state, and the coprocessor sequences the trackpad
itself, asking the host to pulse the AFE reset line when it needs a
pulse.

The J700 (MacBook Neo) firmware uses power method 2 and accepts only
the nine-byte form of the command: the method in byte 1, the interface
in byte 2, the target state in byte 3 and a has-changed flag in byte 4.
Each transition is announced with the flag clear; the host then drives
the AFE reset line itself, asserting it for a power-off and holding it
for 50 ms, or releasing it for a power-on; and the transition is
confirmed with the flag set. After the firmware has been sent the
trackpad is taken through OFF and then ON, as with method 1. This is
the sequence recorded on the J700 during its bring-up.

Select the method with the apple,power-method property of the
multi-touch node, which defaults to 1, so that nothing changes on the
existing machines: they keep their two four-byte commands and keep
ignoring the commands' results. With method 2 the AFE reset line is
requested in probe, as soon as the device tree asks for the method, so
that a GPIO provider that has not probed yet defers the probe instead
of failing the first open; it is requested as-is, so that its level
does not change before the first transition has been announced. The
line is driven with logical values, and the J700 device tree describes
it with the level that asserts the reset as its active level. Should
the firmware also announce the line as a GPIO request, the same
descriptor serves the request.

Move the command encoders into a header of their own and add KUnit
tests for them, so that the wire format is pinned down without Apple
hardware. The method 2 encoder and the first two test cases are based
on work by Eryk Wieliczko for Aurora's tree (September 2026); Eryk
Wieliczko's Signed-off-by is outstanding.

Compile-tested only, including the KUnit test object; not run on
hardware.

Assisted-by: LLM checkpatch sparse
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
The transport starts the keyboard and trackpad interfaces only after
the STM interface has reported the machine's vendor and product IDs,
keyboard type and serial number, which go into the HID devices. The
J700 (MacBook Neo) MTP firmware announces no STM interface, so nothing
is ever started.

Let the device tree say so with apple,no-stm: the HID devices then get
Apple's vendor ID and no product ID, version or serial, and the
interfaces start as soon as they are announced. hid-apple and
hid-magicmouse match Apple's vendor ID with any product on the host
bus, so both still bind.

The J700 firmware also announces an interface named "mtp" that the
device tree does not describe. Interfaces without a node are ignored by
design, so log that at debug level instead of warning on every boot.

Compile-tested only; not run on hardware.

Assisted-by: LLM checkpatch sparse
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
The comments on struct tp_header and struct tp_mouse_report open with
"/**" but name no structure and describe only some of the members, so
a W=1 build warns "expecting prototype for struct vendor" and
"expecting prototype for struct standard". Give them the structure
names and the missing members.

Assisted-by: LLM checkpatch sparse
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
The trackpad of the J700 (MacBook Neo) is driven by Apple's C1FE
controller, and its MTP firmware sends report 0x75 in a layout the
driver does not accept: a 32-byte header instead of the 38-byte one,
then the contact records, then an 8-byte trailer. The header carries
the contact section length at offset 16, the trailer length at offset
20, the contact count at offset 22 and the button in bit 0 of offset
23; the contact records have the known 30-byte layout, of which only
the positions are known to be meaningful. The touch area field is zero
on some real contacts, and the controller has no force sensor.

Select the layout from the apple,j700-multitouch compatible of the
transport's multi-touch node, so that nothing changes for the other
laptops. Check the whole shape of a report before decoding it, and
drop a report that fails the check rather than fall through to the
other decoder; report every declared contact instead of filtering on
the touch area; and advertise only the position and button
capabilities, so that user space does not take a missing pressure for
a touch size.

The report layout and the decoding rules are based on LiamRay11's
description of the C1FE report for Aurora's tree, from a capture taken
on 2026-09-07; LiamRay11's Signed-off-by is outstanding.

Compile-tested only; not run on hardware.

Assisted-by: LLM checkpatch sparse
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
Write down the layout of the J700 trackpad's report 0x75 as
hid-magicmouse decodes it: the 32-byte header with its length, count
and button fields, the 30-byte contact records, of which only the
positions are decoded, and the 8-byte trailer, together with the
checks a report has to pass and what happens to one that fails them.
This is the format the C1FE controller's firmware was captured sending
on 2026-09-07; the earlier Apple Silicon laptops use a different
header, which is described only in the driver.

Based on LiamRay11's description of the C1FE report for Aurora's tree;
LiamRay11's Signed-off-by is outstanding.

Assisted-by: LLM checkpatch
Co-authored-by: Claude Fable 5.1 <[email protected]>
Signed-off-by: Ryan Murray <[email protected]>
@RyanTheTide
RyanTheTide force-pushed the series/neo-j700-hid-20260926 branch from 40b6436 to 98f1a1d Compare September 25, 2026 17:23
@RyanTheTide RyanTheTide changed the title HID: apple: support J700 DockChannel keyboard and trackpad HID: apple: J700 DockChannel keyboard and trackpad (reworked, 22 patches) Sep 25, 2026
@RyanTheTide
RyanTheTide marked this pull request as ready for review September 25, 2026 17:23
@RyanTheTide
RyanTheTide merged commit 16ed49a into aurora-wip Sep 25, 2026
@RyanTheTide
RyanTheTide deleted the series/neo-j700-hid-20260926 branch September 26, 2026 12:45
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