u-boot-rockpro64: remove (MR 3824)

Use Alpine's u-boot package for rp64 instead.

[ci:skip-build]: already built successfully in CI
This commit is contained in:
Oliver Smith 2023-01-26 07:46:17 +01:00
parent 87d2de88c1
commit 78dffc2dbe
No known key found for this signature in database
GPG key ID: 5AE7F5513E0885CB
4 changed files with 0 additions and 231 deletions

View file

@ -1,51 +0,0 @@
From 1a01021c9361c4e017cb5b032300f5555c393710 Mon Sep 17 00:00:00 2001
From: dhivael <dhivael.git@eno.space>
Date: Sat, 11 Jan 2020 15:04:46 +0100
Subject: rk3399: light pinebook power and standby leds during early boot
this is a hack, but it works for now.
---
arch/arm/mach-rockchip/rk3399/rk3399.c | 12 +++++++++++-
1 file changed, 11 insertions(+), 1 deletion(-)
diff --git a/arch/arm/mach-rockchip/rk3399/rk3399.c b/arch/arm/mach-rockchip/rk3399/rk3399.c
index 863024d071..cf37129d55 100644
--- a/arch/arm/mach-rockchip/rk3399/rk3399.c
+++ b/arch/arm/mach-rockchip/rk3399/rk3399.c
@@ -15,6 +15,8 @@
#include <asm/arch-rockchip/grf_rk3399.h>
#include <asm/arch-rockchip/hardware.h>
#include <power/regulator.h>
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/pinctrl/rockchip.h>
DECLARE_GLOBAL_DATA_PTR;
@@ -115,8 +117,8 @@ void board_debug_uart_init(void)
struct rk3399_grf_regs * const grf = (void *)GRF_BASE;
#ifdef CONFIG_TARGET_CHROMEBOOK_BOB
struct rk3399_pmugrf_regs * const pmugrf = (void *)PMUGRF_BASE;
- struct rockchip_gpio_regs * const gpio = (void *)GPIO0_BASE;
#endif
+ struct rockchip_gpio_regs * const gpio = (void *)GPIO0_BASE;
#if defined(CONFIG_DEBUG_UART_BASE) && (CONFIG_DEBUG_UART_BASE == 0xff180000)
/* Enable early UART0 on the RK3399 */
@@ -149,6 +151,14 @@ void board_debug_uart_init(void)
spl_gpio_set_pull(&pmugrf->gpio0_p, GPIO(BANK_B, 4), GPIO_PULL_NORMAL);
#endif /* CONFIG_TARGET_CHROMEBOOK_BOB */
+ {
+ // set GPIO0_A2/B3 to GPIO_ACTIVE_HIGH
+ // set GPIO0_A2/B3 to OUTPUT
+ int mask = (1UL << RK_PA2) | (1UL << RK_PB3);
+ setbits_le32(&gpio->swport_dr, mask);
+ setbits_le32(&gpio->swport_ddr, mask);
+ }
+
/* Enable early UART2 channel C on the RK3399 */
rk_clrsetreg(&grf->gpio4c_iomux,
GRF_GPIO4C3_SEL_MASK,
--
cgit v1.2.3

View file

@ -1,24 +0,0 @@
The new u-boot releases bring up HDMI and USB and it causes the kernel or u-boot to hang
on most boot tries. USE_PREBOOT is disabled so USB won't be brought up which causes an hang
after 2020.10 and HDMI being on confuses Linux enough to break everything.
diff --git a/configs/rockpro64-rk3399_defconfig b/configs/rockpro64-rk3399_defconfig
index ae11a8f5eb..aa8f55639c 100644
--- a/configs/rockpro64-rk3399_defconfig
+++ b/configs/rockpro64-rk3399_defconfig
@@ -12,7 +12,7 @@ CONFIG_DEBUG_UART_CLOCK=24000000
CONFIG_SPL_SPI_FLASH_SUPPORT=y
CONFIG_SPL_SPI_SUPPORT=y
CONFIG_DEBUG_UART=y
-CONFIG_USE_PREBOOT=y
+CONFIG_USE_PREBOOT=n
CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-rockpro64.dtb"
CONFIG_DISPLAY_BOARDINFO_LATE=y
CONFIG_MISC_INIT_R=y
@@ -81,6 +81,6 @@ CONFIG_USB_ETHER_SMSC95XX=y
CONFIG_DM_VIDEO=y
CONFIG_DISPLAY=y
CONFIG_VIDEO_ROCKCHIP=y
-CONFIG_DISPLAY_ROCKCHIP_HDMI=y
+CONFIG_DISPLAY_ROCKCHIP_HDMI=n
CONFIG_SPL_TINY_MEMSET=y
CONFIG_ERRNO_STR=y

View file

@ -1,47 +0,0 @@
# Maintainer: Jean Lucas <jean@4ray.co>
# Co-Maintainer: Bart Ribbers <bribbers@disroot.org>
# U-boot RC built for rk3399, can be upstreamed to alpine soon when 2020.04 is released
pkgname=u-boot-rockpro64
pkgver=2021.07
pkgrel=2
pkgdesc="u-boot bootloader for the rk3399"
url="https://gitlab.com/pine64-org/u-boot"
arch="aarch64"
license="GPL-2.0-or-later OFL-1.1 BSD-2-Clause BSD-3-Clause eCos-2.0 IBM-pibs
ISC LGPL-2.0-only LGPL-2.1-only X11"
makedepends="$depends_dev bc dtc python3-dev swig bison flex openssl-dev arm-trusted-firmware"
options="!check"
source="
ftp://ftp.denx.de/pub/u-boot/u-boot-${pkgver//_/-}.tar.bz2
0000-rk3399-power-led.patch
0001-fix-boot-hang.patch
update-u-boot
"
builddir="$srcdir"/u-boot-${pkgver//_/-}
build() {
touch include/config.h
LC_ALL=C date +'#define U_BOOT_DATE "%b %d %C%y"' > include/timestamp_autogenerated.h
LC_ALL=C date +'#define U_BOOT_TIME "%T"' >> include/timestamp_autogenerated.h
export BL31="/usr/share/arm-trusted-firmware/rk3399/bl31.elf"
export BUILD_DIR="$builddir"/build
mkdir -p "$BUILD_DIR"
make O="$BUILD_DIR" HOSTCC=gcc ARCH=arm rockpro64-rk3399_defconfig
make O="$BUILD_DIR" HOSTCC=gcc ARCH=arm all
}
package() {
install -D -m644 build/u-boot-rockchip.bin \
"$pkgdir"/usr/share/u-boot/pine64-rockpro64/u-boot-rockchip.bin
install -D -m755 "$srcdir"/update-u-boot "$pkgdir"/usr/sbin/update-u-boot
}
sha512sums="
210b206a4626feb0985580d9448a97b499b09bf9b9313ca847a66624785e9e9b0fae8f2e329acd344f5f75cb722d2093dd0ee394311ddd1fde05e400ee71a24d u-boot-2021.07.tar.bz2
4495dbaceac1cc42b3506dda81e0920f8eca19e11e0d717637dba6e4623e95cd4c3c94e7fc3aa8f3cbfe5fcaf0c0c109d1699eb7f278a69fa8e209c7cd6e4c02 0000-rk3399-power-led.patch
7772b0a2a811b422dab491b6a97d82f6153c49288f92bcf0194c26303810ffb0242a479afcffc079d1262f4cc118726198764b5135b4aad4b69a95346eeef6e9 0001-fix-boot-hang.patch
8bd5e4236257f3a971f207ff3ae8f97358e6ec4a110fa14e675bf583e1f1ccacbc1e8d2c887ac66eb64369cd0d6c3beab7643d201592bb0ec1c66c8f27a58fc8 update-u-boot
"

View file

@ -1,109 +0,0 @@
#!/bin/sh
verbose=
board=
device=
dryrun=
imagedir=
get_defaults() {
if [ -z "$board" -a -e /sys/firmware/devicetree/base/compatible ]; then
case "$(cat /sys/firmware/devicetree/base/compatible 2>/dev/null)" in
pine64,rockpro64*) board=rockpro64 ;;
esac
fi
if [ -z "$device" ]; then
case "$board" in
rockpro64) device=/dev/mmcblk2 ;;
esac
fi
if [ -z "$imagedir" ]; then
imagedir="$(realpath $(dirname $0))"
[ -f "$imagedir/README.txt" ] || imagedir="/usr/share/u-boot"
fi
}
die() {
echo "ERROR: $@"
exit 1
}
usage() {
get_defaults
cat <<EOF
usage: $0 [-n,--dry-run] [-i,--imagedir <imagedir>] [-b|--board <board-type>] [-d|--device <device>]
options:
-b,--board <board> Specify the board type: rockpro64
(current default: ${board:-none})
-d,--device <device> Specify the device where to install u-boot
(current default: ${device:-none})
-i,--imagedir <imagedir> Specify u-boot image directory
(current default: ${imagedir:-none})
-n,--dry-run Print commands but don't execute them
EOF
}
while [ $# -gt 0 ]; do
opt="$1"
shift
case "$opt" in
-b|--board)
case "$1" in
rockpro64) board="rockpro64" ;;
*) usage; exit 1;;
esac
shift
;;
-d|--device)
device="$1"
shift
;;
-i|--imagedir)
imagedir="$1"
shift
;;
-n|--dry-run)
dryrun="echo"
;;
--)
break
;;
-*)
usage
exit 1
;;
esac
done
get_defaults
if [ -z "$board" -o -z "$device" -o -z "$imagedir" -o ! -e "$imagedir" ]; then
usage
exit 1
fi
if [ -z "$dryrun" ]; then
echo "Updating $board u-boot in $device in 3 seconds..."
sleep 3
fi
(
set -e
case "$board" in
rockpro64)
[ -e "$imagedir/pine64-rockpro64/" ] || die "rockpro64 images not installed, apk add u-boot-rockpro64"
$dryrun dd if=$imagedir/pine64-rockpro64/u-boot-rockchip.bin of=$device bs=1024 seek=32 status=none
;;
esac
$dryrun sync
) || die "U-Boot installation in $device failed"
[ -z "$dryrun" ] && echo "Completed successfully."