Signed-off-by: fbt <fbt@fleshless.org>
This commit is contained in:
2017-12-10 20:44:17 +03:00
parent e6f85aa437
commit d85b1945e9
115 changed files with 132 additions and 238 deletions

15
services/hwdetect Executable file
View File

@@ -0,0 +1,15 @@
#!/usr/bin/env ssm
service_type='oneshot'
service_command=( /usr/bin/true )
pre_start() {
printf '(${service_name}) Running module autodetect...\n'
# The Alpine Linux hwdetect script runs this twice. Apparently to make sure we get devices that appear after loading a module on the first run.
find /sys -name modalias -type f -print0 | xargs -0 sort -u | xargs modprobe -b -a 2>/dev/null
find /sys -name modalias -type f -print0 | xargs -0 sort -u | xargs modprobe -b -a 2>/dev/null
# This script cannot be regarded as failed. It has no definitive failure state.
return 0
}