Skip to content

fix(udev): don't treat usbip (vhci_hcd) devices as virtual - #827

Open
Jyers wants to merge 2 commits into
ShadowBlip:mainfrom
Jyers:fix/usbip-vhci-not-virtual
Open

Jyers wants to merge 2 commits into
ShadowBlip:mainfrom
Jyers:fix/usbip-vhci-not-virtual

Conversation

@Jyers

@Jyers Jyers commented Nov 28, 2026

Copy link
Copy Markdown

Proposed fix for #826, simply removes the filter for vhci_hcd devices.

Devices attached over USB/IP appear under a virtual vhci_hcd host
controller in sysfs (e.g. /devices/platform/vhci_hcd.0/usb7/...) even
though they represent real physical devices on the remote end. Treating
anything under vhci_hcd as virtual caused such devices to be ignored.
@ShadowApex

Copy link
Copy Markdown
Contributor

As mentioned in the issue related to this PR, we use vchi_hcd in order to emulate the Steam Deck controller at the USB level. This PR would cause recursive device creation if the user selects the Steam Deck controller target.

With vhci_hcd devices no longer treated as virtual, InputPlumber would
manage the vhci devices it generates itself (e.g. the Steam Deck target)
as source devices, creating an input feedback loop. Track the serial
numbers of vhci devices created by running target devices and deny only
those in the udev check, so external USB/IP devices are still managed
while self-generated ones are ignored.

@pastaq pastaq left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't hate this approach, but I'm wondering if we're making a mistake by codifying something so specific to one target device in the Manager.

There are other feedback loops we could close with internal properties (uhid, for example, has a similar problem). Perhaps we could serve a generic list of properties to the manager and have a standard retrieval on the TargetDevice trait, then it would make expansion of the interface easier.

I wouldn't expect you to do all the plumbing for every target device and subsystem, but I think it would be best to at least outline the shape of it and leave them stubbed in the the other targets for now.

Before you do that though, I'd like to know what @ShadowApex thinks about it first.

This branch has not been deployed

No deployments
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.

3 participants