[v2,01/10] conf/machine: add support for rk3399

Submitted by ayaka on April 23, 2019, 1:25 p.m. | Patch ID: 160619

Details

Message ID 20190423132514.21996-2-ayaka@soulik.info
State New
Headers show

Commit Message

ayaka April 23, 2019, 1:25 p.m.
RK3399 is a new generation powerful SoC from Rockchip, which has
Dual Cortex-A72 + Quad Cortex-A53, 64-bit CPU.

Signed-off-by: Randy 'ayaka' Li <ayaka@soulik.info>
---
 conf/machine/excavator-rk3399.conf | 12 ++++++++++++
 conf/machine/firefly-rk3399.conf   | 14 ++++++++++++++
 conf/machine/include/rk3399.inc    | 17 +++++++++++++++++
 3 files changed, 43 insertions(+)
 create mode 100644 conf/machine/excavator-rk3399.conf
 create mode 100644 conf/machine/firefly-rk3399.conf
 create mode 100644 conf/machine/include/rk3399.inc

Patch hide | download patch | download mbox

diff --git a/conf/machine/excavator-rk3399.conf b/conf/machine/excavator-rk3399.conf
new file mode 100644
index 0000000..8506a50
--- /dev/null
+++ b/conf/machine/excavator-rk3399.conf
@@ -0,0 +1,12 @@ 
+# Copyright (C) 2017 Fuzhou Rockchip Electronics Co., Ltd
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+#@TYPE: Machine
+#@NAME: EXCAVATOR 3399
+
+include conf/machine/include/rk3399.inc
+
+KERNEL_DEVICETREE = "rockchip/rk3399-sapphire-excavator.dtb"
+UBOOT_MACHINE = "evb-rk3399_defconfig"
+
+GPTIMG_APPEND = "console=ttyS2,1500000n8 rw root=PARTUUID=B921B045-1DF0 rootfstype=ext4 init=/sbin/init"
diff --git a/conf/machine/firefly-rk3399.conf b/conf/machine/firefly-rk3399.conf
new file mode 100644
index 0000000..4e35c3d
--- /dev/null
+++ b/conf/machine/firefly-rk3399.conf
@@ -0,0 +1,14 @@ 
+# Copyright (C) 2017 Fuzhou Rockchip Electronics Co., Ltd
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+#@TYPE: Machine
+#@NAME: Firefly RK3399
+#@DESCRIPTION: Firefly-RK3399 is a Six-Core 64-bit High-Performance Platform.
+#http://www.t-firefly.com/en/
+
+include conf/machine/include/rk3399.inc
+
+KERNEL_DEVICETREE = "rockchip/rk3399-firefly.dtb"
+UBOOT_MACHINE = "evb-rk3399_defconfig"
+
+GPTIMG_APPEND = "console=ttyS2,1500000n8 rw root=PARTUUID=B921B045-1DF0 rootfstype=ext4 init=/sbin/init"
diff --git a/conf/machine/include/rk3399.inc b/conf/machine/include/rk3399.inc
new file mode 100644
index 0000000..9237616
--- /dev/null
+++ b/conf/machine/include/rk3399.inc
@@ -0,0 +1,17 @@ 
+# Copyright (C) 2019 SUMOMO Computer Association
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+SOC_FAMILY = "rk3399"
+
+require conf/machine/include/tune-cortexa72.inc
+require conf/machine/include/soc-family.inc
+require conf/machine/include/rockchip-defaults.inc
+
+SERIAL_CONSOLES = "1500000;ttyS2"
+KERNEL_IMAGETYPE = "Image"
+KBUILD_DEFCONFIG = "defconfig"
+
+PREFERRED_PROVIDER_virtual/bootloader ?= "u-boot-rockchip"
+
+IMAGE_FSTYPES = "rockchip-gpt-img"
+IMAGE_CLASSES = "rockchip-gpt-img"

Comments

Trevor Woerner April 23, 2019, 5:47 p.m.
On Tue 2019-04-23 @ 09:25:05 PM, Randy 'ayaka' Li wrote:
> RK3399 is a new generation powerful SoC from Rockchip, which has
> Dual Cortex-A72 + Quad Cortex-A53, 64-bit CPU.
> 
> Signed-off-by: Randy 'ayaka' Li <ayaka@soulik.info>
> ---
>  conf/machine/excavator-rk3399.conf | 12 ++++++++++++
>  conf/machine/firefly-rk3399.conf   | 14 ++++++++++++++
>  conf/machine/include/rk3399.inc    | 17 +++++++++++++++++
>  3 files changed, 43 insertions(+)
>  create mode 100644 conf/machine/excavator-rk3399.conf
>  create mode 100644 conf/machine/firefly-rk3399.conf
>  create mode 100644 conf/machine/include/rk3399.inc
> 
> diff --git a/conf/machine/excavator-rk3399.conf b/conf/machine/excavator-rk3399.conf
> new file mode 100644
> index 0000000..8506a50
> --- /dev/null
> +++ b/conf/machine/excavator-rk3399.conf
> @@ -0,0 +1,12 @@
> +# Copyright (C) 2017 Fuzhou Rockchip Electronics Co., Ltd
> +# Released under the MIT license (see COPYING.MIT for the terms)
> +
> +#@TYPE: Machine
> +#@NAME: EXCAVATOR 3399
> +
> +include conf/machine/include/rk3399.inc
> +
> +KERNEL_DEVICETREE = "rockchip/rk3399-sapphire-excavator.dtb"
> +UBOOT_MACHINE = "evb-rk3399_defconfig"
> +
> +GPTIMG_APPEND = "console=ttyS2,1500000n8 rw root=PARTUUID=B921B045-1DF0 rootfstype=ext4 init=/sbin/init"
> diff --git a/conf/machine/firefly-rk3399.conf b/conf/machine/firefly-rk3399.conf
> new file mode 100644
> index 0000000..4e35c3d
> --- /dev/null
> +++ b/conf/machine/firefly-rk3399.conf
> @@ -0,0 +1,14 @@
> +# Copyright (C) 2017 Fuzhou Rockchip Electronics Co., Ltd
> +# Released under the MIT license (see COPYING.MIT for the terms)
> +
> +#@TYPE: Machine
> +#@NAME: Firefly RK3399
> +#@DESCRIPTION: Firefly-RK3399 is a Six-Core 64-bit High-Performance Platform.
> +#http://www.t-firefly.com/en/
> +
> +include conf/machine/include/rk3399.inc
> +
> +KERNEL_DEVICETREE = "rockchip/rk3399-firefly.dtb"
> +UBOOT_MACHINE = "evb-rk3399_defconfig"
> +
> +GPTIMG_APPEND = "console=ttyS2,1500000n8 rw root=PARTUUID=B921B045-1DF0 rootfstype=ext4 init=/sbin/init"
> diff --git a/conf/machine/include/rk3399.inc b/conf/machine/include/rk3399.inc
> new file mode 100644
> index 0000000..9237616
> --- /dev/null
> +++ b/conf/machine/include/rk3399.inc
> @@ -0,0 +1,17 @@
> +# Copyright (C) 2019 SUMOMO Computer Association
> +# Released under the MIT license (see COPYING.MIT for the terms)
> +
> +SOC_FAMILY = "rk3399"
> +
> +require conf/machine/include/tune-cortexa72.inc
> +require conf/machine/include/soc-family.inc
> +require conf/machine/include/rockchip-defaults.inc
> +
> +SERIAL_CONSOLES = "1500000;ttyS2"
> +KERNEL_IMAGETYPE = "Image"
> +KBUILD_DEFCONFIG = "defconfig"
> +
> +PREFERRED_PROVIDER_virtual/bootloader ?= "u-boot-rockchip"

Using u-boot-rockchip causes build failures. In both cases (excavator-rk3399
and firefly-rk3399) I get:

	| #
	| # configuration written to .config
	| #
	| make[1]: Leaving directory '/z/build-master/meta-rockchip/build/tmp-glibc/work/firefly_rk3399-oe-linux/u-boot-rockchip/20171218-r0/build'
	| make: Leaving directory '/z/build-master/meta-rockchip/build/tmp-glibc/work/firefly_rk3399-oe-linux/u-boot-rockchip/20171218-r0/git'
	| /z/build-master/meta-rockchip/build/tmp-glibc/work/firefly_rk3399-oe-linux/u-boot-rockchip/20171218-r0/temp/run.do_configure.27647: line 113: merge_config.sh: command not found
	| WARNING: /z/build-master/meta-rockchip/build/tmp-glibc/work/firefly_rk3399-oe-linux/u-boot-rockchip/20171218-r0/temp/run.do_configure.27647:1 exit 127 from 'merge_config.sh -m .config'
	| ERROR: Function failed: do_configure (log file is located at /z/build-master/meta-rockchip/build/tmp-glibc/work/firefly_rk3399-oe-linux/u-boot-rockchip/20171218-r0/temp/log.do_configure.27647)

Do you have an updated recipe for u-boot-rockchip?

> +
> +IMAGE_FSTYPES = "rockchip-gpt-img"
> +IMAGE_CLASSES = "rockchip-gpt-img"
> -- 
> 2.20.1
> 
> -- 
> _______________________________________________
> yocto mailing list
> yocto@yoctoproject.org
> https://lists.yoctoproject.org/listinfo/yocto
ayaka April 24, 2019, 3:01 p.m.
On 4/24/19 1:47 AM, Trevor Woerner wrote:
> On Tue 2019-04-23 @ 09:25:05 PM, Randy 'ayaka' Li wrote:
>> RK3399 is a new generation powerful SoC from Rockchip, which has
>> Dual Cortex-A72 + Quad Cortex-A53, 64-bit CPU.
>>
>> Signed-off-by: Randy 'ayaka' Li <ayaka@soulik.info>
>> ---
>>   conf/machine/excavator-rk3399.conf | 12 ++++++++++++
>>   conf/machine/firefly-rk3399.conf   | 14 ++++++++++++++
>>   conf/machine/include/rk3399.inc    | 17 +++++++++++++++++
>>   3 files changed, 43 insertions(+)
>>   create mode 100644 conf/machine/excavator-rk3399.conf
>>   create mode 100644 conf/machine/firefly-rk3399.conf
>>   create mode 100644 conf/machine/include/rk3399.inc
>>
>> diff --git a/conf/machine/excavator-rk3399.conf b/conf/machine/excavator-rk3399.conf
>> new file mode 100644
>> index 0000000..8506a50
>> --- /dev/null
>> +++ b/conf/machine/excavator-rk3399.conf
>> @@ -0,0 +1,12 @@
>> +# Copyright (C) 2017 Fuzhou Rockchip Electronics Co., Ltd
>> +# Released under the MIT license (see COPYING.MIT for the terms)
>> +
>> +#@TYPE: Machine
>> +#@NAME: EXCAVATOR 3399
>> +
>> +include conf/machine/include/rk3399.inc
>> +
>> +KERNEL_DEVICETREE = "rockchip/rk3399-sapphire-excavator.dtb"
>> +UBOOT_MACHINE = "evb-rk3399_defconfig"
>> +
>> +GPTIMG_APPEND = "console=ttyS2,1500000n8 rw root=PARTUUID=B921B045-1DF0 rootfstype=ext4 init=/sbin/init"
>> diff --git a/conf/machine/firefly-rk3399.conf b/conf/machine/firefly-rk3399.conf
>> new file mode 100644
>> index 0000000..4e35c3d
>> --- /dev/null
>> +++ b/conf/machine/firefly-rk3399.conf
>> @@ -0,0 +1,14 @@
>> +# Copyright (C) 2017 Fuzhou Rockchip Electronics Co., Ltd
>> +# Released under the MIT license (see COPYING.MIT for the terms)
>> +
>> +#@TYPE: Machine
>> +#@NAME: Firefly RK3399
>> +#@DESCRIPTION: Firefly-RK3399 is a Six-Core 64-bit High-Performance Platform.
>> +#http://www.t-firefly.com/en/
>> +
>> +include conf/machine/include/rk3399.inc
>> +
>> +KERNEL_DEVICETREE = "rockchip/rk3399-firefly.dtb"
>> +UBOOT_MACHINE = "evb-rk3399_defconfig"
>> +
>> +GPTIMG_APPEND = "console=ttyS2,1500000n8 rw root=PARTUUID=B921B045-1DF0 rootfstype=ext4 init=/sbin/init"
>> diff --git a/conf/machine/include/rk3399.inc b/conf/machine/include/rk3399.inc
>> new file mode 100644
>> index 0000000..9237616
>> --- /dev/null
>> +++ b/conf/machine/include/rk3399.inc
>> @@ -0,0 +1,17 @@
>> +# Copyright (C) 2019 SUMOMO Computer Association
>> +# Released under the MIT license (see COPYING.MIT for the terms)
>> +
>> +SOC_FAMILY = "rk3399"
>> +
>> +require conf/machine/include/tune-cortexa72.inc
>> +require conf/machine/include/soc-family.inc
>> +require conf/machine/include/rockchip-defaults.inc
>> +
>> +SERIAL_CONSOLES = "1500000;ttyS2"
>> +KERNEL_IMAGETYPE = "Image"
>> +KBUILD_DEFCONFIG = "defconfig"
>> +
>> +PREFERRED_PROVIDER_virtual/bootloader ?= "u-boot-rockchip"
> Using u-boot-rockchip causes build failures. In both cases (excavator-rk3399
> and firefly-rk3399) I get:
>
> 	| #
> 	| # configuration written to .config
> 	| #
> 	| make[1]: Leaving directory '/z/build-master/meta-rockchip/build/tmp-glibc/work/firefly_rk3399-oe-linux/u-boot-rockchip/20171218-r0/build'
> 	| make: Leaving directory '/z/build-master/meta-rockchip/build/tmp-glibc/work/firefly_rk3399-oe-linux/u-boot-rockchip/20171218-r0/git'
> 	| /z/build-master/meta-rockchip/build/tmp-glibc/work/firefly_rk3399-oe-linux/u-boot-rockchip/20171218-r0/temp/run.do_configure.27647: line 113: merge_config.sh: command not found
> 	| WARNING: /z/build-master/meta-rockchip/build/tmp-glibc/work/firefly_rk3399-oe-linux/u-boot-rockchip/20171218-r0/temp/run.do_configure.27647:1 exit 127 from 'merge_config.sh -m .config'
> 	| ERROR: Function failed: do_configure (log file is located at /z/build-master/meta-rockchip/build/tmp-glibc/work/firefly_rk3399-oe-linux/u-boot-rockchip/20171218-r0/temp/log.do_configure.27647)
>
> Do you have an updated recipe for u-boot-rockchip?

Yes, it is a bug in the recent u-boot-rockchip recipes, I have just sent 
out patches to fix them, you may have a check.

And about this serial of patches, I sent "conf: use rockchip kernel 4.4 
for firefly release" by mistake, you may ignore this one.

>
>> +
>> +IMAGE_FSTYPES = "rockchip-gpt-img"
>> +IMAGE_CLASSES = "rockchip-gpt-img"
>> -- 
>> 2.20.1
>>
>> -- 
>> _______________________________________________
>> yocto mailing list
>> yocto@yoctoproject.org
>> https://lists.yoctoproject.org/listinfo/yocto