Make YT6801 migration retry-safe
This commit is contained in:
1 parent
6d2069230e
commit
ea21c37d98
2 files changed
+34
-8
No files matched your search
@@ -26,12 +26,14 @@ omarchy-pkg-drop yt6801-dkms
|
||||
|
||||
if lsmod | awk '$1 == "yt6801" { found = 1 } END { exit !found }'; then
|
||||
sudo modprobe -r yt6801
|
||||
|
||||
for device in "${yt6801_devices[@]}"; do
|
||||
printf '%s\n' "$device" | sudo tee /sys/bus/pci/drivers_probe >/dev/null
|
||||
done
|
||||
fi
|
||||
|
||||
for device in "${yt6801_devices[@]}"; do
|
||||
if ! lspci -Dks "$device" | grep -Eq 'Kernel driver in use: dwmac[-_]motorcomm'; then
|
||||
printf '%s\n' "$device" | sudo tee /sys/bus/pci/drivers_probe >/dev/null
|
||||
fi
|
||||
done
|
||||
|
||||
for device in "${yt6801_devices[@]}"; do
|
||||
if ! lspci -Dks "$device" | grep -Eq 'Kernel driver in use: dwmac[-_]motorcomm'; then
|
||||
echo "YT6801 device $device did not bind to dwmac-motorcomm." >&2
|
||||
|
||||
Reference in new issue
Block a user