mirror of
https://github.com/armbian/build
synced 2025-09-24 19:47:06 +07:00
Backport DTS/DTSI changes from linux-6.4.y to 6.1.y
Add meson64-reboot driver to all boards
Add board: ODROID N2L
Add uart_A uart_AO_B uart_B uart_C where appropriate
U-Boot v2023.07.02: ODROID N2/N2L/N2Plus/C4
Meson64-reboot driver: (source: tobetter)
While the current meson64-reboot driver is cleaner and doesn't
depend on modding other kernel sources, its functionality leaves
much to be desired. One example can be found in the ODROID C4.
Using the current driver, the board will not properly power off,
leaving the POWER LED still on. The new driver powers off the unit
completely.
Fan control: (ODROID N2L/N2PLus)
Added service and script for controlling the trip point.
fanctrl: arguments: 65 55 45 35 25 menu run
┌──┤ Fan Control ├──┐
│ │
│ 6) 65°C │
│ 5) 55°C │
│ 4) 45°C │
│ 3) 35°C │
│ 2) 25°C │
│ E) Exit .. │
│ │
│ │
│ <Ok> │
│ │
└───────────────────┘
NOTES: (N2L/HC4): I do not own the units so I can't run tests.
Signed-off-by: Patrick Yavitz <pyavitz@xxxxx.com>
50 lines
1.7 KiB
Plaintext
50 lines
1.7 KiB
Plaintext
# Amlogic S922X hexa core 2GB/4GB RAM SoC 1.8-2.4Ghz eMMC GBE USB3 SPI RTC
|
|
BOARD_NAME="Odroid N2L"
|
|
BOARDFAMILY="meson-g12b"
|
|
BOARD_MAINTAINER=""
|
|
KERNEL_TARGET="current,edge"
|
|
FULL_DESKTOP="yes"
|
|
FORCE_BOOTSCRIPT_UPDATE="yes"
|
|
BOOT_LOGO="desktop"
|
|
BOOTCONFIG="odroid-n2l_defconfig"
|
|
BOOTBRANCH_BOARD="tag:v2023.07.02"
|
|
BOOTPATCHDIR="v2023.07.02"
|
|
PACKAGE_LIST_BOARD="whiptail"
|
|
|
|
# MAX might be different for N2/N2+/N2L, for now use N2+'s
|
|
# @TODO: remove? cpufreq is not used anymore, instead DT should be patched
|
|
CPUMIN=1000000
|
|
CPUMAX=2400000
|
|
GOVERNOR=performance # some people recommend performance to avoid random hangs after 24+ hours running.
|
|
|
|
# U-boot has detection code for the ODROID boards.
|
|
# https://github.com/u-boot/u-boot/blob/v2021.04/board/amlogic/odroid-n2/odroid-n2.c#L35-L106
|
|
# Unfortunately it uses n2_plus instead of n2-plus as the Kernel expects it.
|
|
# So there is a hack at and around config/bootscripts/boot-meson64.cmd L90
|
|
# If needed (eg for extlinux) you can specify the N2/N2+/ DTB in BOOT_FDT_FILE, example for the N2+:
|
|
# BOOT_FDT_FILE="amlogic/meson-g12b-odroid-n2l.dtb"
|
|
|
|
function pre_customize_image__initialize_odroidn2_fanctrl_service() {
|
|
if [[ -f "$SRC/packages/bsp/odroid/fanctrl" ]]; then
|
|
mkdir -p $SDCARD/usr/bin/
|
|
display_alert "$BOARD" "Installing ODROID Fan Control" "info"
|
|
install -m 755 $SRC/packages/bsp/odroid/fanctrl $SDCARD/usr/bin/
|
|
fi
|
|
mkdir -p ${SDCARD}/etc/systemd/system/
|
|
cat <<- 'EOD' > "${SDCARD}/etc/systemd/system/fanctrl.service"
|
|
[Unit]
|
|
Description=ODROID Fan Control
|
|
ConditionPathExists=/usr/bin/fanctrl
|
|
After=rc-local.service armbian-hardware-optimize.service
|
|
|
|
[Service]
|
|
ExecStart=/usr/bin/fanctrl run &>/dev/null
|
|
Type=oneshot
|
|
RemainAfterExit=yes
|
|
|
|
[Install]
|
|
WantedBy=multi-user.target
|
|
EOD
|
|
chroot_sdcard systemctl enable fanctrl.service
|
|
}
|