mirror of
https://github.com/coolsnowwolf/lede.git
synced 2025-04-16 04:13:31 +00:00
uboot-sunxi: add support for H618 x98h
This commit is contained in:
parent
5c5b7af071
commit
0d1280a187
@ -346,6 +346,15 @@ define U-Boot/orangepi_zero3
|
||||
ATF:=h616
|
||||
endef
|
||||
|
||||
define U-Boot/hechuang_x98h
|
||||
BUILD_SUBTARGET:=cortexa53
|
||||
NAME:=Hechuang X98H
|
||||
BUILD_DEVICES:=hechuang_x98h
|
||||
DEPENDS:=+PACKAGE_u-boot-hechuang_x98h:trusted-firmware-a-sunxi-h616
|
||||
UENV:=h616
|
||||
ATF:=h616
|
||||
endef
|
||||
|
||||
define U-Boot/Bananapi_M2_Ultra
|
||||
BUILD_SUBTARGET:=cortexa7
|
||||
NAME:=Bananapi M2 Ultra
|
||||
@ -383,6 +392,7 @@ UBOOT_TARGETS := \
|
||||
Cubieboard \
|
||||
Cubieboard2 \
|
||||
Cubietruck \
|
||||
hechuang_x98h \
|
||||
Hummingbird_A31 \
|
||||
Marsboard_A10 \
|
||||
Mele_M9 \
|
||||
|
@ -0,0 +1,218 @@
|
||||
diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
|
||||
index c16b6471..3262517a 100644
|
||||
--- a/arch/arm/dts/Makefile
|
||||
+++ b/arch/arm/dts/Makefile
|
||||
@@ -836,7 +836,8 @@ dtb-$(CONFIG_MACH_SUN50I_H6) += \
|
||||
dtb-$(CONFIG_MACH_SUN50I_H616) += \
|
||||
sun50i-h616-orangepi-zero2.dtb \
|
||||
sun50i-h618-orangepi-zero3.dtb \
|
||||
- sun50i-h616-x96-mate.dtb
|
||||
+ sun50i-h616-x96-mate.dtb \
|
||||
+ sun50i-h618-x98h.dtb
|
||||
dtb-$(CONFIG_MACH_SUN50I) += \
|
||||
sun50i-a64-amarula-relic.dtb \
|
||||
sun50i-a64-bananapi-m64.dtb \
|
||||
diff --git a/arch/arm/dts/sun50i-h618-x98h.dts b/arch/arm/dts/sun50i-h618-x98h.dts
|
||||
new file mode 100644
|
||||
index 00000000..d3bc2284
|
||||
--- /dev/null
|
||||
+++ b/arch/arm/dts/sun50i-h618-x98h.dts
|
||||
@@ -0,0 +1,161 @@
|
||||
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||||
+/*
|
||||
+ * Copyright (C) 2021 Arm Ltd.
|
||||
+ */
|
||||
+
|
||||
+/dts-v1/;
|
||||
+
|
||||
+#include "sun50i-h616.dtsi"
|
||||
+
|
||||
+#include <dt-bindings/gpio/gpio.h>
|
||||
+#include <dt-bindings/interrupt-controller/arm-gic.h>
|
||||
+
|
||||
+/ {
|
||||
+ model = "X98H";
|
||||
+ compatible = "hechuang,x98h", "allwinner,sun50i-h618";
|
||||
+
|
||||
+ aliases {
|
||||
+ ethernet0 = &emac1;
|
||||
+ serial0 = &uart0;
|
||||
+ };
|
||||
+
|
||||
+ chosen {
|
||||
+ stdout-path = "serial0:115200n8";
|
||||
+ };
|
||||
+
|
||||
+ reg_vcc5v: vcc5v {
|
||||
+ /* board wide 5V supply directly from the DC input */
|
||||
+ compatible = "regulator-fixed";
|
||||
+ regulator-name = "vcc-5v";
|
||||
+ regulator-min-microvolt = <5000000>;
|
||||
+ regulator-max-microvolt = <5000000>;
|
||||
+ regulator-always-on;
|
||||
+ };
|
||||
+};
|
||||
+
|
||||
+&emac1 {
|
||||
+ pinctrl-names = "default";
|
||||
+ pinctrl-0 = <&rmii_pins>;
|
||||
+ phy-mode = "rmii";
|
||||
+ phy-handle = <&rmii_phy>;
|
||||
+ phy-supply = <®_aldo1>;
|
||||
+ allwinner,rx-delay-ps = <3100>;
|
||||
+ allwinner,tx-delay-ps = <700>;
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&mdio1 {
|
||||
+ rmii_phy: ethernet-phy@16 {
|
||||
+ compatible = "ethernet-phy-ieee802.3-c22";
|
||||
+ reg = <16>;
|
||||
+ };
|
||||
+};
|
||||
+
|
||||
+&ehci0 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&ehci2 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&ir {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&mmc0 {
|
||||
+ vmmc-supply = <®_dldo1>;
|
||||
+ cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>; /* PF6 */
|
||||
+ bus-width = <4>;
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&mmc2 {
|
||||
+ vmmc-supply = <®_dldo1>;
|
||||
+ vqmmc-supply = <®_aldo1>;
|
||||
+ bus-width = <8>;
|
||||
+ non-removable;
|
||||
+ cap-mmc-hw-reset;
|
||||
+ mmc-ddr-1_8v;
|
||||
+ mmc-hs200-1_8v;
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&ohci0 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&ohci2 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&r_i2c {
|
||||
+ status = "okay";
|
||||
+
|
||||
+ axp313: pmic@36 {
|
||||
+ compatible = "x-powers,axp313a";
|
||||
+ reg = <0x36>;
|
||||
+ #interrupt-cells = <1>;
|
||||
+ interrupt-controller;
|
||||
+ interrupt-parent = <&pio>;
|
||||
+ interrupts = <2 9 IRQ_TYPE_LEVEL_LOW>; /* PC9 */
|
||||
+
|
||||
+ vin1-supply = <®_vcc5v>;
|
||||
+ vin2-supply = <®_vcc5v>;
|
||||
+ vin3-supply = <®_vcc5v>;
|
||||
+
|
||||
+ regulators {
|
||||
+ /* Supplies VCC-PLL, so needs to be always on. */
|
||||
+ reg_aldo1: aldo1 {
|
||||
+ regulator-always-on;
|
||||
+ regulator-min-microvolt = <1800000>;
|
||||
+ regulator-max-microvolt = <1800000>;
|
||||
+ regulator-name = "vcc1v8";
|
||||
+ };
|
||||
+
|
||||
+ /* Supplies VCC-IO, so needs to be always on. */
|
||||
+ reg_dldo1: dldo1 {
|
||||
+ regulator-always-on;
|
||||
+ regulator-min-microvolt = <3300000>;
|
||||
+ regulator-max-microvolt = <3300000>;
|
||||
+ regulator-name = "vcc3v3";
|
||||
+ };
|
||||
+
|
||||
+ reg_dcdc1: dcdc1 {
|
||||
+ regulator-always-on;
|
||||
+ regulator-min-microvolt = <810000>;
|
||||
+ regulator-max-microvolt = <990000>;
|
||||
+ regulator-name = "vdd-gpu-sys";
|
||||
+ };
|
||||
+
|
||||
+ reg_dcdc2: dcdc2 {
|
||||
+ regulator-always-on;
|
||||
+ regulator-min-microvolt = <810000>;
|
||||
+ regulator-max-microvolt = <1100000>;
|
||||
+ regulator-name = "vdd-cpu";
|
||||
+ };
|
||||
+
|
||||
+ reg_dcdc3: dcdc3 {
|
||||
+ regulator-always-on;
|
||||
+ regulator-min-microvolt = <1100000>;
|
||||
+ regulator-max-microvolt = <1100000>;
|
||||
+ regulator-name = "vdd-dram";
|
||||
+ };
|
||||
+ };
|
||||
+ };
|
||||
+};
|
||||
+
|
||||
+&uart0 {
|
||||
+ pinctrl-names = "default";
|
||||
+ pinctrl-0 = <&uart0_ph_pins>;
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&usbotg {
|
||||
+ dr_mode = "host"; /* USB A type receptable */
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&usbphy {
|
||||
+ status = "okay";
|
||||
+};
|
||||
diff --git a/configs/hechuang_x98h_defconfig b/configs/hechuang_x98h_defconfig
|
||||
new file mode 100644
|
||||
index 00000000..3d97900b
|
||||
--- /dev/null
|
||||
+++ b/configs/hechuang_x98h_defconfig
|
||||
@@ -0,0 +1,31 @@
|
||||
+CONFIG_ARM=y
|
||||
+CONFIG_ARCH_SUNXI=y
|
||||
+CONFIG_DEFAULT_DEVICE_TREE="sun50i-h618-x98h"
|
||||
+CONFIG_SPL=y
|
||||
+CONFIG_DRAM_SUN50I_H616_DX_ODT=0x03030303
|
||||
+CONFIG_DRAM_SUN50I_H616_DX_DRI=0x0e0e0e0e
|
||||
+CONFIG_DRAM_SUN50I_H616_CA_DRI=0x1f12
|
||||
+CONFIG_DRAM_SUN50I_H616_TPR0=0xc0001002
|
||||
+CONFIG_DRAM_SUN50I_H616_TPR10=0x2f1107
|
||||
+CONFIG_DRAM_SUN50I_H616_TPR11=0xddddcccc
|
||||
+CONFIG_DRAM_SUN50I_H616_TPR12=0xeddc7665
|
||||
+CONFIG_MACH_SUN50I_H616=y
|
||||
+CONFIG_SUNXI_DRAM_H616_DDR3_1333=y
|
||||
+CONFIG_DRAM_CLK=648
|
||||
+CONFIG_MMC_SUNXI_SLOT_EXTRA=2
|
||||
+CONFIG_R_I2C_ENABLE=y
|
||||
+# CONFIG_SYS_MALLOC_CLEAR_ON_INIT is not set
|
||||
+CONFIG_SPL_I2C=y
|
||||
+CONFIG_SPL_I2C_SUPPORT=y
|
||||
+CONFIG_SPL_SYS_I2C_LEGACY=y
|
||||
+CONFIG_SYS_I2C_MVTWSI=y
|
||||
+CONFIG_SYS_I2C_SLAVE=0x7f
|
||||
+CONFIG_SYS_I2C_SPEED=100000
|
||||
+CONFIG_PHY_REALTEK=y
|
||||
+CONFIG_SUN8I_EMAC=y
|
||||
+CONFIG_I2C3_ENABLE=y
|
||||
+CONFIG_SUPPORT_EMMC_BOOT=y
|
||||
+CONFIG_AXP313_POWER=y
|
||||
+CONFIG_AXP_DCDC3_VOLT=1360
|
||||
+CONFIG_USB_EHCI_HCD=y
|
||||
+CONFIG_USB_OHCI_HCD=y
|
Loading…
Reference in New Issue
Block a user