fix(udev): restrict mode switching to intended devices and events

Take the aic.rules portion of #129: restrict 1111:1111 switching to
88M80 USB devices, target the event's bus/device address, and eject only
whole disks on add. Add selection fixtures and document the product
restriction. Keep installer paths and existing firmware handling unchanged.

Co-authored-by: rtk94 <richardtknepp@gmail.com>
(cherry picked from commit e2c5835767)
This commit is contained in:
Shen Mintao committed 2026-11-02 14:32:11 +08:00
1 parent 20fb7181e6
commit 3a71c7188b
3 files changed
+89 -11

No files matched your search

+5
View File
@@ -85,6 +85,11 @@ commands. Existing users must rerun `sudo ./install.sh` to replace the installed
usb_modeswitch configuration, then unplug the adapter completely and plug it
back in.
Automatic switching requires the USB product string to start with `88M80`.
Unrelated flash disks also use `1111:1111`, so that USB ID alone is not enough.
If your adapter reports a different product string, verify its identity before
trying the manual command below.
If automatic switching does not occur, try the same sequence manually:
```bash