Skip to content

usb: misc: add a USB Billboard Device Class driver - #2253

Closed
RyanTheTide wants to merge 1 commit into
integration/aurorafrom
drvgap/usb-billboard
Closed

RyanTheTide wants to merge 1 commit into
integration/aurorafrom
drvgap/usb-billboard

Conversation

@RyanTheTide

Copy link
Copy Markdown
Contributor

What

A driver for the USB Billboard Device Class (class 0x11). Every USB-C dock, adapter or display with an Alternate Mode exposes a Billboard device, and until now it sat unbound (lsusb -t shows Driver=[none]). Example: the Realtek 0bda:5418 Billboard behind the RTS5411 hub in a Plugable UD-ULTC4K dock.

The driver binds to the Billboard interface, reads the Billboard Capability descriptor from the BOS the core already holds, plus any Billboard AUM Capability descriptors, and then:

  • exposes the descriptor in sysfs, readable without root: <intf>/billboard/{num_modes,preferred_mode,vconn_power,version,additional_failure_info,additional_info_url} and <intf>/billboard/altmode<N>/{svid,mode,vdo,state,description} (ABI doc included)
  • logs one line per mode at bind time. A mode the device reports as attempted-but-not-entered, or as an unspecified error, is logged as a warning, so a dock whose DisplayPort path failed now says so.

The descriptor structs go into uapi ch9.h. The driver sends nothing to the device beyond string descriptors. It does not depend on the SoC or board: it binds to any Billboard on any machine. CONFIG_USB_BILLBOARD=m is added to asahi.config.

Prior work

This follows Niklas Neronin's 2024 debugfs-only posting (https://lore.kernel.org/linux-usb/20240206125623.1208161-1-niklas.neronin@linux.intel.com/), which was never merged. Review there asked for the data outside debugfs and for the structs in uapi. This version does both and fixes that posting's bmConfigured decode, which shifted by the mode index instead of twice the index.

Tests

  • Out-of-tree build of the module against the 7.3.0-40 config (clang 22, W=1): 0 warnings. checkpatch --strict: 0 errors (the remaining warnings are the Co-Authored-By trailer and the MAINTAINERS prompt).
  • uapi block: gcc -std=c99 -pedantic -Werror clean; static asserts on the layout (cap 44 bytes + 4 per mode, AUM cap 8 bytes, bcdVersion at offset 40).
  • Hardware: see the comment below (MacBook Neo, dock Billboard 0bda:5418).

🤖 Generated with Claude Code

USB-C docks, adapters and displays that offer Alternate Modes expose a
USB 2.0 Billboard device (class 0x11). Its BOS carries a Billboard
Capability descriptor listing every mode the device container supports
(SVID, mode index, optional string) and a two-bit bmConfigured result per
mode telling the host whether the mode was entered, plus optional
Billboard AUM Capability descriptors with each mode's VDO. Linux has no
driver for the class, so these devices sit unbound in every dock (lsusb
-t shows Driver=[none]) and a dock whose DisplayPort path failed says
nothing.

Bind to the Billboard interface and:
 - expose the descriptor in sysfs under <interface>/billboard/
   (num_modes, preferred_mode, vconn_power, version,
   additional_failure_info, additional_info_url, and altmode<N>/ with
   svid, mode, vdo, state, description), readable without root;
 - log one line per mode at bind time, at warning level for modes the
   device reports as attempted-but-not-entered or as an unspecified error.

The descriptor layouts go into the uapi ch9.h so user space can share
them. The capability is copied at probe, since a device reset replaces
udev->bos. Nothing is sent to the device beyond the string descriptors
the core already reads.

This follows the 2024 debugfs posting by Niklas Neronin; review asked
for the data outside debugfs and for the structs in uapi, which this
does. It also fixes that posting's bmConfigured decode, which shifted
by the mode index instead of twice the index.

Tested on a Realtek RTS5411 dock billboard (0bda:5418, Billboard 1.21,
one DisplayPort mode, configured).

Link: https://lore.kernel.org/linux-usb/20240206125623.1208161-1-niklas.neronin@linux.intel.com/
Suggested-by: Niklas Neronin <niklas.neronin@linux.intel.com>
Signed-off-by: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@RyanTheTide

Copy link
Copy Markdown
Contributor Author

Superseded by #2263 (same change, updated commit trailers).

@RyanTheTide
RyanTheTide deleted the drvgap/usb-billboard branch November 19, 2026 11:49
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