From f33f61bdb7ca6d5ebe7a78f9d8694b91360279ac Mon Sep 17 00:00:00 2001
From: hc <hc@nodka.com>
Date: Mon, 04 Dec 2023 07:10:27 +0000
Subject: [PATCH] add gpio
---
u-boot/arch/arm/mach-rockchip/kernel_dtb.c | 17 ++++++++++-------
1 files changed, 10 insertions(+), 7 deletions(-)
diff --git a/u-boot/arch/arm/mach-rockchip/kernel_dtb.c b/u-boot/arch/arm/mach-rockchip/kernel_dtb.c
old mode 100755
new mode 100644
index 74da167..ce492b9
--- a/u-boot/arch/arm/mach-rockchip/kernel_dtb.c
+++ b/u-boot/arch/arm/mach-rockchip/kernel_dtb.c
@@ -815,12 +815,10 @@
return -ENODEV;
}
- if (IS_ENABLED(CONFIG_EMBED_KERNEL_DTB_ALWAYS)) {
- resource_init_list();
- printf("Always embed kernel dtb\n");
- goto dtb_embed;
- }
-
+#ifdef CONFIG_EMBED_KERNEL_DTB_ALWAYS
+ printf("Always embed kernel dtb\n");
+ goto dtb_embed;
+#endif
ret = rockchip_read_dtb_file((void *)fdt_addr);
if (!ret) {
if (!dtb_check_ok((void *)fdt_addr, (void *)gd->fdt_blob)) {
@@ -831,7 +829,10 @@
}
}
+#ifdef CONFIG_EMBED_KERNEL_DTB
+#ifdef CONFIG_EMBED_KERNEL_DTB_ALWAYS
dtb_embed:
+#endif
if (gd->fdt_blob_kern) {
if (!dtb_check_ok((void *)gd->fdt_blob_kern, (void *)gd->fdt_blob)) {
printf("Embedded kernel dtb mismatch this platform!\n");
@@ -850,7 +851,9 @@
memcpy((void *)fdt_addr, gd->fdt_blob_kern,
fdt_totalsize(gd->fdt_blob_kern));
printf("DTB: %s\n", CONFIG_EMBED_KERNEL_DTB_PATH);
- } else {
+ } else
+#endif
+ {
printf("Failed to get kernel dtb, ret=%d\n", ret);
return -ENOENT;
}
--
Gitblit v1.6.2