Skip to content

fix(dra): load xz-compressed usbip kernel modules#2647

Merged
danilrwx merged 1 commit into
mainfrom
fix/dra/usbip-module-xz
Jul 14, 2026
Merged

fix(dra): load xz-compressed usbip kernel modules#2647
danilrwx merged 1 commit into
mainfrom
fix/dra/usbip-module-xz

Conversation

@danilrwx

@danilrwx danilrwx commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

Description

On nodes where the pre-installed usbip kernel modules are shipped compressed, the DRA USB driver failed to initialize with module ...usbip-core.ko.zst not found, so USB passthrough was unavailable on those nodes. Kernel modules can be compressed with any of the three formats the kernel supports (zstd, xz, gzip), but only .ko and .ko.zst were recognized. The driver now finds and decompresses .ko.xz and .ko.gz too, and the node-configuration check that installs the modules recognizes the same set of formats.

Why do we need it, and what problem does it solve?

Some distributions (e.g. the observed node shipped .ko.xz) compress kernel modules with xz or gzip instead of zstd. USB passthrough silently stayed broken on such nodes because the driver only knew about zstd. This makes module loading work regardless of the host's chosen compression format.

What is the expected result?

On a node whose usbip modules are .ko.xz (or .ko.gz), the DRA USB driver init loads the modules successfully and USB passthrough works, instead of failing with module not found.

Checklist

  • The code is covered by unit tests.
  • e2e tests passed.
  • Documentation updated according to the changes.
  • Changes were tested in the Kubernetes cluster manually.

Changelog entries

section:  core
type: fix
summary: "USB passthrough now works on nodes where usbip kernel modules are compressed with xz or gzip, not only zstd."
impact_level: low

@danilrwx danilrwx marked this pull request as ready for review July 13, 2026 11:46
@danilrwx danilrwx added this to the v1.10.0 milestone Jul 13, 2026
@danilrwx danilrwx force-pushed the fix/dra/usbip-module-xz branch 2 times, most recently from 615e270 to 4b8070c Compare July 13, 2026 11:48
@danilrwx danilrwx requested a review from Isteb4k as a code owner July 13, 2026 11:48
@danilrwx danilrwx force-pushed the fix/dra/usbip-module-xz branch from 4b8070c to d7e1748 Compare July 13, 2026 11:51
Comment thread images/virtualization-dra/pkg/modprobe/modprobe.go
@danilrwx danilrwx force-pushed the fix/dra/usbip-module-xz branch from d7e1748 to a635902 Compare July 13, 2026 20:51
@danilrwx danilrwx requested a review from yaroslavborbat July 13, 2026 20:51
Pre-installed usbip modules may ship compressed as .ko.xz or .ko.gz
depending on the host distribution, not only .ko or .ko.zst. Resolve all
kernel-supported compression suffixes (zstd, xz, gzip) in the module path
fallback and decompress accordingly before finit_module.

Signed-off-by: Daniil Antoshin <daniil.antoshin@flant.com>
@danilrwx danilrwx force-pushed the fix/dra/usbip-module-xz branch from a635902 to 2b19636 Compare July 13, 2026 20:52
@danilrwx danilrwx merged commit 2c86898 into main Jul 14, 2026
29 of 32 checks passed
@danilrwx danilrwx deleted the fix/dra/usbip-module-xz branch July 14, 2026 11:41
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.

2 participants