From 68fe3cec25bc9ea4e1bafdb1d9f5315e245d650b Mon Sep 17 00:00:00 2001 From: Anders Dellien Date: Wed, 8 Dec 2021 21:59:36 +0000 Subject: [PATCH 1/5] fix(tc): remove the bootargs node We need to keep the kernel command line in Yocto, otherwise we can't support AVB. Signed-off-by: Anders Dellien Change-Id: Ic291eb13620b307f10354c2c2797c6fc9b053e83 --- fdts/tc.dts | 1 - 1 file changed, 1 deletion(-) diff --git a/fdts/tc.dts b/fdts/tc.dts index 6e119ceba..bd729bb78 100644 --- a/fdts/tc.dts +++ b/fdts/tc.dts @@ -17,7 +17,6 @@ }; chosen { - bootargs = "console=ttyAMA0 debug user_debug=31 earlycon=pl011,0x7ff80000 loglevel=9 androidboot.hardware=total_compute androidboot.boot_devices=1c050000.mmci ip=dhcp androidboot.selinux=permissive allow_mismatched_32bit_el0"; stdout-path = "serial0:115200n8"; }; From 82117bb48180175c25936b0ff9e33563e25e18f4 Mon Sep 17 00:00:00 2001 From: Anders Dellien Date: Sat, 1 Jan 2022 21:51:21 +0000 Subject: [PATCH 2/5] feat(tc): enable GPU Add DTS node for GPU to support hardware rendering in Android Signed-off-by: Anders Dellien Change-Id: I2cf2badf5b15e59a910f6cf7d3d30fdfaf4fe9ce --- fdts/tc.dts | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/fdts/tc.dts b/fdts/tc.dts index bd729bb78..f5ad1a606 100644 --- a/fdts/tc.dts +++ b/fdts/tc.dts @@ -434,6 +434,19 @@ clock-names = "mclk", "apb_pclk"; }; + gpu: gpu@2d000000 { + compatible = "arm,mali-midgard"; + reg = <0x0 0x2d000000 0x0 0x200000>; + interrupts = <0 66 4>, <0 67 4>, <0 65 4>; + interrupt-names = "JOB", "MMU", "GPU"; + clocks = <&soc_refclk100mhz>; + clock-names = "clk_mali"; + operating-points = < + /* KHz uV */ + 50000 820000 + >; + }; + dp0: display@2cc00000 { #address-cells = <1>; #size-cells = <0>; From ad60a42cd79713984065dca8540c091c49755f32 Mon Sep 17 00:00:00 2001 From: Anders Dellien Date: Wed, 8 Dec 2021 21:57:21 +0000 Subject: [PATCH 3/5] feat(tc): add reserved memory region for Gralloc Gralloc for Android S uses dmabuf, we need to add reserved memory area for these allocations Signed-off-by: Anders Dellien Change-Id: If869ac930fadc374ec435cae3847ba374584275b --- fdts/tc.dts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/fdts/tc.dts b/fdts/tc.dts index f5ad1a606..891a4c903 100644 --- a/fdts/tc.dts +++ b/fdts/tc.dts @@ -206,6 +206,13 @@ #size-cells = <2>; ranges; + linux,cma { + compatible = "shared-dma-pool"; + reusable; + size = <0x0 0x8000000>; + linux,cma-default; + }; + optee@0xfce00000 { reg = <0x00000000 0xfce00000 0 0x00200000>; no-map; From 4a6ebeeca37ece34a58982c8b6ebdc8cfd70814b Mon Sep 17 00:00:00 2001 From: Anders Dellien Date: Sat, 1 Jan 2022 21:56:25 +0000 Subject: [PATCH 4/5] feat(tc): enable SMMU for DPU The SMMU needs to be enabled to support 8GB RAM Signed-off-by: Anders Dellien Change-Id: Ie81f2fc59886c52e9d6ed799ea73f49eb7a7c307 --- fdts/tc.dts | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/fdts/tc.dts b/fdts/tc.dts index 891a4c903..7c0e84260 100644 --- a/fdts/tc.dts +++ b/fdts/tc.dts @@ -454,6 +454,13 @@ >; }; + smmu: smmu@2ce00000 { + #iommu-cells = <1>; + compatible = "arm,smmu-v3"; + reg = <0x0 0x2ce00000 0x0 0x20000>; + status = "okay"; + }; + dp0: display@2cc00000 { #address-cells = <1>; #size-cells = <0>; @@ -463,6 +470,9 @@ interrupt-names = "DPU"; clocks = <&scmi_clk 0>; clock-names = "aclk"; + iommus = <&smmu 0>, <&smmu 1>, <&smmu 2>, <&smmu 3>, + <&smmu 4>, <&smmu 5>, <&smmu 6>, <&smmu 7>, + <&smmu 8>, <&smmu 9>; pl0: pipeline@0 { reg = <0>; clocks = <&scmi_clk 1>; From b06344a3f2c5a0fede3646627f37d1fce3d3d585 Mon Sep 17 00:00:00 2001 From: Anders Dellien Date: Fri, 7 Jan 2022 13:26:29 +0000 Subject: [PATCH 5/5] fix(sptool): add leading zeroes in UUID conversion The UUID conversion drops leading zeroes, so make sure that all hex strings always are 8 digits long Signed-off-by: Anders Dellien Change-Id: I5d7e3cf3b53403a02bf551f35f17dbdb96dec8ae --- tools/sptool/sp_mk_generator.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/sptool/sp_mk_generator.py b/tools/sptool/sp_mk_generator.py index f983ff3a2..6b1f20447 100755 --- a/tools/sptool/sp_mk_generator.py +++ b/tools/sptool/sp_mk_generator.py @@ -1,5 +1,5 @@ #!/usr/bin/python3 -# Copyright (c) 2020-2021, Arm Limited. All rights reserved. +# Copyright (c) 2020-2022, Arm Limited. All rights reserved. # # SPDX-License-Identifier: BSD-3-Clause @@ -134,7 +134,7 @@ with open(gen_file, 'w') as out_file: int.from_bytes(y[1], byteorder='little', signed=False), int.from_bytes(y[2], byteorder='little', signed=False), int.from_bytes(y[3], byteorder='little', signed=False)) - uuid_std = uuid.UUID(f'{z[0]:04x}{z[1]:04x}{z[2]:04x}{z[3]:04x}') + uuid_std = uuid.UUID(f'{z[0]:08x}{z[1]:08x}{z[2]:08x}{z[3]:08x}') """ Append FIP_ARGS