feat(deck): Add fix for suspend with some wifi adapters.

This commit is contained in:
Kyle Gospodnetich 2024-02-19 18:35:52 -08:00
parent 802cf35e64
commit c69297c255
2 changed files with 22 additions and 0 deletions

View File

@ -0,0 +1,2 @@
# Line separated list of modules to unload/reload at suspend/resume.
mt7921e

View File

@ -0,0 +1,20 @@
#!/bin/bash
# This file runs during sleep/resume events. It will read the list of modules
# in /etc/device-quirks/systemd-suspend-mods.conf and rmmod them on suspend,
# insmod them on resume.
# Originally created by ChimeraOS
MOD_LIST=$(grep -v ^\# /etc/device-quirks/systemd-suspend-mods.conf)
case $1 in
pre)
for mod in $MOD_LIST; do
modprobe -r $mod
done
;;
post)
for mod in $MOD_LIST; do
modprobe $mod
done
;;
esac