Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place. Commercial Alternative to JupyterHub.
Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place. Commercial Alternative to JupyterHub.
Path: blob/next/external/config/sources/families/sun50iw9.conf
Views: 3960
source "${BASH_SOURCE%/*}/include/sunxi64_common.inc"12LINUXFAMILY=sun50iw934[[ -z $CPUMIN ]] && CPUMIN=4800005[[ -z $CPUMAX ]] && CPUMAX=15120006GOVERNOR=ondemand78ASOUND_STATE=asound.state.sun50iw9-${BRANCH}910case $BRANCH in1112legacy)1314KERNELBRANCH="branch:orange-pi-4.9-sun50iw9"15BOOTBRANCH='branch:v2018.05-sun50iw9'1617KERNELPATCHDIR=${BOARDFAMILY}-${BRANCH}18UBOOT_TARGET_MAP=";;dts/${BOARD}-u-boot.dts boot0_sdcard.fex boot_package.fex"19UBOOT_COMPILER="arm-linux-gnueabi-"20UBOOT_USE_GCC='> 6.0'21BOOTENV_FILE=sun50iw9-default.txt22BOOTSCRIPT='boot-sun50iw9.cmd:boot.cmd'23KERNEL_USE_GCC='> 10.0'24OFFSET=2025ATFSOURCE=""26ATF_COMPILE="no"27INITRD_ARCH=arm2829;;3031current)3233OVERLAY_PREFIX='sun50i-h616'34KERNELBRANCH="branch:orange-pi-5.4-sun50iw9"35#BOOTBRANCH='branch:u-boot-2018'36[[ $BOARD =~ orangepizero2 ]] && BOOTBRANCH='branch:v2018.05-sun50iw9'37[[ $BOARD =~ orangepizero3|orangepir1b|orangepizero2w ]] && BOOTBRANCH='branch:v2018.05-h618'3839KERNELPATCHDIR=${BOARDFAMILY}-${BRANCH}40UBOOT_TARGET_MAP=";;dts/${BOARD}-u-boot.dts boot0_sdcard.fex boot_package.fex"41UBOOT_COMPILER="arm-linux-gnueabi-"42UBOOT_USE_GCC='> 6.0'43BOOTENV_FILE=sun50iw9-default.txt44BOOTSCRIPT='boot-sun50iw9.cmd:boot.cmd'45KERNEL_USE_GCC='> 10.0'46OFFSET=2047ATFSOURCE=""48ATF_COMPILE="no"49INITRD_ARCH=arm5051;;5253next)5455OVERLAY_PREFIX='sun50i-h616'56ATFSOURCE='https://github.com/ARM-software/arm-trusted-firmware'57ATFBRANCH='commit:4b9be5abfa8b1a7c7e00776da01768d3358e648a'58ATF_PLAT="sun50i_h616";59ATF_TARGET_MAP='PLAT=sun50i_h616 DEBUG=1 bl31;;build/sun50i_h616/debug/bl31.bin'60UBOOT_TARGET_MAP=';;u-boot-sunxi-with-spl.bin'61[[ $BOARD =~ orangepizero2 ]] && BOOTBRANCH='branch:v2021.10-sunxi'62BOOTSCRIPT='boot-sun50iw9-next.cmd:boot.cmd'63if [[ $BOARD =~ orangepizero3|orangepir1b|orangepizero2w ]]; then64BOOTBRANCH='branch:v2024.01'65fi6667## For Linux5.16.y68#KERNELBRANCH="branch:orange-pi-5.16-sunxi64"69#LINUXCONFIG="linux-5.16-sun50iw9-current"7071## For Linu6.1.y72KERNELBRANCH="branch:orange-pi-6.1-sun50iw9"73LINUXCONFIG="linux-6.1-sun50iw9-next"74;;7576esac7778family_tweaks_s()79{80rsync -a --chown=root:root "${EXTER}"/packages/bsp/overlays_arm64/* ${SDCARD}/8182chroot $SDCARD /bin/bash -c "apt-get -y -qq install rfkill bluetooth bluez bluez-tools ir-keytable tree lirc v4l-utils dnsmasq" >/dev/null 2>&18384if [[ $BUILD_DESKTOP == yes ]]; then8586sed -i "s/auto-profiles = yes/auto-profiles = no/" ${SDCARD}/usr/share/pulseaudio/alsa-mixer/profile-sets/default.conf8788if [[ $BRANCH =~ legacy ]]; then89echo "load-module module-alsa-sink device=hw:0,0 sink_name=AudioCodec-Playback sink_properties=\"device.description='Audio Codec'\"" >> ${SDCARD}/etc/pulse/default.pa90echo "load-module module-alsa-sink device=hw:1,0 sink_name=HDMI-Playback sink_properties=\"device.description='HDMI Audio'\"" >> ${SDCARD}/etc/pulse/default.pa91elif [[ $BRANCH =~ current|next ]]; then92echo "load-module module-alsa-sink device=hw:0,0 sink_name=AudioCodec-Playback sink_properties=\"device.description='Audio Codec'\"" >> ${SDCARD}/etc/pulse/default.pa93echo "load-module module-alsa-sink device=hw:2,0 sink_name=HDMI-Playback sink_properties=\"device.description='HDMI Audio'\"" >> ${SDCARD}/etc/pulse/default.pa94fi95fi9697if [[ ${BRANCH} == current ]]; then98sed -i 's/^debug_uart.*/debug_uart=ttyAS0/' "${SDCARD}"/boot/orangepiEnv.txt99SERIALCON="ttyAS0"100fi101102install_wiringop103}104105family_tweaks_bsp()106{107108install -m 755 $EXTER/packages/blobs/bt/hciattach/hciattach_opi_${ARCH} $destination/usr/bin/hciattach_opi109110if [[ ${BOARD} == orangepizero2w ]]; then111install -m 755 $EXTER/packages/bsp/h618/sun50i-h618-lradc-keys-${BRANCH}.dts $destination/usr/src/sun50i-h618-lradc-keys.dts112fi113114}115116uboot_custom_postprocess()117{118119if [[ ${BRANCH} =~ legacy|current && $(dpkg --print-architecture) == amd64 ]]; then120121rm dts/*.dts sys_config ${BOARD}-u-boot-${BRANCH}.dtb -r >/dev/null 2>&1122export PATH=${EXTER}/packages/pack-uboot/${BOARDFAMILY}/tools/:$PATH123cp ${EXTER}/packages/pack-uboot/${BOARDFAMILY}/bin/* . -r124cp sys_config/sys_config_${BOARD}.fex sys_config.fex125cp u-boot.bin u-boot.fex126if [[ $KERNELBRANCH == "branch:orange-pi-5.4-sun50iw9" ]]; then127mv monitor.fex-linux5.4 monitor.fex128mv boot_package.cfg-linux5.4 boot_package.cfg129mv boot0_sdcard.fex-linux5.4 boot0_sdcard.fex130fi131cp dts/${BOARD}-u-boot-${BRANCH}.dts dts/${BOARD}-u-boot.dts132133# make u-boot dtb134$EXTER/packages/pack-uboot/${BOARDFAMILY}/tools/dtc -p 2048 -W no-unit_address_vs_reg -@ -O dtb -o ${BOARD}-u-boot.dtb -b 0 dts/${BOARD}-u-boot-${BRANCH}.dts >/dev/null 2>&1135[[ ! -f ${BOARD}-u-boot.dtb ]] && exit_with_error "dts compilation failed"136137busybox unix2dos sys_config.fex138$EXTER/packages/pack-uboot/${BOARDFAMILY}/tools/script sys_config.fex >/dev/null 2>&1139cp ${BOARD}-u-boot.dtb sunxi.fex140$EXTER/packages/pack-uboot/${BOARDFAMILY}/tools/update_dtb sunxi.fex 4096 >/dev/null 2>&1141142$EXTER/packages/pack-uboot/${BOARDFAMILY}/tools/update_uboot -no_merge u-boot.fex sys_config.bin >/dev/null 2>&1143update_uboot -no_merge u-boot.bin sys_config.bin >/dev/null 2>&1144145#pack boot package146busybox unix2dos boot_package.cfg147$EXTER/packages/pack-uboot/${BOARDFAMILY}/tools/dragonsecboot -pack boot_package.cfg >/dev/null 2>&1148149if [[ ${MERGE_UBOOT} == yes ]]; then150151display_alert "Merge u-boot" "u-boot-${BOARD}-merged.bin" "info"152dd if=/dev/zero of=u-boot-${BOARD}-merged.bin bs=1M count=20 > /dev/null 2>&1153dd if=boot0_sdcard.fex of=u-boot-${BOARD}-merged.bin bs=8k seek=1 conv=fsync > /dev/null 2>&1154dd if=boot_package.fex of=u-boot-${BOARD}-merged.bin bs=8k seek=2050 conv=fsync > /dev/null 2>&1155mv u-boot-${BOARD}-merged.bin ${DEB_STORAGE}/u-boot/156fi157fi158}159160161