forked from armbian/build
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathhelios4.conf
More file actions
42 lines (39 loc) · 1.54 KB
/
helios4.conf
File metadata and controls
42 lines (39 loc) · 1.54 KB
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
# Marvell Armada 388 2GB ECC RAM SoC 4xSATA 2xUSB3.0 GBE SPI
BOARD_NAME="Helios4"
BOARD_VENDOR="kobol"
BOARDFAMILY="mvebu"
BOARD_MAINTAINER="leggewie"
INTRODUCED="2018"
BOOTCONFIG="helios4_defconfig"
BOOTCONFIG_NEXT="helios4_defconfig"
MODULES_LEGACY="marvell_cesa lm75"
MODULES_CURRENT="marvell_cesa lm75"
HAS_VIDEO_OUTPUT="no"
FORCE_BOOTSCRIPT_UPDATE="yes"
KERNEL_TARGET="current,edge"
KERNEL_TEST_TARGET="current"
# Enable btrfs support in u-boot
enable_extension "uboot-btrfs"
function post_family_config__helios4_extra_packages() {
add_packages_to_image "fancontrol"
add_packages_to_image "ethtool"
}
# J17 PWM on Helios4 depends on the out-of-tree timer-assignment patch, which
# is currently .disabled from mvebu-6.18 onwards (needs porting to the
# refactored pwm chip API). Comment out original J17 references in
# /etc/fancontrol so the service starts with J10-only; drop this hook once
# the patch is ported and re-enabled.
function post_family_tweaks_bsp__helios4_j17_disable_until_patch_ported() {
linux-version compare "${KERNEL_MAJOR_MINOR}" ge 6.18 || return 0
[[ -s "${destination}/etc/fancontrol" ]] || return 0
display_alert "${BOARD}" "fancontrol: commenting out J17 (no >=6.18 timer patch)" "info"
awk '
BEGIN { print "# J17 PWM disabled: mvebu >=6.18 lacks the timer-assignment patch." }
/\/dev\/fan-j17\/pwm1/ {
print "# " $0
gsub(/ ?\/dev\/fan-j17\/pwm1=[^ ]+/, "")
}
{ print }
' "${destination}/etc/fancontrol" > "${destination}/etc/fancontrol.new"
mv "${destination}/etc/fancontrol.new" "${destination}/etc/fancontrol"
}