Version Bump
This commit is contained in:
parent
af2200eeb9
commit
f0d3747b9e
@ -1,2 +1,2 @@
|
||||
DIST trusted-firmware-a-2.6.tar.gz 6007293 BLAKE2B 860efad37acab15478b725692ebd3ae88205b0048869cc5f3381a465646f789f929480d04552d7b26b31672e636651a00378c41a77f275acaff73ee6a3eedbab SHA512 bfd7df42abd51907264359463c5ab483fc82241fce9344df51dd89e6a65fc8a5c5b3c1481830c60dede8356326bd25f66516d623fda5bc2a9913000b8865ab37
|
||||
DIST u-boot-2022.01.tar.gz 20895074 BLAKE2B 9841f9b6b7afdf4df24e085a0addcdd78230d0c1ec405b9d4e6c798cc085b77e60cf68d811f209f5214b742afeaa43035bc664844725b5be6261ed861d917bce SHA512 9b9ff1536770397d4a95b903d18724ef46c3d142d8bc79aa1a9afe830bcfb28614035bf610a4cc388e0d0935d2b3bbd53cf9aa4b66873d897c3da5baa6c1b717
|
||||
DIST u-boot-2022.04.tar.gz 22791864 BLAKE2B 20c96c6035c8dd6b3aae985064231d48ce02feddf9f392f022a94cb82525ea93f5467f38afebf5733e095b7b0a3ad9142c25b543f4172eb334802f128e0db867 SHA512 41d86f0196c85cde4e96372e658d13ffc4caf3903a46ab52c7823d9444c246860a288e9d6b66cbdace092e749b3bc99514e1c82d2a59a2642db748f0880894bf
|
||||
|
@ -1,241 +0,0 @@
|
||||
From c4d3ac73a3f19d2372e3d35e833665b2ee1f11fa Mon Sep 17 00:00:00 2001
|
||||
From: Martijn Braam <martijn@brixit.nl>
|
||||
Date: Sat, 12 Dec 2020 13:31:03 +0100
|
||||
Subject: [PATCH 1/8] PPP
|
||||
|
||||
---
|
||||
arch/arm/mach-rockchip/rk3399/Kconfig | 7 ++
|
||||
board/pine64/pinephone-pro-rk3399/Kconfig | 15 +++
|
||||
board/pine64/pinephone-pro-rk3399/MAINTAINERS | 8 ++
|
||||
board/pine64/pinephone-pro-rk3399/Makefile | 1 +
|
||||
.../pinephone-pro-rk3399.c | 56 +++++++++++
|
||||
configs/pinephone-pro-rk3399_defconfig | 92 +++++++++++++++++++
|
||||
6 files changed, 179 insertions(+)
|
||||
create mode 100644 board/pine64/pinephone-pro-rk3399/Kconfig
|
||||
create mode 100644 board/pine64/pinephone-pro-rk3399/MAINTAINERS
|
||||
create mode 100644 board/pine64/pinephone-pro-rk3399/Makefile
|
||||
create mode 100644 board/pine64/pinephone-pro-rk3399/pinephone-pro-rk3399.c
|
||||
create mode 100644 configs/pinephone-pro-rk3399_defconfig
|
||||
|
||||
diff --git a/arch/arm/mach-rockchip/rk3399/Kconfig b/arch/arm/mach-rockchip/rk3399/Kconfig
|
||||
index 17628f9171..35b1125906 100644
|
||||
--- a/arch/arm/mach-rockchip/rk3399/Kconfig
|
||||
+++ b/arch/arm/mach-rockchip/rk3399/Kconfig
|
||||
@@ -28,6 +28,13 @@ config TARGET_PINEBOOK_PRO_RK3399
|
||||
with 4Gb RAM, onboard eMMC, USB-C, a USB3 and USB2 port,
|
||||
1920*1080 screen and all the usual laptop features.
|
||||
|
||||
+config TARGET_PINEPHONE_PRO_RK3399
|
||||
+ bool "PinePhone Pro"
|
||||
+ help
|
||||
+ PinePhone Pro is a phone based on the Rockchip rk3399 SoC
|
||||
+ with 4Gb RAM, onboard eMMC, USB-C, a headphone jack,
|
||||
+ 720x1440 screen and an external Quectel USB modem.
|
||||
+
|
||||
config TARGET_PUMA_RK3399
|
||||
bool "Theobroma Systems RK3399-Q7 (Puma)"
|
||||
help
|
||||
diff --git a/board/pine64/pinephone-pro-rk3399/Kconfig b/board/pine64/pinephone-pro-rk3399/Kconfig
|
||||
new file mode 100644
|
||||
index 0000000000..13d6465ae6
|
||||
--- /dev/null
|
||||
+++ b/board/pine64/pinephone-pro-rk3399/Kconfig
|
||||
@@ -0,0 +1,15 @@
|
||||
+if TARGET_PINEPHONE_PRO_RK3399
|
||||
+
|
||||
+config SYS_BOARD
|
||||
+ default "pinephone-pro-rk3399"
|
||||
+
|
||||
+config SYS_VENDOR
|
||||
+ default "pine64"
|
||||
+
|
||||
+config SYS_CONFIG_NAME
|
||||
+ default "pinephone-pro-rk3399"
|
||||
+
|
||||
+config BOARD_SPECIFIC_OPTIONS
|
||||
+ def_bool y
|
||||
+
|
||||
+endif
|
||||
diff --git a/board/pine64/pinephone-pro-rk3399/MAINTAINERS b/board/pine64/pinephone-pro-rk3399/MAINTAINERS
|
||||
new file mode 100644
|
||||
index 0000000000..227c1c0bea
|
||||
--- /dev/null
|
||||
+++ b/board/pine64/pinephone-pro-rk3399/MAINTAINERS
|
||||
@@ -0,0 +1,8 @@
|
||||
+PINEBOOK_PRO
|
||||
+M: Peter Robinson <pbrobinson@gmail.com>
|
||||
+S: Maintained
|
||||
+F: board/pine64/rk3399-pinebook-pro/
|
||||
+F: include/configs/rk3399-pinebook-pro.h
|
||||
+F: arch/arm/dts/rk3399-pinebook-pro.dts
|
||||
+F: arch/arm/dts/rk3399-pinebook-pro-u-boot.dtsi
|
||||
+F: configs/pinebook-pro-rk3399_defconfig
|
||||
diff --git a/board/pine64/pinephone-pro-rk3399/Makefile b/board/pine64/pinephone-pro-rk3399/Makefile
|
||||
new file mode 100644
|
||||
index 0000000000..8d9203053e
|
||||
--- /dev/null
|
||||
+++ b/board/pine64/pinephone-pro-rk3399/Makefile
|
||||
@@ -0,0 +1 @@
|
||||
+obj-y += pinephone-pro-rk3399.o
|
||||
diff --git a/board/pine64/pinephone-pro-rk3399/pinephone-pro-rk3399.c b/board/pine64/pinephone-pro-rk3399/pinephone-pro-rk3399.c
|
||||
new file mode 100644
|
||||
index 0000000000..d79084614f
|
||||
--- /dev/null
|
||||
+++ b/board/pine64/pinephone-pro-rk3399/pinephone-pro-rk3399.c
|
||||
@@ -0,0 +1,56 @@
|
||||
+// SPDX-License-Identifier: GPL-2.0+
|
||||
+/*
|
||||
+ * (C) Copyright 2019 Vasily Khoruzhick <anarsoul@gmail.com>
|
||||
+ */
|
||||
+
|
||||
+#include <common.h>
|
||||
+#include <dm.h>
|
||||
+#include <init.h>
|
||||
+#include <syscon.h>
|
||||
+#include <asm/io.h>
|
||||
+#include <asm/arch-rockchip/clock.h>
|
||||
+#include <asm/arch-rockchip/grf_rk3399.h>
|
||||
+#include <asm/arch-rockchip/hardware.h>
|
||||
+#include <asm/arch-rockchip/misc.h>
|
||||
+
|
||||
+#define GRF_IO_VSEL_BT565_SHIFT 0
|
||||
+#define PMUGRF_CON0_VSEL_SHIFT 8
|
||||
+
|
||||
+#ifdef CONFIG_MISC_INIT_R
|
||||
+static void setup_iodomain(void)
|
||||
+{
|
||||
+ struct rk3399_grf_regs *grf =
|
||||
+ syscon_get_first_range(ROCKCHIP_SYSCON_GRF);
|
||||
+ struct rk3399_pmugrf_regs *pmugrf =
|
||||
+ syscon_get_first_range(ROCKCHIP_SYSCON_PMUGRF);
|
||||
+
|
||||
+ /* BT565 is in 1.8v domain */
|
||||
+ rk_setreg(&grf->io_vsel, 1 << GRF_IO_VSEL_BT565_SHIFT);
|
||||
+
|
||||
+ /* Set GPIO1 1.8v/3.0v source select to PMU1830_VOL */
|
||||
+ rk_setreg(&pmugrf->soc_con0, 1 << PMUGRF_CON0_VSEL_SHIFT);
|
||||
+}
|
||||
+
|
||||
+int misc_init_r(void)
|
||||
+{
|
||||
+ const u32 cpuid_offset = 0x7;
|
||||
+ const u32 cpuid_length = 0x10;
|
||||
+ u8 cpuid[cpuid_length];
|
||||
+ int ret;
|
||||
+
|
||||
+ setup_iodomain();
|
||||
+
|
||||
+ ret = rockchip_cpuid_from_efuse(cpuid_offset, cpuid_length, cpuid);
|
||||
+ if (ret)
|
||||
+ return ret;
|
||||
+
|
||||
+ ret = rockchip_cpuid_set(cpuid, cpuid_length);
|
||||
+ if (ret)
|
||||
+ return ret;
|
||||
+
|
||||
+ ret = rockchip_setup_macaddr();
|
||||
+
|
||||
+ return ret;
|
||||
+}
|
||||
+
|
||||
+#endif
|
||||
diff --git a/configs/pinephone-pro-rk3399_defconfig b/configs/pinephone-pro-rk3399_defconfig
|
||||
new file mode 100644
|
||||
index 0000000000..320ce65ffb
|
||||
--- /dev/null
|
||||
+++ b/configs/pinephone-pro-rk3399_defconfig
|
||||
@@ -0,0 +1,92 @@
|
||||
+CONFIG_ARM=y
|
||||
+CONFIG_ARCH_ROCKCHIP=y
|
||||
+CONFIG_SYS_TEXT_BASE=0x00200000
|
||||
+CONFIG_NR_DRAM_BANKS=1
|
||||
+CONFIG_ENV_SIZE=0x8000
|
||||
+CONFIG_ROCKCHIP_RK3399=y
|
||||
+CONFIG_TARGET_PINEPHONE_PRO_RK3399=y
|
||||
+CONFIG_DEBUG_UART_BASE=0xFF1A0000
|
||||
+CONFIG_DEBUG_UART_CLOCK=24000000
|
||||
+CONFIG_SPL_SPI_FLASH_SUPPORT=y
|
||||
+CONFIG_SPL_SPI_SUPPORT=y
|
||||
+CONFIG_DEFAULT_DEVICE_TREE="rk3399-pinephone-pro"
|
||||
+CONFIG_DEBUG_UART=y
|
||||
+CONFIG_BOOTDELAY=3
|
||||
+CONFIG_USE_PREBOOT=y
|
||||
+CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-pinephone-pro.dtb"
|
||||
+CONFIG_DISPLAY_BOARDINFO_LATE=y
|
||||
+CONFIG_MISC_INIT_R=y
|
||||
+# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
|
||||
+CONFIG_SPL_STACK_R=y
|
||||
+CONFIG_SPL_STACK_R_MALLOC_SIMPLE_LEN=0x10000
|
||||
+CONFIG_SPL_MTD_SUPPORT=y
|
||||
+CONFIG_SPL_SPI_LOAD=y
|
||||
+CONFIG_TPL=y
|
||||
+CONFIG_CMD_BOOTZ=y
|
||||
+CONFIG_CMD_GPIO=y
|
||||
+CONFIG_CMD_GPT=y
|
||||
+CONFIG_CMD_I2C=y
|
||||
+CONFIG_CMD_MMC=y
|
||||
+CONFIG_CMD_PCI=y
|
||||
+CONFIG_CMD_USB=y
|
||||
+# CONFIG_CMD_SETEXPR is not set
|
||||
+CONFIG_CMD_TIME=y
|
||||
+CONFIG_CMD_PMIC=y
|
||||
+CONFIG_CMD_REGULATOR=y
|
||||
+CONFIG_SPL_OF_CONTROL=y
|
||||
+CONFIG_OF_SPL_REMOVE_PROPS="pinctrl-0 pinctrl-names clock-names interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents"
|
||||
+CONFIG_ENV_IS_IN_SPI_FLASH=y
|
||||
+CONFIG_SYS_RELOC_GD_ENV_ADDR=y
|
||||
+CONFIG_ROCKCHIP_GPIO=y
|
||||
+CONFIG_SYS_I2C_ROCKCHIP=y
|
||||
+CONFIG_DM_KEYBOARD=y
|
||||
+CONFIG_LED=y
|
||||
+CONFIG_LED_GPIO=y
|
||||
+CONFIG_MISC=y
|
||||
+CONFIG_ROCKCHIP_EFUSE=y
|
||||
+CONFIG_MMC_DW=y
|
||||
+CONFIG_MMC_DW_ROCKCHIP=y
|
||||
+CONFIG_MMC_SDHCI=y
|
||||
+CONFIG_MMC_SDHCI_SDMA=y
|
||||
+CONFIG_MMC_SDHCI_ROCKCHIP=y
|
||||
+CONFIG_SF_DEFAULT_SPEED=20000000
|
||||
+CONFIG_SPI_FLASH_GIGADEVICE=y
|
||||
+CONFIG_SPI_FLASH_WINBOND=y
|
||||
+CONFIG_DM_ETH=y
|
||||
+CONFIG_NVME=y
|
||||
+CONFIG_PCI=y
|
||||
+CONFIG_PHY_ROCKCHIP_INNO_USB2=y
|
||||
+CONFIG_PHY_ROCKCHIP_TYPEC=y
|
||||
+CONFIG_DM_PMIC_FAN53555=y
|
||||
+CONFIG_PMIC_RK8XX=y
|
||||
+CONFIG_REGULATOR_PWM=y
|
||||
+CONFIG_REGULATOR_RK8XX=y
|
||||
+CONFIG_PWM_ROCKCHIP=y
|
||||
+CONFIG_RAM_RK3399_LPDDR4=y
|
||||
+CONFIG_DM_RESET=y
|
||||
+CONFIG_DM_RNG=y
|
||||
+CONFIG_RNG_ROCKCHIP=y
|
||||
+CONFIG_BAUDRATE=1500000
|
||||
+CONFIG_DEBUG_UART_SHIFT=2
|
||||
+CONFIG_ROCKCHIP_SPI=y
|
||||
+CONFIG_SYSRESET=y
|
||||
+CONFIG_USB=y
|
||||
+CONFIG_USB_XHCI_HCD=y
|
||||
+CONFIG_USB_XHCI_DWC3=y
|
||||
+CONFIG_USB_EHCI_HCD=y
|
||||
+CONFIG_USB_EHCI_GENERIC=y
|
||||
+CONFIG_USB_OHCI_HCD=y
|
||||
+CONFIG_USB_OHCI_GENERIC=y
|
||||
+CONFIG_USB_DWC3=y
|
||||
+CONFIG_USB_DWC3_GENERIC=y
|
||||
+CONFIG_USB_KEYBOARD=y
|
||||
+CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE=y
|
||||
+CONFIG_USB_HOST_ETHER=y
|
||||
+CONFIG_USB_ETHER_ASIX=y
|
||||
+CONFIG_USB_ETHER_RTL8152=y
|
||||
+CONFIG_DM_VIDEO=y
|
||||
+CONFIG_DISPLAY=y
|
||||
+CONFIG_VIDEO_ROCKCHIP=y
|
||||
+CONFIG_DISPLAY_ROCKCHIP_EDP=y
|
||||
+CONFIG_SPL_TINY_MEMSET=y
|
||||
+CONFIG_ERRNO_STR=y
|
||||
--
|
||||
2.33.0
|
@ -1,25 +0,0 @@
|
||||
From 6e64cdb39e4452315cf9a4d1e9e89691403c3089 Mon Sep 17 00:00:00 2001
|
||||
From: Martijn Braam <martijn@brixit.nl>
|
||||
Date: Sun, 13 Dec 2020 19:36:14 +0100
|
||||
Subject: [PATCH 3/8] Config changes
|
||||
|
||||
---
|
||||
configs/pinephone-pro-rk3399_defconfig | 2 --
|
||||
1 file changed, 2 deletions(-)
|
||||
|
||||
diff --git a/configs/pinephone-pro-rk3399_defconfig b/configs/pinephone-pro-rk3399_defconfig
|
||||
index 320ce65ffb..1c2e7f278d 100644
|
||||
--- a/configs/pinephone-pro-rk3399_defconfig
|
||||
+++ b/configs/pinephone-pro-rk3399_defconfig
|
||||
@@ -53,8 +53,6 @@ CONFIG_SF_DEFAULT_SPEED=20000000
|
||||
CONFIG_SPI_FLASH_GIGADEVICE=y
|
||||
CONFIG_SPI_FLASH_WINBOND=y
|
||||
CONFIG_DM_ETH=y
|
||||
-CONFIG_NVME=y
|
||||
-CONFIG_PCI=y
|
||||
CONFIG_PHY_ROCKCHIP_INNO_USB2=y
|
||||
CONFIG_PHY_ROCKCHIP_TYPEC=y
|
||||
CONFIG_DM_PMIC_FAN53555=y
|
||||
--
|
||||
2.33.0
|
||||
|
@ -1,24 +0,0 @@
|
||||
From 4101d635fb8d82a5f6e63decccddfcfdea9f081e Mon Sep 17 00:00:00 2001
|
||||
From: Martijn Braam <martijn@brixit.nl>
|
||||
Date: Sun, 13 Dec 2020 19:48:37 +0100
|
||||
Subject: [PATCH 4/8] Add kconfig include
|
||||
|
||||
---
|
||||
arch/arm/mach-rockchip/rk3399/Kconfig | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/arch/arm/mach-rockchip/rk3399/Kconfig b/arch/arm/mach-rockchip/rk3399/Kconfig
|
||||
index 35b1125906..3ba603ca80 100644
|
||||
--- a/arch/arm/mach-rockchip/rk3399/Kconfig
|
||||
+++ b/arch/arm/mach-rockchip/rk3399/Kconfig
|
||||
@@ -161,6 +161,7 @@ endif # BOOTCOUNT_LIMIT
|
||||
source "board/firefly/roc-pc-rk3399/Kconfig"
|
||||
source "board/google/gru/Kconfig"
|
||||
source "board/pine64/pinebook-pro-rk3399/Kconfig"
|
||||
+source "board/pine64/pinephone-pro-rk3399/Kconfig"
|
||||
source "board/pine64/rockpro64_rk3399/Kconfig"
|
||||
source "board/rockchip/evb_rk3399/Kconfig"
|
||||
source "board/theobroma-systems/puma_rk3399/Kconfig"
|
||||
--
|
||||
2.33.0
|
||||
|
@ -1,41 +0,0 @@
|
||||
From 13c8c6945856e57958fdf7e4ef338c21e1199f19 Mon Sep 17 00:00:00 2001
|
||||
From: Martijn Braam <martijn@brixit.nl>
|
||||
Date: Sun, 13 Dec 2020 19:52:09 +0100
|
||||
Subject: [PATCH 5/8] Add pinephone-pro-rk3399.h
|
||||
|
||||
---
|
||||
include/configs/pinephone-pro-rk3399.h | 22 ++++++++++++++++++++++
|
||||
1 file changed, 22 insertions(+)
|
||||
create mode 100644 include/configs/pinephone-pro-rk3399.h
|
||||
|
||||
diff --git a/include/configs/pinephone-pro-rk3399.h b/include/configs/pinephone-pro-rk3399.h
|
||||
new file mode 100644
|
||||
index 0000000000..aaaa344839
|
||||
--- /dev/null
|
||||
+++ b/include/configs/pinephone-pro-rk3399.h
|
||||
@@ -0,0 +1,22 @@
|
||||
+/* SPDX-License-Identifier: GPL-2.0+ */
|
||||
+/*
|
||||
+ * Copyright (C) 2016 Rockchip Electronics Co., Ltd
|
||||
+ * Copyright (C) 2020 Peter Robinson <pbrobinson at gmail.com>
|
||||
+ */
|
||||
+
|
||||
+#ifndef __PINEPHONE_PRO_RK3399_H
|
||||
+#define __PINEPHONE_PRO_RK3399_H
|
||||
+
|
||||
+#define ROCKCHIP_DEVICE_SETTINGS \
|
||||
+ "stdin=serial,usbkbd\0" \
|
||||
+ "stdout=serial,vidconsole\0" \
|
||||
+ "stderr=serial,vidconsole\0"
|
||||
+
|
||||
+#include <configs/rk3399_common.h>
|
||||
+
|
||||
+#define SDRAM_BANK_SIZE (2UL << 30)
|
||||
+
|
||||
+#define CONFIG_USB_OHCI_NEW
|
||||
+#define CONFIG_SYS_USB_OHCI_MAX_ROOT_PORTS 2
|
||||
+
|
||||
+#endif
|
||||
--
|
||||
2.33.0
|
||||
|
@ -1,23 +0,0 @@
|
||||
From 3e8d6e4d57dd15acf104a8f11ff18833f8d7adc7 Mon Sep 17 00:00:00 2001
|
||||
From: Martijn Braam <martijn@brixit.nl>
|
||||
Date: Sun, 13 Dec 2020 19:57:49 +0100
|
||||
Subject: [PATCH 6/8] Added dts to makefile
|
||||
|
||||
---
|
||||
arch/arm/dts/Makefile | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
|
||||
index e2e8a5fb7a..ff07ae0270 100644
|
||||
--- a/arch/arm/dts/Makefile
|
||||
+++ b/arch/arm/dts/Makefile
|
||||
@@ -135,6 +135,7 @@ dtb-$(CONFIG_ROCKCHIP_RK3399) += \
|
||||
rk3399-nanopi-r4s.dtb \
|
||||
rk3399-orangepi.dtb \
|
||||
rk3399-pinebook-pro.dtb \
|
||||
+ rk3399-pinephone-pro.dtb \
|
||||
rk3399-puma-haikou.dtb \
|
||||
rk3399-roc-pc.dtb \
|
||||
rk3399-roc-pc-mezzanine.dtb \
|
||||
--
|
||||
2.33.0
|
@ -1,24 +0,0 @@
|
||||
From 19150d65b1bed6831ba92a4cf3e7262518f1049f Mon Sep 17 00:00:00 2001
|
||||
From: Martijn Braam <martijn@brixit.nl>
|
||||
Date: Sun, 13 Dec 2020 20:02:56 +0100
|
||||
Subject: [PATCH 7/8] u-boot.dtsi fixes
|
||||
|
||||
---
|
||||
arch/arm/dts/rk3399-pinephone-pro-u-boot.dtsi | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/arch/arm/dts/rk3399-pinephone-pro-u-boot.dtsi b/arch/arm/dts/rk3399-pinephone-pro-u-boot.dtsi
|
||||
index 7a058477db..e52263aafe 100644
|
||||
--- a/arch/arm/dts/rk3399-pinephone-pro-u-boot.dtsi
|
||||
+++ b/arch/arm/dts/rk3399-pinephone-pro-u-boot.dtsi
|
||||
@@ -12,7 +12,7 @@
|
||||
};
|
||||
|
||||
chosen {
|
||||
- u-boot,spl-boot-order = "same-as-spl", &sdhci, &spiflash, &sdmmc;
|
||||
+ u-boot,spl-boot-order = "same-as-spl", &sdhci, &sdmmc;
|
||||
};
|
||||
|
||||
config {
|
||||
--
|
||||
2.33.0
|
@ -1,44 +0,0 @@
|
||||
From b212ad24a604b00b240add35516b7381965deb31 Mon Sep 17 00:00:00 2001
|
||||
From: Alex Bee <knaerzche@gmail.com>
|
||||
Date: Thu, 17 Jun 2021 11:01:12 +0200
|
||||
Subject: [PATCH] rockchip: Fix MMC boot order
|
||||
|
||||
Basically all, i.e. rk3036.dtsi, rk3128.dtsi, rk3xxx.dtsi, rk322x.dtsi,
|
||||
rk3288.dtsi, rk3308-u-boot.dtsi, rk3328-u-boot.dtsi, rk3399-u-boot.dtsi
|
||||
and px30-u-boot.dtsi Rockchip SoC devicetrees which have mmc indexes
|
||||
are defining eMMC as mmc0 and sdmmc as mmc1.
|
||||
This means that the rule to try to boot from the SD card first is ignored,
|
||||
which as per comment is what we want and is important for distros, which
|
||||
rely on that.
|
||||
|
||||
Fix this by setting the correct mmc index, i.e. first from mmc1 (SD card),
|
||||
second from mmc0 (eMMC).
|
||||
|
||||
Signed-off-by: Alex Bee <knaerzche@gmail.com>
|
||||
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
|
||||
---
|
||||
include/configs/rockchip-common.h | 6 +++---
|
||||
1 file changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/include/configs/rockchip-common.h b/include/configs/rockchip-common.h
|
||||
index 0b9e24d1db..ba7061a287 100644
|
||||
--- a/include/configs/rockchip-common.h
|
||||
+++ b/include/configs/rockchip-common.h
|
||||
@@ -14,11 +14,11 @@
|
||||
|
||||
#ifndef CONFIG_SPL_BUILD
|
||||
|
||||
-/* First try to boot from SD (index 0), then eMMC (index 1) */
|
||||
+/* First try to boot from SD (index 1), then eMMC (index 0) */
|
||||
#if CONFIG_IS_ENABLED(CMD_MMC)
|
||||
#define BOOT_TARGET_MMC(func) \
|
||||
- func(MMC, mmc, 0) \
|
||||
- func(MMC, mmc, 1)
|
||||
+ func(MMC, mmc, 1) \
|
||||
+ func(MMC, mmc, 0)
|
||||
#else
|
||||
#define BOOT_TARGET_MMC(func)
|
||||
#endif
|
||||
--
|
||||
GitLab
|
||||
|
@ -1,24 +1,65 @@
|
||||
From 98b43f8c80a3ce16363f6a386b23bda10a738ffa Mon Sep 17 00:00:00 2001
|
||||
From eea38c80ff858222e15ba4d79a0cb811adbdfc23 Mon Sep 17 00:00:00 2001
|
||||
From: Martijn Braam <martijn@brixit.nl>
|
||||
Date: Sun, 13 Dec 2020 19:21:12 +0100
|
||||
Subject: [PATCH 2/8] Add ppp dt
|
||||
Date: Sat, 12 Dec 2020 13:31:03 +0100
|
||||
Subject: [PATCH] rockchip: Add initial support for the PinePhone Pro
|
||||
|
||||
This is a new device by PINE64 that's very similar to the Pinebook Pro
|
||||
that's already supported.
|
||||
|
||||
Specification:
|
||||
- Rockchip RK3399
|
||||
- 4GB Dual-Channel LPDDR4
|
||||
- 128GB eMMC
|
||||
- mSD card slot
|
||||
- AP6255 for 802.11ac WiFi and Bluetooth
|
||||
- 6 inch 720*1440 DSI display
|
||||
- Quectel EG25g usb modem
|
||||
- Type-C port with alt-mode display (DP 1.2) and PD charging.
|
||||
|
||||
Signed-off-by: Martijn Braam <martijn@brixit.nl>
|
||||
---
|
||||
arch/arm/dts/rk3399-pinephone-pro-u-boot.dtsi | 43 ++
|
||||
arch/arm/dts/rk3399-pinephone-pro.dts | 520 +++++++++++++++++++
|
||||
2 files changed, 563 insertions(+)
|
||||
arch/arm/dts/Makefile | 1 +
|
||||
arch/arm/dts/rk3399-pinephone-pro-u-boot.dtsi | 44 ++
|
||||
arch/arm/dts/rk3399-pinephone-pro.dts | 520 ++++++++++++++++++
|
||||
arch/arm/mach-rockchip/rk3399/Kconfig | 8 +
|
||||
board/pine64/pinephone-pro-rk3399/Kconfig | 15 +
|
||||
board/pine64/pinephone-pro-rk3399/MAINTAINERS | 8 +
|
||||
board/pine64/pinephone-pro-rk3399/Makefile | 1 +
|
||||
.../pinephone-pro-rk3399.c | 57 ++
|
||||
configs/pinephone-pro-rk3399_defconfig | 92 ++++
|
||||
include/configs/pinephone-pro-rk3399.h | 23 +
|
||||
10 files changed, 769 insertions(+)
|
||||
create mode 100644 arch/arm/dts/rk3399-pinephone-pro-u-boot.dtsi
|
||||
create mode 100644 arch/arm/dts/rk3399-pinephone-pro.dts
|
||||
create mode 100644 board/pine64/pinephone-pro-rk3399/Kconfig
|
||||
create mode 100644 board/pine64/pinephone-pro-rk3399/MAINTAINERS
|
||||
create mode 100644 board/pine64/pinephone-pro-rk3399/Makefile
|
||||
create mode 100644 board/pine64/pinephone-pro-rk3399/pinephone-pro-rk3399.c
|
||||
create mode 100644 configs/pinephone-pro-rk3399_defconfig
|
||||
create mode 100644 include/configs/pinephone-pro-rk3399.h
|
||||
|
||||
diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
|
||||
index aeaec713..6f123425 100644
|
||||
--- a/arch/arm/dts/Makefile
|
||||
+++ b/arch/arm/dts/Makefile
|
||||
@@ -145,6 +145,7 @@ dtb-$(CONFIG_ROCKCHIP_RK3399) += \
|
||||
rk3399-nanopi-r4s.dtb \
|
||||
rk3399-orangepi.dtb \
|
||||
rk3399-pinebook-pro.dtb \
|
||||
+ rk3399-pinephone-pro.dtb \
|
||||
rk3399-puma-haikou.dtb \
|
||||
rk3399-roc-pc.dtb \
|
||||
rk3399-roc-pc-mezzanine.dtb \
|
||||
diff --git a/arch/arm/dts/rk3399-pinephone-pro-u-boot.dtsi b/arch/arm/dts/rk3399-pinephone-pro-u-boot.dtsi
|
||||
new file mode 100644
|
||||
index 0000000000..7a058477db
|
||||
index 00000000..9d44db59
|
||||
--- /dev/null
|
||||
+++ b/arch/arm/dts/rk3399-pinephone-pro-u-boot.dtsi
|
||||
@@ -0,0 +1,43 @@
|
||||
@@ -0,0 +1,44 @@
|
||||
+// SPDX-License-Identifier: GPL-2.0+
|
||||
+/*
|
||||
+ * Copyright (C) 2019 Peter Robinson <pbrobinson at gmail.com>
|
||||
+ * Copyright (C) 2021 Martijn Braam <martijn at brixit.nl>
|
||||
+ */
|
||||
+
|
||||
+#include "rk3399-u-boot.dtsi"
|
||||
@ -30,7 +71,7 @@ index 0000000000..7a058477db
|
||||
+ };
|
||||
+
|
||||
+ chosen {
|
||||
+ u-boot,spl-boot-order = "same-as-spl", &sdhci, &spiflash, &sdmmc;
|
||||
+ u-boot,spl-boot-order = "same-as-spl", &sdhci, &sdmmc;
|
||||
+ };
|
||||
+
|
||||
+ config {
|
||||
@ -61,13 +102,13 @@ index 0000000000..7a058477db
|
||||
+};
|
||||
diff --git a/arch/arm/dts/rk3399-pinephone-pro.dts b/arch/arm/dts/rk3399-pinephone-pro.dts
|
||||
new file mode 100644
|
||||
index 0000000000..78d4760c8e
|
||||
index 00000000..3fe1845c
|
||||
--- /dev/null
|
||||
+++ b/arch/arm/dts/rk3399-pinephone-pro.dts
|
||||
@@ -0,0 +1,520 @@
|
||||
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||||
+/*
|
||||
+ * Copyright (c) 2020 Martijn Braam <martijn@brixit.nl>
|
||||
+ * Copyright (c) 2021 Martijn Braam <martijn@brixit.nl>
|
||||
+ */
|
||||
+
|
||||
+/dts-v1/;
|
||||
@ -75,8 +116,8 @@ index 0000000000..78d4760c8e
|
||||
+#include "rk3399-opp.dtsi"
|
||||
+
|
||||
+/ {
|
||||
+ model = "Pine64 PinePhonePro";
|
||||
+ compatible = "pine64,pinephonepro", "rockchip,rk3399";
|
||||
+ model = "Pine64 PinePhone Pro";
|
||||
+ compatible = "pine64,pinephone-pro", "rockchip,rk3399";
|
||||
+
|
||||
+ chosen {
|
||||
+ stdout-path = "serial2:1500000n8";
|
||||
@ -585,5 +626,264 @@ index 0000000000..78d4760c8e
|
||||
+&vopl_mmu {
|
||||
+ status = "okay";
|
||||
+};
|
||||
diff --git a/arch/arm/mach-rockchip/rk3399/Kconfig b/arch/arm/mach-rockchip/rk3399/Kconfig
|
||||
index 17628f91..3ba603ca 100644
|
||||
--- a/arch/arm/mach-rockchip/rk3399/Kconfig
|
||||
+++ b/arch/arm/mach-rockchip/rk3399/Kconfig
|
||||
@@ -28,6 +28,13 @@ config TARGET_PINEBOOK_PRO_RK3399
|
||||
with 4Gb RAM, onboard eMMC, USB-C, a USB3 and USB2 port,
|
||||
1920*1080 screen and all the usual laptop features.
|
||||
|
||||
+config TARGET_PINEPHONE_PRO_RK3399
|
||||
+ bool "PinePhone Pro"
|
||||
+ help
|
||||
+ PinePhone Pro is a phone based on the Rockchip rk3399 SoC
|
||||
+ with 4Gb RAM, onboard eMMC, USB-C, a headphone jack,
|
||||
+ 720x1440 screen and an external Quectel USB modem.
|
||||
+
|
||||
config TARGET_PUMA_RK3399
|
||||
bool "Theobroma Systems RK3399-Q7 (Puma)"
|
||||
help
|
||||
@@ -154,6 +161,7 @@ endif # BOOTCOUNT_LIMIT
|
||||
source "board/firefly/roc-pc-rk3399/Kconfig"
|
||||
source "board/google/gru/Kconfig"
|
||||
source "board/pine64/pinebook-pro-rk3399/Kconfig"
|
||||
+source "board/pine64/pinephone-pro-rk3399/Kconfig"
|
||||
source "board/pine64/rockpro64_rk3399/Kconfig"
|
||||
source "board/rockchip/evb_rk3399/Kconfig"
|
||||
source "board/theobroma-systems/puma_rk3399/Kconfig"
|
||||
diff --git a/board/pine64/pinephone-pro-rk3399/Kconfig b/board/pine64/pinephone-pro-rk3399/Kconfig
|
||||
new file mode 100644
|
||||
index 00000000..13d6465a
|
||||
--- /dev/null
|
||||
+++ b/board/pine64/pinephone-pro-rk3399/Kconfig
|
||||
@@ -0,0 +1,15 @@
|
||||
+if TARGET_PINEPHONE_PRO_RK3399
|
||||
+
|
||||
+config SYS_BOARD
|
||||
+ default "pinephone-pro-rk3399"
|
||||
+
|
||||
+config SYS_VENDOR
|
||||
+ default "pine64"
|
||||
+
|
||||
+config SYS_CONFIG_NAME
|
||||
+ default "pinephone-pro-rk3399"
|
||||
+
|
||||
+config BOARD_SPECIFIC_OPTIONS
|
||||
+ def_bool y
|
||||
+
|
||||
+endif
|
||||
diff --git a/board/pine64/pinephone-pro-rk3399/MAINTAINERS b/board/pine64/pinephone-pro-rk3399/MAINTAINERS
|
||||
new file mode 100644
|
||||
index 00000000..9ca4fc4c
|
||||
--- /dev/null
|
||||
+++ b/board/pine64/pinephone-pro-rk3399/MAINTAINERS
|
||||
@@ -0,0 +1,8 @@
|
||||
+PINEPHONE_PRO
|
||||
+M: Martijn Braam <martijn@brixit.nl>
|
||||
+S: Maintained
|
||||
+F: board/pine64/rk3399-pinephone-pro/
|
||||
+F: include/configs/rk3399-pinephone-pro.h
|
||||
+F: arch/arm/dts/rk3399-pinephone-pro.dts
|
||||
+F: arch/arm/dts/rk3399-pinephone-pro-u-boot.dtsi
|
||||
+F: configs/pinephone-pro-rk3399_defconfig
|
||||
diff --git a/board/pine64/pinephone-pro-rk3399/Makefile b/board/pine64/pinephone-pro-rk3399/Makefile
|
||||
new file mode 100644
|
||||
index 00000000..8d920305
|
||||
--- /dev/null
|
||||
+++ b/board/pine64/pinephone-pro-rk3399/Makefile
|
||||
@@ -0,0 +1 @@
|
||||
+obj-y += pinephone-pro-rk3399.o
|
||||
diff --git a/board/pine64/pinephone-pro-rk3399/pinephone-pro-rk3399.c b/board/pine64/pinephone-pro-rk3399/pinephone-pro-rk3399.c
|
||||
new file mode 100644
|
||||
index 00000000..8efeb6ea
|
||||
--- /dev/null
|
||||
+++ b/board/pine64/pinephone-pro-rk3399/pinephone-pro-rk3399.c
|
||||
@@ -0,0 +1,57 @@
|
||||
+// SPDX-License-Identifier: GPL-2.0+
|
||||
+/*
|
||||
+ * (C) Copyright 2019 Vasily Khoruzhick <anarsoul@gmail.com>
|
||||
+ * (C) Copyright 2021 Martijn Braam <martijn@brixit.nl>
|
||||
+ */
|
||||
+
|
||||
+#include <common.h>
|
||||
+#include <dm.h>
|
||||
+#include <init.h>
|
||||
+#include <syscon.h>
|
||||
+#include <asm/io.h>
|
||||
+#include <asm/arch-rockchip/clock.h>
|
||||
+#include <asm/arch-rockchip/grf_rk3399.h>
|
||||
+#include <asm/arch-rockchip/hardware.h>
|
||||
+#include <asm/arch-rockchip/misc.h>
|
||||
+
|
||||
+#define GRF_IO_VSEL_BT565_SHIFT 0
|
||||
+#define PMUGRF_CON0_VSEL_SHIFT 8
|
||||
+
|
||||
+#ifdef CONFIG_MISC_INIT_R
|
||||
+static void setup_iodomain(void)
|
||||
+{
|
||||
+ struct rk3399_grf_regs *grf =
|
||||
+ syscon_get_first_range(ROCKCHIP_SYSCON_GRF);
|
||||
+ struct rk3399_pmugrf_regs *pmugrf =
|
||||
+ syscon_get_first_range(ROCKCHIP_SYSCON_PMUGRF);
|
||||
+
|
||||
+ /* BT565 is in 1.8v domain */
|
||||
+ rk_setreg(&grf->io_vsel, 1 << GRF_IO_VSEL_BT565_SHIFT);
|
||||
+
|
||||
+ /* Set GPIO1 1.8v/3.0v source select to PMU1830_VOL */
|
||||
+ rk_setreg(&pmugrf->soc_con0, 1 << PMUGRF_CON0_VSEL_SHIFT);
|
||||
+}
|
||||
+
|
||||
+int misc_init_r(void)
|
||||
+{
|
||||
+ const u32 cpuid_offset = 0x7;
|
||||
+ const u32 cpuid_length = 0x10;
|
||||
+ u8 cpuid[cpuid_length];
|
||||
+ int ret;
|
||||
+
|
||||
+ setup_iodomain();
|
||||
+
|
||||
+ ret = rockchip_cpuid_from_efuse(cpuid_offset, cpuid_length, cpuid);
|
||||
+ if (ret)
|
||||
+ return ret;
|
||||
+
|
||||
+ ret = rockchip_cpuid_set(cpuid, cpuid_length);
|
||||
+ if (ret)
|
||||
+ return ret;
|
||||
+
|
||||
+ ret = rockchip_setup_macaddr();
|
||||
+
|
||||
+ return ret;
|
||||
+}
|
||||
+
|
||||
+#endif
|
||||
diff --git a/configs/pinephone-pro-rk3399_defconfig b/configs/pinephone-pro-rk3399_defconfig
|
||||
new file mode 100644
|
||||
index 00000000..2cf80f7d
|
||||
--- /dev/null
|
||||
+++ b/configs/pinephone-pro-rk3399_defconfig
|
||||
@@ -0,0 +1,92 @@
|
||||
+CONFIG_ARM=y
|
||||
+CONFIG_SKIP_LOWLEVEL_INIT=y
|
||||
+CONFIG_ARCH_ROCKCHIP=y
|
||||
+CONFIG_SYS_TEXT_BASE=0x00200000
|
||||
+CONFIG_NR_DRAM_BANKS=1
|
||||
+CONFIG_ENV_SIZE=0x8000
|
||||
+CONFIG_ROCKCHIP_RK3399=y
|
||||
+CONFIG_TARGET_PINEPHONE_PRO_RK3399=y
|
||||
+CONFIG_DEBUG_UART_BASE=0xFF1A0000
|
||||
+CONFIG_DEBUG_UART_CLOCK=24000000
|
||||
+CONFIG_SPL_SPI_FLASH_SUPPORT=y
|
||||
+CONFIG_SPL_SPI_SUPPORT=y
|
||||
+CONFIG_DEFAULT_DEVICE_TREE="rk3399-pinephone-pro"
|
||||
+CONFIG_DEBUG_UART=y
|
||||
+CONFIG_SYS_LOAD_ADDR=0x800800
|
||||
+CONFIG_BOOTDELAY=3
|
||||
+CONFIG_USE_PREBOOT=y
|
||||
+CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-pinephone-pro.dtb"
|
||||
+CONFIG_DISPLAY_BOARDINFO_LATE=y
|
||||
+CONFIG_MISC_INIT_R=y
|
||||
+# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
|
||||
+CONFIG_SPL_STACK_R=y
|
||||
+CONFIG_SPL_STACK_R_MALLOC_SIMPLE_LEN=0x10000
|
||||
+CONFIG_SPL_MTD_SUPPORT=y
|
||||
+CONFIG_SPL_SPI_LOAD=y
|
||||
+CONFIG_TPL=y
|
||||
+CONFIG_CMD_BOOTZ=y
|
||||
+CONFIG_CMD_GPIO=y
|
||||
+CONFIG_CMD_GPT=y
|
||||
+CONFIG_CMD_I2C=y
|
||||
+CONFIG_CMD_MMC=y
|
||||
+CONFIG_CMD_PCI=y
|
||||
+CONFIG_CMD_USB=y
|
||||
+# CONFIG_CMD_SETEXPR is not set
|
||||
+CONFIG_CMD_TIME=y
|
||||
+CONFIG_CMD_PMIC=y
|
||||
+CONFIG_CMD_REGULATOR=y
|
||||
+CONFIG_SPL_OF_CONTROL=y
|
||||
+CONFIG_OF_SPL_REMOVE_PROPS="pinctrl-0 pinctrl-names clock-names interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents"
|
||||
+CONFIG_ENV_IS_IN_SPI_FLASH=y
|
||||
+CONFIG_SYS_RELOC_GD_ENV_ADDR=y
|
||||
+CONFIG_ROCKCHIP_GPIO=y
|
||||
+CONFIG_SYS_I2C_ROCKCHIP=y
|
||||
+CONFIG_DM_KEYBOARD=y
|
||||
+CONFIG_LED=y
|
||||
+CONFIG_LED_GPIO=y
|
||||
+CONFIG_MISC=y
|
||||
+CONFIG_ROCKCHIP_EFUSE=y
|
||||
+CONFIG_MMC_DW=y
|
||||
+CONFIG_MMC_DW_ROCKCHIP=y
|
||||
+CONFIG_MMC_SDHCI=y
|
||||
+CONFIG_MMC_SDHCI_SDMA=y
|
||||
+CONFIG_MMC_SDHCI_ROCKCHIP=y
|
||||
+CONFIG_SF_DEFAULT_SPEED=20000000
|
||||
+CONFIG_SPI_FLASH_GIGADEVICE=y
|
||||
+CONFIG_SPI_FLASH_WINBOND=y
|
||||
+CONFIG_DM_ETH=y
|
||||
+CONFIG_PHY_ROCKCHIP_INNO_USB2=y
|
||||
+CONFIG_PHY_ROCKCHIP_TYPEC=y
|
||||
+CONFIG_DM_PMIC_FAN53555=y
|
||||
+CONFIG_PMIC_RK8XX=y
|
||||
+CONFIG_REGULATOR_PWM=y
|
||||
+CONFIG_REGULATOR_RK8XX=y
|
||||
+CONFIG_PWM_ROCKCHIP=y
|
||||
+CONFIG_RAM_RK3399_LPDDR4=y
|
||||
+CONFIG_DM_RESET=y
|
||||
+CONFIG_DM_RNG=y
|
||||
+CONFIG_RNG_ROCKCHIP=y
|
||||
+CONFIG_BAUDRATE=1500000
|
||||
+CONFIG_DEBUG_UART_SHIFT=2
|
||||
+CONFIG_ROCKCHIP_SPI=y
|
||||
+CONFIG_SYSRESET=y
|
||||
+CONFIG_USB=y
|
||||
+CONFIG_USB_XHCI_HCD=y
|
||||
+CONFIG_USB_XHCI_DWC3=y
|
||||
+CONFIG_USB_EHCI_HCD=y
|
||||
+CONFIG_USB_EHCI_GENERIC=y
|
||||
+CONFIG_USB_OHCI_HCD=y
|
||||
+CONFIG_USB_OHCI_GENERIC=y
|
||||
+CONFIG_USB_DWC3=y
|
||||
+CONFIG_USB_DWC3_GENERIC=y
|
||||
+CONFIG_USB_KEYBOARD=y
|
||||
+CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE=y
|
||||
+CONFIG_USB_HOST_ETHER=y
|
||||
+CONFIG_USB_ETHER_ASIX=y
|
||||
+CONFIG_USB_ETHER_RTL8152=y
|
||||
+CONFIG_DM_VIDEO=y
|
||||
+CONFIG_DISPLAY=y
|
||||
+CONFIG_VIDEO_ROCKCHIP=y
|
||||
+CONFIG_DISPLAY_ROCKCHIP_EDP=y
|
||||
+CONFIG_SPL_TINY_MEMSET=y
|
||||
+CONFIG_ERRNO_STR=y
|
||||
diff --git a/include/configs/pinephone-pro-rk3399.h b/include/configs/pinephone-pro-rk3399.h
|
||||
new file mode 100644
|
||||
index 00000000..fefa793f
|
||||
--- /dev/null
|
||||
+++ b/include/configs/pinephone-pro-rk3399.h
|
||||
@@ -0,0 +1,23 @@
|
||||
+/* SPDX-License-Identifier: GPL-2.0+ */
|
||||
+/*
|
||||
+ * Copyright (C) 2016 Rockchip Electronics Co., Ltd
|
||||
+ * Copyright (C) 2020 Peter Robinson <pbrobinson at gmail.com>
|
||||
+ * Copyright (C) 2021 Martijn Braam <martijn@brixit.nl>
|
||||
+ */
|
||||
+
|
||||
+#ifndef __PINEPHONE_PRO_RK3399_H
|
||||
+#define __PINEPHONE_PRO_RK3399_H
|
||||
+
|
||||
+#define ROCKCHIP_DEVICE_SETTINGS \
|
||||
+ "stdin=serial,usbkbd\0" \
|
||||
+ "stdout=serial,vidconsole\0" \
|
||||
+ "stderr=serial,vidconsole\0"
|
||||
+
|
||||
+#include <configs/rk3399_common.h>
|
||||
+
|
||||
+#define SDRAM_BANK_SIZE (2UL << 30)
|
||||
+
|
||||
+#define CONFIG_USB_OHCI_NEW
|
||||
+#define CONFIG_SYS_USB_OHCI_MAX_ROOT_PORTS 2
|
||||
+
|
||||
+#endif
|
||||
--
|
||||
2.33.0
|
||||
2.34.1
|
||||
|
@ -0,0 +1,28 @@
|
||||
From 679d7562f4711b1ad8c5ea54aa804fde5da5a19d Mon Sep 17 00:00:00 2001
|
||||
From: Samuel Dionne-Riel <samuel@dionne-riel.com>
|
||||
Date: Sat, 5 Feb 2022 21:00:53 -0500
|
||||
Subject: [PATCH] mtd: spi-nor-ids: Add GigaDevice GD25LQ128E entry
|
||||
|
||||
---
|
||||
drivers/mtd/spi/spi-nor-ids.c | 5 +++++
|
||||
1 file changed, 5 insertions(+)
|
||||
|
||||
diff --git a/drivers/mtd/spi/spi-nor-ids.c b/drivers/mtd/spi/spi-nor-ids.c
|
||||
index 4aef1ddd6e2..ff5bc2b2d78 100644
|
||||
--- a/drivers/mtd/spi/spi-nor-ids.c
|
||||
+++ b/drivers/mtd/spi/spi-nor-ids.c
|
||||
@@ -112,6 +112,11 @@ const struct flash_info spi_nor_ids[] = {
|
||||
SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ |
|
||||
SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB)
|
||||
},
|
||||
+ {
|
||||
+ INFO("gd25lq128e", 0x257018, 0, 64 * 1024, 256,
|
||||
+ SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ |
|
||||
+ SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB)
|
||||
+ },
|
||||
{
|
||||
INFO("gd25q128", 0xc84018, 0, 64 * 1024, 256,
|
||||
SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ |
|
||||
--
|
||||
2.34.0
|
||||
|
@ -0,0 +1,67 @@
|
||||
From 7d114ec31e537fcb4c2e4f0fca867b050fd59549 Mon Sep 17 00:00:00 2001
|
||||
From: Dragan Simic <dragan.simic@gmail.com>
|
||||
Date: Thu, 10 Feb 2022 14:43:05 +0100
|
||||
Subject: [PATCH] Reconfigure GPIO4_D3 as input on PinePhone Pro
|
||||
|
||||
---
|
||||
.../pinephone-pro-rk3399.c | 39 ++++++++++++++++++-
|
||||
1 file changed, 38 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/board/pine64/pinephone-pro-rk3399/pinephone-pro-rk3399.c b/board/pine64/pinephone-pro-rk3399/pinephone-pro-rk3399.c
|
||||
index d79084614f..bc19b275b2 100644
|
||||
--- a/board/pine64/pinephone-pro-rk3399/pinephone-pro-rk3399.c
|
||||
+++ b/board/pine64/pinephone-pro-rk3399/pinephone-pro-rk3399.c
|
||||
@@ -12,6 +12,7 @@
|
||||
#include <asm/arch-rockchip/grf_rk3399.h>
|
||||
#include <asm/arch-rockchip/hardware.h>
|
||||
#include <asm/arch-rockchip/misc.h>
|
||||
+#include <asm-generic/gpio.h>
|
||||
|
||||
#define GRF_IO_VSEL_BT565_SHIFT 0
|
||||
#define PMUGRF_CON0_VSEL_SHIFT 8
|
||||
@@ -52,5 +53,41 @@ int misc_init_r(void)
|
||||
|
||||
return ret;
|
||||
}
|
||||
-
|
||||
#endif
|
||||
+
|
||||
+#define GPIO4_D3 "155"
|
||||
+
|
||||
+static int setup_gpios(void)
|
||||
+{
|
||||
+ struct gpio_desc gpio;
|
||||
+ int ret;
|
||||
+
|
||||
+ /*
|
||||
+ * MaskROM enables output on GPIO4_D3 and leaves it that way, seemingly
|
||||
+ * because the RK3399 reference BOX and VR REF designs use GPIO4_D3 as
|
||||
+ * EFUSE_VQPS (AD23) power control output, while it is a light sensor
|
||||
+ * interrupt on the PinePhone Pro and needs to be configured as input.
|
||||
+ */
|
||||
+ ret = dm_gpio_lookup_name(GPIO4_D3, &gpio);
|
||||
+ if (ret)
|
||||
+ return ret;
|
||||
+
|
||||
+ ret = dm_gpio_request(&gpio, "light_int_l");
|
||||
+ if (ret)
|
||||
+ return ret;
|
||||
+
|
||||
+ dm_gpio_set_dir_flags(&gpio, GPIOD_IS_IN);
|
||||
+
|
||||
+ return 0;
|
||||
+}
|
||||
+
|
||||
+int rk_board_late_init(void)
|
||||
+{
|
||||
+ int ret;
|
||||
+
|
||||
+ ret = setup_gpios();
|
||||
+ if (ret)
|
||||
+ debug("Failed to configure GPIO lines: %d\n", ret);
|
||||
+
|
||||
+ return ret;
|
||||
+}
|
||||
--
|
||||
2.33.1
|
||||
|
@ -0,0 +1,67 @@
|
||||
From: Peter Geis <pgwipeout@gmail.com>
|
||||
To: Peng Fan <peng.fan@nxp.com>, Jaehoon Chung <jh80.chung@samsung.com>
|
||||
Cc: Peter Geis <pgwipeout@gmail.com>, u-boot@lists.denx.de
|
||||
Subject: [PATCH v1 02/11] mmc: sdhci: allow disabling sdma in spl
|
||||
Date: Mon, 21 Feb 2022 20:31:21 -0500
|
||||
|
||||
Rockchip emmc devices have a similar issue to Rockchip dwmmc devices,
|
||||
where performing dma to sram causes errors with suspend/resume.
|
||||
Allow us to toggle sdma in spl for sdhci similar to adma support, so we
|
||||
can ensure dma is not used when loading the sram code.
|
||||
|
||||
Signed-off-by: Peter Geis <pgwipeout@gmail.com>
|
||||
Reviewed-by: Jaehoon Chung <jh80.chung@samsung.com>
|
||||
---
|
||||
drivers/mmc/Kconfig | 7 +++++++
|
||||
drivers/mmc/sdhci.c | 6 +++---
|
||||
2 files changed, 10 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/drivers/mmc/Kconfig b/drivers/mmc/Kconfig
|
||||
index f04cc44e1973..1e4342285ce7 100644
|
||||
--- a/drivers/mmc/Kconfig
|
||||
+++ b/drivers/mmc/Kconfig
|
||||
@@ -468,6 +468,13 @@ config MMC_SDHCI_SDMA
|
||||
This enables support for the SDMA (Single Operation DMA) defined
|
||||
in the SD Host Controller Standard Specification Version 1.00 .
|
||||
|
||||
+config SPL_MMC_SDHCI_SDMA
|
||||
+ bool "Support SDHCI SDMA in SPL"
|
||||
+ depends on MMC_SDHCI
|
||||
+ help
|
||||
+ This enables support for the SDMA (Single Operation DMA) defined
|
||||
+ in the SD Host Controller Standard Specification Version 1.00 in SPL.
|
||||
+
|
||||
config MMC_SDHCI_ADMA
|
||||
bool "Support SDHCI ADMA2"
|
||||
depends on MMC_SDHCI
|
||||
diff --git a/drivers/mmc/sdhci.c b/drivers/mmc/sdhci.c
|
||||
index 766e4a6b0c5e..6285e53d12a2 100644
|
||||
--- a/drivers/mmc/sdhci.c
|
||||
+++ b/drivers/mmc/sdhci.c
|
||||
@@ -70,7 +70,7 @@ static void sdhci_transfer_pio(struct sdhci_host *host, struct mmc_data *data)
|
||||
}
|
||||
}
|
||||
|
||||
-#if (defined(CONFIG_MMC_SDHCI_SDMA) || CONFIG_IS_ENABLED(MMC_SDHCI_ADMA))
|
||||
+#if (CONFIG_IS_ENABLED(MMC_SDHCI_SDMA) || CONFIG_IS_ENABLED(MMC_SDHCI_ADMA))
|
||||
static void sdhci_prepare_dma(struct sdhci_host *host, struct mmc_data *data,
|
||||
int *is_aligned, int trans_bytes)
|
||||
{
|
||||
@@ -177,7 +177,7 @@ static int sdhci_transfer_data(struct sdhci_host *host, struct mmc_data *data)
|
||||
}
|
||||
} while (!(stat & SDHCI_INT_DATA_END));
|
||||
|
||||
-#if (defined(CONFIG_MMC_SDHCI_SDMA) || CONFIG_IS_ENABLED(MMC_SDHCI_ADMA))
|
||||
+#if (CONFIG_IS_ENABLED(MMC_SDHCI_SDMA) || CONFIG_IS_ENABLED(MMC_SDHCI_ADMA))
|
||||
dma_unmap_single(host->start_addr, data->blocks * data->blocksize,
|
||||
mmc_get_dma_dir(data));
|
||||
#endif
|
||||
@@ -836,7 +836,7 @@ int sdhci_setup_cfg(struct mmc_config *cfg, struct sdhci_host *host,
|
||||
#endif
|
||||
debug("%s, caps: 0x%x\n", __func__, caps);
|
||||
|
||||
-#ifdef CONFIG_MMC_SDHCI_SDMA
|
||||
+#if CONFIG_IS_ENABLED(MMC_SDHCI_SDMA)
|
||||
if ((caps & SDHCI_CAN_DO_SDMA)) {
|
||||
host->flags |= USE_SDMA;
|
||||
} else {
|
@ -0,0 +1,32 @@
|
||||
From 0885f6b57b218f0de18cd67856fcfdd68843fc9a Mon Sep 17 00:00:00 2001
|
||||
From: Samuel Dionne-Riel <samuel@dionne-riel.com>
|
||||
Date: Sun, 30 Jan 2022 21:44:07 -0500
|
||||
Subject: [PATCH 7/7] [WIP] pinephone-pro: Remove cargo-culted iodomain config
|
||||
|
||||
It is unclear what it actually does, and the TRM states this register
|
||||
should already be at `0x1` on reset.
|
||||
|
||||
Thus it is assumed this would be redundant. Except that it is not, and
|
||||
keeping this change in will break SPI NOR Flash support. The SPI bus(?)
|
||||
will be tied up, I assume, and thus return `ff ff ff` as an identifier
|
||||
---
|
||||
board/pine64/pinephone-pro-rk3399/pinephone-pro-rk3399.c | 3 ---
|
||||
1 file changed, 3 deletions(-)
|
||||
|
||||
diff --git a/board/pine64/pinephone-pro-rk3399/pinephone-pro-rk3399.c b/board/pine64/pinephone-pro-rk3399/pinephone-pro-rk3399.c
|
||||
index c51d1657a2a..22c2ced2d79 100644
|
||||
--- a/board/pine64/pinephone-pro-rk3399/pinephone-pro-rk3399.c
|
||||
+++ b/board/pine64/pinephone-pro-rk3399/pinephone-pro-rk3399.c
|
||||
@@ -33,9 +33,6 @@ static void setup_iodomain(void)
|
||||
|
||||
/* BT565 is in 1.8v domain */
|
||||
rk_setreg(&grf->io_vsel, 1 << GRF_IO_VSEL_BT565_SHIFT);
|
||||
-
|
||||
- /* Set GPIO1 1.8v/3.0v source select to PMU1830_VOL */
|
||||
- rk_setreg(&pmugrf->soc_con0, 1 << PMUGRF_CON0_VSEL_SHIFT);
|
||||
}
|
||||
|
||||
int misc_init_r(void)
|
||||
--
|
||||
2.34.0
|
||||
|
@ -0,0 +1,40 @@
|
||||
From 8945d49c2d60a3b26d215b2d6c45918ac9d143bd Mon Sep 17 00:00:00 2001
|
||||
From: Samuel Dionne-Riel <samuel@dionne-riel.com>
|
||||
Date: Sun, 30 Jan 2022 16:59:26 -0500
|
||||
Subject: [PATCH 6/7] pine64-pinephonePro: SPI support
|
||||
|
||||
NOTE: Original patch modified a bit for the used version of the PPP DT.
|
||||
---
|
||||
diff --git a/arch/arm/dts/rk3399-pinephone-pro-u-boot.dtsi b/arch/arm/dts/rk3399-pinephone-pro-u-boot.dtsi
|
||||
index 9d44db59783..28bec0a6a70 100644
|
||||
--- a/arch/arm/dts/rk3399-pinephone-pro-u-boot.dtsi
|
||||
+++ b/arch/arm/dts/rk3399-pinephone-pro-u-boot.dtsi
|
||||
@@ -42,3 +42,7 @@
|
||||
max-frequency = <20000000>;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
+
|
||||
+&spiflash {
|
||||
+ u-boot,dm-pre-reloc;
|
||||
+};
|
||||
diff --git a/arch/arm/dts/rk3399-pinephone-pro.dts b/arch/arm/dts/rk3399-pinephone-pro.dts
|
||||
index e6c2df936fb..9a658f37c69 100644
|
||||
--- a/arch/arm/dts/rk3399-pinephone-pro.dts
|
||||
+++ b/arch/arm/dts/rk3399-pinephone-pro.dts
|
||||
@@ -503,6 +503,16 @@
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
+&spi1 {
|
||||
+ status = "okay";
|
||||
+
|
||||
+ spiflash: flash@0 {
|
||||
+ compatible = "jedec,spi-nor";
|
||||
+ reg = <0>;
|
||||
+ spi-max-frequency = <10000000>;
|
||||
+ };
|
||||
+};
|
||||
+
|
||||
&vopb {
|
||||
status = "okay";
|
||||
};
|
@ -7,7 +7,7 @@ inherit toolchain-funcs
|
||||
|
||||
PKGREL="4"
|
||||
FIRMWAREVERSION="2.6"
|
||||
COMMMIT="0719bf42931033c3109ecc6357e8adb567cb637b"
|
||||
COMMMIT="e4b6ebd3de982ae7185dbf689a030e73fd06e0d2"
|
||||
MY_P="u-boot-${COMMMIT}"
|
||||
DESCRIPTION="Das U-boot and utilities for working with Das U-Boot for the PinePhone Pro"
|
||||
HOMEPAGE="https://www.denx.de/wiki/U-Boot/WebHome"
|
||||
@ -42,15 +42,13 @@ src_prepare() {
|
||||
|
||||
#Apply PinePhone Pro patches
|
||||
eapply "${FILESDIR}"/0001-PPP.patch
|
||||
eapply "${FILESDIR}"/0002-Add-ppp-dt.patch
|
||||
eapply "${FILESDIR}"/0003-Config-changes.patch
|
||||
eapply "${FILESDIR}"/0004-Add-kconfig-include.patch
|
||||
eapply "${FILESDIR}"/0005-Add-pinephone-pro-rk3399.h.patch
|
||||
eapply "${FILESDIR}"/0006-Added-dts-to-makefile.patch
|
||||
eapply "${FILESDIR}"/0007-u-boot.dtsi-fixes.patch
|
||||
eapply "${FILESDIR}"/0008-fix-boot-order.patch
|
||||
eapply "${FILESDIR}"/0009-Correct-boot-order-to-be-USB-SD-eMMC.patch
|
||||
|
||||
eapply "${FILESDIR}"/1001-Correct-boot-order-to-be-USB-SD-eMMC.patch
|
||||
eapply "${FILESDIR}"/1002-rockchip-Add-initial-support-for-the-PinePhone-Pro.patch
|
||||
eapply "${FILESDIR}"/1004-mtd-spi-nor-ids-Add-GigaDevice-GD25LQ128E-entry.patch
|
||||
eapply "${FILESDIR}"/1005-Reconfigure-GPIO4_D3-as-input-on-PinePhone-Pro.patch
|
||||
eapply "${FILESDIR}"/2001-mmc-sdhci-allow-disabling-sdma-in-spl.patch
|
||||
eapply "${FILESDIR}"/3001-pinephone-pro-Remove-cargo-culted-iodomain-config.patch
|
||||
eapply "${FILESDIR}"/3002-pine64-pinephonePro-SPI-support.patch
|
||||
}
|
||||
|
||||
|
||||
@ -80,6 +78,10 @@ src_compile() {
|
||||
emake "${myemakeargs[@]}" pinephone-pro-rk3399_defconfig
|
||||
|
||||
echo 'CONFIG_IDENT_STRING=" Gentoo Linux"' >> .config
|
||||
echo 'CONFIG_BOOTDELAY=" 0"' >> .config
|
||||
echo 'CONFIG_SPL_DM_SEQ_ALIAS=" y"' >> .config
|
||||
echo 'CONFIG_SF_DEFAULT_BUS=" 1"' >> .config
|
||||
echo 'CONFIG_SPL_MMC_SDHCI_SDMA=" n"' >> .config
|
||||
|
||||
emake "${myemakeargs[@]}" EXTRAVERSION=-${PKGREL}
|
||||
|
Loading…
Reference in New Issue
Block a user