17 Commits

Author SHA1 Message Date
Jiajie Chen
c9c25e6ffe Install versioned linux-modules-extra for the generic kernel
linux-modules-extra-generic is not a package name; the packages are versioned
as linux-modules-extra-<ver>-generic. Install it after detecting the generic
kernel version.
2026-09-04 02:01:11 +08:00
Jiajie Chen
defc096808 Boot the Ubuntu generic kernel in CI and load HID modules to verify the keyboard
The GitHub runner's Azure kernel has CONFIG_USB_HID disabled, so it cannot
enumerate the simulated HID keyboard over USB/IP. Install and boot the Ubuntu
generic kernel instead (which ships usbhid/hid-generic as modules and
usbip/cdc-acm in linux-modules-extra), bundle + load the full module chain
(hid, hid-generic, usbhid, usbip-core, vhci-hcd, cdc-acm) in the guest, and
restore the keyboard check as a gating assertion. Now both the CDC ACM serial
device and the HID keyboard are verified in CI.
2026-09-04 01:59:42 +08:00
Jiajie Chen
ff738948ec Decompress kernel modules and harden the usbip client copy
The Azure kernel does not load zstd/xz/gzip-compressed modules via insmod, so
decompress them to plain .ko when bundling the initramfs. Also copy the usbip
client to both /usr/sbin and /usr/bin (and its real path), and log its presence
in the guest for diagnostics.
2026-09-04 00:51:13 +08:00
Jiajie Chen
8d33603873 Install linux-modules-extra and handle compressed kernel modules
The GitHub runner uses an Azure kernel that does not ship the usbip /
cdc-acm modules by default; on Ubuntu those live in the separate
linux-modules-extra package. Install it and make the initramfs builder /
guest loader accept compressed kernel modules (.ko.zst, .ko.xz, .ko.gz).
2026-09-04 00:22:32 +08:00
Jiajie Chen
411e63f8e8 Add QEMU end-to-end test verifying simulated USB devices
Boot a real Linux inside QEMU and confirm that simulated USB/IP devices
work against a real kernel (vhci-hcd + cdc_acm):

- Add examples/demo.rs: a single server exporting a HID keyboard and a
  CDC ACM serial device on port 3240.
- Add scripts/qemu/: build a minimal initramfs (host kernel + busybox +
  usbip tool + demo server), boot it in QEMU, attach the simulated devices
  over 127.0.0.1, and verify:
    * the serial port emits 'a' (0x61)  -> SERIAL_TEST
    * the keyboard generates a KEY_1 input event -> KEYBOARD_TEST
- Add .github/workflows/qemu.yml to run this in CI (KVM when available,
  TCG fallback otherwise), uploading the serial console log as an artefact.
2026-09-04 00:16:40 +08:00
Jiajie Chen
a584b3713d Add stale bot 2025-06-13 17:17:59 +08:00
Jiajie Chen
c4f7a376b5 Drop broken coveralls 2025-03-24 14:15:43 +08:00
Jiajie Chen
5c00f965f9 Use nightly for coveralls 2024-10-26 10:49:05 +08:00
Jiajie Chen
066aeb15dc Use stable in ci 2024-10-26 10:40:24 +08:00
h7x4
db56238ace workflows/main.yml: enable all package features 2023-09-06 10:11:39 +02:00
h7x4
ff0d34af42 workflows/main.yml: add dependency cache 2023-09-01 13:54:50 +02:00
h7x4
0323a1ce0a workflows/main.yml: only run coveralls push on PRs 2023-09-01 13:54:33 +02:00
h7x4
511fd2926e workflows/main.yml: remove benchmark step
We don't have any benchmarks at the moment,
so this step is pointless
2023-09-01 13:54:24 +02:00
h7x4
0df4ae9296 workflows/main.yml: update external actions
- `actions/checkout@v2` -> `actions/checkout@v3`
- `actions-rs/toolchain@v1` -> `dtolnay/rust-toolchain@nightly`
2023-09-01 13:53:43 +02:00
h7x4
4b7a246add workflows/main.yml: parallellize workflow 2023-09-01 13:53:21 +02:00
h7x4
b840376fe4 Add clippy to pipeline 2023-08-24 16:20:46 +02:00
Jiajie Chen
3469ef77fa Setup github ci 2020-05-16 11:23:27 +08:00