Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

修复编译时的一些报错 #335

Open
RadxaYuntian opened this issue Jun 24, 2024 · 9 comments · Fixed by #338
Open

修复编译时的一些报错 #335

RadxaYuntian opened this issue Jun 24, 2024 · 9 comments · Fixed by #338
Assignees

Comments

@RadxaYuntian
Copy link
Member

有的设备树节点缺少了比如#clock-cells的定义,会在编译时警告。这个因为dts有对应定义,实际上使用是没有问题的,但我们之后会打算增强dts的检查,所以现在先把这些简单的问题修复了

@RadxaYuntian
Copy link
Member Author

按照你的修改后编译还是一大堆新的警告

@RadxaYuntian
Copy link
Member Author

比如/ports: graph node has single child node 'port@0', #address-cells/#size-cells are not necessary就应该把ports/port@0转换成单独的port结点:

https://patchwork.kernel.org/project/linux-arm-kernel/patch/[email protected]/

@RadxaYuntian RadxaYuntian reopened this Jul 1, 2024
@CodeChenL
Copy link
Contributor

比如/ports: graph node has single child node 'port@0', #address-cells/#size-cells are not necessary就应该把ports/port@0转换成单独的port结点:

https://patchwork.kernel.org/project/linux-arm-kernel/patch/[email protected]/

你是使用什么内核?

@RadxaYuntian
Copy link
Member Author

RadxaYuntian commented Jul 1, 2024

diff --git a/arch/arm64/boot/dts/rockchip/overlays/rock-3a-radxa-5inch-touchscreen.dts b/arch/arm64/boot/dts/rockchip/overlays/rock-3a-radxa-5inch-touchscreen.dts
index 42cc5b8..40da825 100644
--- a/arch/arm64/boot/dts/rockchip/overlays/rock-3a-radxa-5inch-touchscreen.dts
+++ b/arch/arm64/boot/dts/rockchip/overlays/rock-3a-radxa-5inch-touchscreen.dts
@@ -39,12 +39,7 @@
                status = "okay";
 
                ports {
-                       #address-cells = <1>;
-                       #size-cells = <0>;
-
-                       port@0 {
-                               reg = <0>;
-
+                       port {
                                panel_in_dsi1: endpoint {
                                        remote-endpoint = <&dsi1_out_panel>;
                                };
@@ -58,11 +53,7 @@
 
                port@1 {
                        reg = <1>;
-                       #address-cells = <1>;
-                       #size-cells = <0>;
-
-                       dsi1_out_panel: endpoint@0 {
-                               reg = <0>;
+                       dsi1_out_panel: endpoint {
                                remote-endpoint = <&panel_in_dsi1>;
                        };
                };

@RadxaYuntian
Copy link
Member Author

我直接用我现在的arch内核运行 make arch/arm64/boot/dts/rockchip/overlays/rock-3a-radxa-5inch-touchscreen.dtbo

@RadxaYuntian
Copy link
Member Author

第一个结点的修改可能有点问题,我看看

@CodeChenL
Copy link
Contributor

我这不会报错啊

[chen@ChenArchLinux 15:48]
[0 ~/Documents/GitHub/overlays]$ make arch/arm64/boot/dts/rockchip/overlays/rock-3a-radxa-5inch-touchscreen.dtbo
cpp -nostdinc -undef -x assembler-with-cpp -E -I "/lib/modules/6.9.7-zen1-1-zen/build/include" "arch/arm64/boot/dts/rockchip/overlays/rock-3a-radxa-5inch-touchscreen.dts" "arch/arm64/boot/dts/rockchip/overlays/rock-3a-radxa-5inch-touchscreen.dtbo.tmp"
dtc -q -@ -I dts -O dtb -o "arch/arm64/boot/dts/rockchip/overlays/rock-3a-radxa-5inch-touchscreen.dtbo" "arch/arm64/boot/dts/rockchip/overlays/rock-3a-radxa-5inch-touchscreen.dtbo.tmp"
[chen@ChenArchLinux 15:48]
[0 ~/Documents/GitHub/overlays]$ uname -a
Linux ChenArchLinux 6.9.7-zen1-1-zen #1 ZEN SMP PREEMPT_DYNAMIC Fri, 28 Jun 2024 04:32:27 +0000 x86_64 GNU/Linux
[chen@ChenArchLinux 15:49]
[0 ~/Documents/GitHub/overlays]$

@RadxaYuntian
Copy link
Member Author

第一个diff我修改了一下,另外你要pull一下你本地的代码,dtc的-q我之前删了

@RadxaYuntian
Copy link
Member Author

可以反编译试一试这么改和有@0的是不是一样的结果

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants