forked from pocopico/tinycore-redpill
-
Notifications
You must be signed in to change notification settings - Fork 0
/
knownfixes.sh
104 lines (74 loc) · 3 KB
/
knownfixes.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
#!/bin/bash
function knownfixes() {
PLATFORM="$1"
VERSION="$2"
case $PLATFORM in
ds3615xs)
case $VERSION in
\
7.1.0-42621)
echo sed -i 's/^acpi-cpufreq/# acpi-cpufreq/g' /mnt/dsmroot/usr/lib/modules-load.d/70-cpufreq-kernel.conf && cat /mnt/dsmroot/usr/lib/modules-load.d/70-cpufreq-kernel.conf
;;
*)
echo "$VERSION is not a known VERSION, or no fixes are available"
;;
esac
;;
dva3221)
case $VERSION in
\
7.1.0-42621)
echo sed -i 's/^acpi-cpufreq/# acpi-cpufreq/g' /mnt/dsmroot/usr/lib/modules-load.d/70-cpufreq-kernel.conf && cat /mnt/dsmroot/usr/lib/modules-load.d/70-cpufreq-kernel.conf
[ $(lspci -nn | grep -i nvidia | grep 300 | wc -l) -le 0 ] && echo sed -i 's/^/#/g' /mnt/dsmroot/usr/lib/modules-load.d/70-syno-nvidia-gpu.conf && cat /mnt/dsmroot/usr/lib/modules-load.d/70-syno-nvidia-gpu.conf
;;
\
*)
echo "$VERSION is not a known VERSION, or no fixes are available"
;;
esac
;;
ds3622xsp)
case $VERSION in
\
7.1.0-42621)
echo sed -i 's/^acpi-cpufreq/# acpi-cpufreq/g' /mnt/dsmroot/usr/lib/modules-load.d/70-cpufreq-kernel.conf && cat /mnt/dsmroot/usr/lib/modules-load.d/70-cpufreq-kernel.conf
;;
*)
echo "$VERSION is not a known VERSION, or no fixes are available"
;;
esac
;;
*)
echo "$PLATFORM is not a known PLATFORM, or no fixes are available"
;;
ds3617xs)
case $VERSION in
\
7.1.0-42621)
echo sed -i 's/^acpi-cpufreq/# acpi-cpufreq/g' /mnt/dsmroot/usr/lib/modules-load.d/70-cpufreq-kernel.conf && cat /mnt/dsmroot/usr/lib/modules-load.d/70-cpufreq-kernel.conf
;;
*)
echo "$VERSION is not a known VERSION, or no fixes are available"
;;
esac
;;
ds920p)
case $VERSION in
\
7.1.0-42621)
cd /home/tc/redpill-load ; ./ext-manager.sh add https://github.com/jumkey/redpill-load/raw/develop/redpill-dtb/rpext-index.json
cd /home/tc/redpill-load ; ./ext-manager.sh _update_platform_exts ds920p_42218
cp /home/tc/ds920p.dtb /home/tc/redpill-load/custom/extensions/jumkey.dtb/ds920p_42218/model_ds920p.dtb
echo sed -i 's/^acpi-cpufreq/# acpi-cpufreq/g' /mnt/dsmroot/usr/lib/modules-load.d/70-cpufreq-kernel.conf && cat /mnt/dsmroot/usr/lib/modules-load.d/70-cpufreq-kernel.conf
;;
*)
echo "$VERSION is not a known VERSION, or no fixes are available"
;;
esac
;;
*)
echo "$PLATFORM is not a known PLATFORM, or no fixes are available"
;;
esac
}
knownfixes $1 $2