From 7d07b3ae8ddad407913c5301877e694430a3263f Mon Sep 17 00:00:00 2001
From: hc <hc@nodka.com>
Date: Thu, 23 Nov 2023 08:24:31 +0000
Subject: [PATCH] add build kerneldeb
---
u-boot/common/fb_mmc.c | 18 ++++++++++++++++++
1 files changed, 18 insertions(+), 0 deletions(-)
diff --git a/u-boot/common/fb_mmc.c b/u-boot/common/fb_mmc.c
index e083daa..f292d0d 100755
--- a/u-boot/common/fb_mmc.c
+++ b/u-boot/common/fb_mmc.c
@@ -31,6 +31,15 @@
#define CONFIG_FASTBOOT_MBR_NAME "mbr"
#endif
+#ifndef CONFIG_FASTBOOT_IDBLOCK_NAME
+#define CONFIG_FASTBOOT_IDBLOCK_NAME "idblock"
+#endif
+
+#define CONFIG_FASTBOOT_MMC_BLOCK_SIZE 512
+#define CONFIG_FASTBOOT_IDBLOCK_SECTOR 64
+/* idblock sector:64 ~ 64 + 5 * 1024(512K for each MiniloadAll.bin) */
+#define CONFIG_FASTBOOT_IDBLOCK_SECTOR_SIZE 5184
+
#define BOOT_PARTITION_NAME "boot"
#define FASTBOOT_MAX_BLK_WRITE 16384
static ulong timer;
@@ -363,6 +372,14 @@
}
#endif
+ if (strcmp(cmd, CONFIG_FASTBOOT_IDBLOCK_NAME) == 0) {
+ printf("%s: updating IDBLOCK\n", __func__);
+ info.blksz = CONFIG_FASTBOOT_MMC_BLOCK_SIZE;
+ info.start = CONFIG_FASTBOOT_IDBLOCK_SECTOR;
+ info.size = CONFIG_FASTBOOT_IDBLOCK_SECTOR_SIZE;
+ goto download;
+ }
+
#ifdef CONFIG_ANDROID_BOOT_IMAGE
if (strncasecmp(cmd, "zimage", 6) == 0) {
fb_mmc_update_zimage(dev_desc, download_buffer, download_bytes, response);
@@ -376,6 +393,7 @@
return;
}
+download:
if (is_sparse_image(download_buffer)) {
struct fb_mmc_sparse sparse_priv;
struct sparse_storage sparse;
--
Gitblit v1.6.2