From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 85E4BC64EC5 for ; Thu, 9 Feb 2023 14:30:47 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 0804685EED; Thu, 9 Feb 2023 15:30:45 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=baylibre-com.20210112.gappssmtp.com header.i=@baylibre-com.20210112.gappssmtp.com header.b="fqvSO44k"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 7359A85EEF; Thu, 9 Feb 2023 15:30:42 +0100 (CET) Received: from mail-wr1-x42a.google.com (mail-wr1-x42a.google.com [IPv6:2a00:1450:4864:20::42a]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 9E95E85D48 for ; Thu, 9 Feb 2023 15:30:38 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=mkorpershoek@baylibre.com Received: by mail-wr1-x42a.google.com with SMTP id j23so2008902wra.0 for ; Thu, 09 Feb 2023 06:30:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20210112.gappssmtp.com; s=20210112; h=mime-version:message-id:date:references:in-reply-to:subject:cc:to :from:from:to:cc:subject:date:message-id:reply-to; bh=7Q140KxfUj5uBHxDa51vtrAvWf6ei7lL4VOhGiIhMHQ=; b=fqvSO44kIV+JUCB+q6/xrU6zRvPRZmZlPe7Cw/cGQrcSKrAkLSrsJozo4wUK5OKlIh wXl6kUR3pWg5MN4cPR96CcfAIcX2PXd0bpNIOAs5NxaaQJULhLg/q7iX08x/EnpQqIrT 4L8vjVAnkz6U8RsW/4C0mgofFE0oqcaiSQhuZKf2QVQXPGNGwTa52Z4d3+MriM9EtfJg MexqbxbVJrHzmKBYq34ZLxj4CQrz+A9DT3zW//qQu4l9TDlIClCLGAbVpyzr0hgzGluh WlmFD3rRiDQ1pXbt3lmPRwUqzR+aYbxWBfYbu9fKcL7DVDcCTAKnZ0YLHjEZl56OpuKi iSCQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=mime-version:message-id:date:references:in-reply-to:subject:cc:to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=7Q140KxfUj5uBHxDa51vtrAvWf6ei7lL4VOhGiIhMHQ=; b=VoT7frc3F5Kkt8P02X2dgvad6O5Se2Te5d6QCJV64+adxnN3O+Rp86f9RtIF7yXliV YpLdAlJGcR4wBnio3XjWTgozgTTS7p01XdplvAvu2zLRMgI3qhv7PHHQJ2Zh5AcYtOpR AGQOPVDeDJ8oyNaObPsadUe5M8TErcyrPFVrxMZVM3WwID5nYka1Yj96hzN8gWW/aeGu pasRSnDGsTGKh60fa2D7qiQIOzAo2SMTRlgjJG2okeVLrA7SGMC8U9VWQ2lrMjNdoNLa OAX+xK3eFE8VbQXwfD1QBcI3aGi7lSNP7wome1VZnwA7HgvAeZDvdPJUatA6uJDU69S0 lm4w== X-Gm-Message-State: AO0yUKX2PqlXm6f200+EsspiWIhchYT0GyPkAWfehBAytQ8kCAWkKEDm 24v7UtNUVcGxBcfktrfwzAqfNQ== X-Google-Smtp-Source: AK7set+tzBZqCmEMtg9q4eSvblojD8GLaT+VwzL0AQY549k6QfwBR0c9jBkkr/JZdSxkRGMcpVHYVA== X-Received: by 2002:a5d:6b4f:0:b0:2bf:b68a:e122 with SMTP id x15-20020a5d6b4f000000b002bfb68ae122mr10784941wrw.33.1675953038078; Thu, 09 Feb 2023 06:30:38 -0800 (PST) Received: from localhost ([82.66.159.240]) by smtp.gmail.com with ESMTPSA id i12-20020a5d438c000000b002c512f56859sm1222771wrq.70.2023.02.09.06.30.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 09 Feb 2023 06:30:37 -0800 (PST) From: Mattijs Korpershoek To: Safae Ouajih , sjg@chromium.org Cc: u-boot@lists.denx.de, sean.anderson@seco.com, r.stratiienko@gmail.com, glaroque@baylibre.com, khilman@baylibre.com Subject: Re: [PATCH v3 09/19] android: boot: add vendor boot image to prepare for v3,v4 support In-Reply-To: <20230205235021.355410-10-souajih@baylibre.com> References: <20230205235021.355410-1-souajih@baylibre.com> <20230205235021.355410-10-souajih@baylibre.com> Date: Thu, 09 Feb 2023 15:30:36 +0100 Message-ID: <874jrukj1v.fsf@baylibre.com> MIME-Version: 1.0 Content-Type: text/plain X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean On Mon, Feb 06, 2023 at 00:50, Safae Ouajih wrote: > Introduce vendor boot image for version 3 and 4 of boot image header. > The vendor boot image will hold extra information about kernel, dtb > and ramdisk. > > This is done to prepare for boot image version 3 and 4 support. > > Signed-off-by: Safae Ouajih Reviewed-by: Mattijs Korpershoek > --- > boot/bootm.c | 8 +++---- > boot/image-android.c | 54 ++++++++++++++++++++++++++++---------------- > boot/image-board.c | 3 +-- > boot/image-fdt.c | 3 ++- > cmd/abootimg.c | 4 ++-- > include/image.h | 48 ++++++++++++++++++++++++++++++--------- > 6 files changed, 81 insertions(+), 39 deletions(-) > > diff --git a/boot/bootm.c b/boot/bootm.c > index 15fce8ad95..a58e6f391e 100644 > --- a/boot/bootm.c > +++ b/boot/bootm.c > @@ -182,11 +182,11 @@ static int bootm_find_os(struct cmd_tbl *cmdtp, int flag, int argc, > #ifdef CONFIG_ANDROID_BOOT_IMAGE > case IMAGE_FORMAT_ANDROID: > images.os.type = IH_TYPE_KERNEL; > - images.os.comp = android_image_get_kcomp(os_hdr); > + images.os.comp = android_image_get_kcomp(os_hdr, NULL); > images.os.os = IH_OS_LINUX; > > - images.os.end = android_image_get_end(os_hdr); > - images.os.load = android_image_get_kload(os_hdr); > + images.os.end = android_image_get_end(os_hdr, NULL); > + images.os.load = android_image_get_kload(os_hdr, NULL); > images.ep = images.os.load; > ep_found = true; > break; > @@ -965,7 +965,7 @@ static const void *boot_get_kernel(struct cmd_tbl *cmdtp, int flag, int argc, > #ifdef CONFIG_ANDROID_BOOT_IMAGE > case IMAGE_FORMAT_ANDROID: > printf("## Booting Android Image at 0x%08lx ...\n", img_addr); > - if (android_image_get_kernel(buf, images->verify, > + if (android_image_get_kernel(buf, NULL, images->verify, > os_data, os_len)) > return NULL; > break; > diff --git a/boot/image-android.c b/boot/image-android.c > index 748fd212ae..f16eebff49 100644 > --- a/boot/image-android.c > +++ b/boot/image-android.c > @@ -66,7 +66,8 @@ static void android_boot_image_v0_v1_v2_parse_hdr(const struct andr_boot_img_hdr > data->boot_img_total_size = end - (ulong)hdr; > } > > -bool android_image_get_data(const void *boot_hdr, struct andr_image_data *data) > +bool android_image_get_data(const void *boot_hdr, const void *vendor_boot_hdr, > + struct andr_image_data *data) > { > if (!boot_hdr || !data) { > printf("boot_hdr or data params can't be NULL\n"); > @@ -114,8 +115,10 @@ static ulong android_image_get_kernel_addr(struct andr_image_data *img_data) > > /** > * android_image_get_kernel() - processes kernel part of Android boot images > - * @hdr: Pointer to image header, which is at the start > + * @hdr: Pointer to boot image header, which is at the start > * of the image. > + * @vendor_boot_img: Pointer to vendor boot image header, which is at the > + * start of the image. > * @verify: Checksum verification flag. Currently unimplemented. > * @os_data: Pointer to a ulong variable, will hold os data start > * address. > @@ -127,14 +130,15 @@ static ulong android_image_get_kernel_addr(struct andr_image_data *img_data) > * Return: Zero, os start address and length on success, > * otherwise on failure. > */ > -int android_image_get_kernel(const struct andr_boot_img_hdr_v0 *hdr, int verify, > +int android_image_get_kernel(const struct andr_boot_img_hdr_v0 *hdr, > + const void *vendor_boot_img, int verify, > ulong *os_data, ulong *os_len) > { > struct andr_image_data img_data = {0}; > u32 kernel_addr; > const struct legacy_img_hdr *ihdr; > > - if (!android_image_get_data(hdr, &img_data)) > + if (!android_image_get_data(hdr, vendor_boot_img, &img_data)) > return -EINVAL; > > kernel_addr = android_image_get_kernel_addr(&img_data); > @@ -201,11 +205,12 @@ bool is_android_boot_image_header(const struct andr_boot_img_hdr_v0 *hdr) > return !memcmp(ANDR_BOOT_MAGIC, hdr, ANDR_BOOT_MAGIC_SIZE); > } > > -ulong android_image_get_end(const struct andr_boot_img_hdr_v0 *hdr) > +ulong android_image_get_end(const struct andr_boot_img_hdr_v0 *hdr, > + const void *vendor_boot_img) > { > struct andr_image_data img_data; > > - if (!android_image_get_data(hdr, &img_data)) > + if (!android_image_get_data(hdr, vendor_boot_img, &img_data)) > return -EINVAL; > > if (img_data.header_version > 2) > @@ -214,22 +219,24 @@ ulong android_image_get_end(const struct andr_boot_img_hdr_v0 *hdr) > return img_data.boot_img_total_size; > } > > -ulong android_image_get_kload(const struct andr_boot_img_hdr_v0 *hdr) > +ulong android_image_get_kload(const struct andr_boot_img_hdr_v0 *hdr, > + const void *vendor_boot_img) > { > struct andr_image_data img_data; > > - if (!android_image_get_data(hdr, &img_data)) > + if (!android_image_get_data(hdr, vendor_boot_img, &img_data)) > return -EINVAL; > > return android_image_get_kernel_addr(&img_data); > } > > -ulong android_image_get_kcomp(const struct andr_boot_img_hdr_v0 *hdr) > +ulong android_image_get_kcomp(const struct andr_boot_img_hdr_v0 *hdr, > + const void *vendor_boot_img) > { > struct andr_image_data img_data; > const void *p; > > - if (!android_image_get_data(hdr, &img_data)) > + if (!android_image_get_data(hdr, vendor_boot_img, &img_data)) > return -EINVAL; > > p = (const void *)img_data.kernel_ptr; > @@ -242,11 +249,11 @@ ulong android_image_get_kcomp(const struct andr_boot_img_hdr_v0 *hdr) > } > > int android_image_get_ramdisk(const struct andr_boot_img_hdr_v0 *hdr, > - ulong *rd_data, ulong *rd_len) > + const void *vendor_boot_img, ulong *rd_data, ulong *rd_len) > { > struct andr_image_data img_data = {0}; > > - if (!android_image_get_data(hdr, &img_data)) > + if (!android_image_get_data(hdr, vendor_boot_img, &img_data)) > return -EINVAL; > > if (!img_data.ramdisk_size) { > @@ -268,7 +275,7 @@ int android_image_get_second(const struct andr_boot_img_hdr_v0 *hdr, > { > struct andr_image_data img_data; > > - if (!android_image_get_data(hdr, &img_data)) > + if (!android_image_get_data(hdr, NULL, &img_data)) > return -EINVAL; > > if (!img_data.second_size) { > @@ -348,11 +355,12 @@ exit: > /** > * android_image_get_dtb_img_addr() - Get the address of DTB area in boot image. > * @hdr_addr: Boot image header address > + * @vhdr_addr: Vendor Boot image header address > * @addr: Will contain the address of DTB area in boot image > * > * Return: true on success or false on fail. > */ > -static bool android_image_get_dtb_img_addr(ulong hdr_addr, ulong *addr) > +static bool android_image_get_dtb_img_addr(ulong hdr_addr, ulong vhdr_addr, ulong *addr) > { > const struct andr_boot_img_hdr_v0 *hdr; > ulong dtb_img_addr; > @@ -395,6 +403,7 @@ exit: > /** > * android_image_get_dtb_by_index() - Get address and size of blob in DTB area. > * @hdr_addr: Boot image header address > + * @vendor_boot_img: Pointer to vendor boot image header, which is at the start of the image. > * @index: Index of desired DTB in DTB area (starting from 0) > * @addr: If not NULL, will contain address to specified DTB > * @size: If not NULL, will contain size of specified DTB > @@ -404,17 +413,24 @@ exit: > * > * Return: true on success or false on error. > */ > -bool android_image_get_dtb_by_index(ulong hdr_addr, u32 index, ulong *addr, > - u32 *size) > +bool android_image_get_dtb_by_index(ulong hdr_addr, ulong vendor_boot_img, > + u32 index, ulong *addr, u32 *size) > { > struct andr_image_data img_data; > const struct andr_boot_img_hdr_v0 *hdr; > + const struct andr_vnd_boot_img_hdr *vhdr; > > hdr = map_sysmem(hdr_addr, sizeof(*hdr)); > - if (!android_image_get_data(hdr, &img_data)) { > + if (vendor_boot_img != -1) > + vhdr = map_sysmem(vendor_boot_img, sizeof(*vhdr)); > + if (!android_image_get_data(hdr, vhdr, &img_data)) { > + if (vendor_boot_img != -1) > + unmap_sysmem(vhdr); > unmap_sysmem(hdr); > return false; > } > + if (vendor_boot_img != -1) > + unmap_sysmem(vhdr); > unmap_sysmem(hdr); > > ulong dtb_img_addr; /* address of DTB part in boot image */ > @@ -422,7 +438,7 @@ bool android_image_get_dtb_by_index(ulong hdr_addr, u32 index, ulong *addr, > ulong dtb_addr; /* address of DTB blob with specified index */ > u32 i; /* index iterator */ > > - android_image_get_dtb_img_addr(hdr_addr, &dtb_img_addr); > + android_image_get_dtb_img_addr(hdr_addr, vendor_boot_img, &dtb_img_addr); > /* Check if DTB area of boot image is in DTBO format */ > if (android_dt_check_header(dtb_img_addr)) { > return android_dt_get_fdt_by_index(dtb_img_addr, index, addr, > @@ -578,7 +594,7 @@ bool android_image_print_dtb_contents(ulong hdr_addr) > ulong dtb_addr; /* address of DTB blob with specified index */ > u32 i; /* index iterator */ > > - res = android_image_get_dtb_img_addr(hdr_addr, &dtb_img_addr); > + res = android_image_get_dtb_img_addr(hdr_addr, 0, &dtb_img_addr); > if (!res) > return false; > > diff --git a/boot/image-board.c b/boot/image-board.c > index 9295b6d0c8..b6c9bbe8f5 100644 > --- a/boot/image-board.c > +++ b/boot/image-board.c > @@ -428,8 +428,7 @@ static int select_ramdisk(struct bootm_headers *images, const char *select, u8 a > if (IS_ENABLED(CONFIG_ANDROID_BOOT_IMAGE)) { > void *ptr = map_sysmem(images->os.start, 0); > int ret; > - > - ret = android_image_get_ramdisk(ptr, rd_datap, rd_lenp); > + ret = android_image_get_ramdisk(ptr, NULL, rd_datap, rd_lenp); > unmap_sysmem(ptr); > if (ret) > return ret; > diff --git a/boot/image-fdt.c b/boot/image-fdt.c > index 1181cb60f0..f270d00a5f 100644 > --- a/boot/image-fdt.c > +++ b/boot/image-fdt.c > @@ -536,7 +536,8 @@ int boot_get_fdt(int flag, int argc, char *const argv[], uint8_t arch, > * Firstly check if this android boot image has dtb field. > */ > dtb_idx = (u32)env_get_ulong("adtb_idx", 10, 0); > - if (android_image_get_dtb_by_index((ulong)hdr, dtb_idx, &fdt_addr, &fdt_size)) { > + if (android_image_get_dtb_by_index((ulong)hdr, 0, > + dtb_idx, &fdt_addr, &fdt_size)) { > fdt_blob = (char *)map_sysmem(fdt_addr, 0); > if (fdt_check_header(fdt_blob)) > goto no_fdt; > diff --git a/cmd/abootimg.c b/cmd/abootimg.c > index f04a7c7c8e..4d6cf0fa3e 100644 > --- a/cmd/abootimg.c > +++ b/cmd/abootimg.c > @@ -72,7 +72,7 @@ static int abootimg_get_dtb_load_addr(int argc, char *const argv[]) > const struct andr_boot_img_hdr_v0 *hdr; > > hdr = map_sysmem(abootimg_addr(), sizeof(*hdr)); > - if (!android_image_get_data(hdr, &img_data)) { > + if (!android_image_get_data(hdr, NULL, &img_data)) { > unmap_sysmem(hdr); > return CMD_RET_FAILURE; > } > @@ -119,7 +119,7 @@ static int abootimg_get_dtb_by_index(int argc, char *const argv[]) > return CMD_RET_FAILURE; > } > > - if (!android_image_get_dtb_by_index(abootimg_addr(), num, > + if (!android_image_get_dtb_by_index(abootimg_addr(), 0, num, > &addr, &size)) { > return CMD_RET_FAILURE; > } > diff --git a/include/image.h b/include/image.h > index 4bf6c98ced..f84c03f08f 100644 > --- a/include/image.h > +++ b/include/image.h > @@ -1736,16 +1736,19 @@ struct cipher_algo *image_get_cipher_algo(const char *full_name); > struct andr_image_data; > > /** > - * android_image_get_data() - Parse Android boot image > + * android_image_get_data() - Parse Android boot images > * > - * This is used to parse boot image header into andr_image_data > - * generic structure. > + * This is used to parse boot and vendor-boot header into > + * andr_image_data generic structure. > * > * @boot_hdr: Pointer to boot image header > + * @vendor_boot_hdr: Pointer to vendor boot image header > * @data: Pointer to generic boot format structure > * Return: true if succeeded, false otherwise > */ > -bool android_image_get_data(const void *boot_hdr, struct andr_image_data *data); > +bool android_image_get_data(const void *boot_hdr, const void *vendor_boot_hdr, > + struct andr_image_data *data); > + > struct andr_boot_img_hdr_v0; > > /** > @@ -1756,6 +1759,7 @@ struct andr_boot_img_hdr_v0; > * > * @hdr: Pointer to image header, which is at the start > * of the image. > + * @vendor_boot_img : Pointer to vendor boot image header > * @verify: Checksum verification flag. Currently unimplemented. > * @os_data: Pointer to a ulong variable, will hold os data start > * address. > @@ -1763,7 +1767,8 @@ struct andr_boot_img_hdr_v0; > * Return: Zero, os start address and length on success, > * otherwise on failure. > */ > -int android_image_get_kernel(const struct andr_boot_img_hdr_v0 *hdr, int verify, > +int android_image_get_kernel(const struct andr_boot_img_hdr_v0 *hdr, > + const void *vendor_boot_img, int verify, > ulong *os_data, ulong *os_len); > > /** > @@ -1772,12 +1777,13 @@ int android_image_get_kernel(const struct andr_boot_img_hdr_v0 *hdr, int verify, > * This extracts the load address of the ramdisk and its size > * > * @hdr: Pointer to image header > + * @vendor_boot_img : Pointer to vendor boot image header > * @rd_data: Pointer to a ulong variable, will hold ramdisk address > * @rd_len: Pointer to a ulong variable, will hold ramdisk length > * Return: 0 if succeeded, -1 if ramdisk size is 0 > */ > int android_image_get_ramdisk(const struct andr_boot_img_hdr_v0 *hdr, > - ulong *rd_data, ulong *rd_len); > + const void *vendor_boot_img, ulong *rd_data, ulong *rd_len); > > /** > * android_image_get_second() - Extracts the secondary bootloader address > @@ -1793,8 +1799,22 @@ int android_image_get_ramdisk(const struct andr_boot_img_hdr_v0 *hdr, > int android_image_get_second(const struct andr_boot_img_hdr_v0 *hdr, > ulong *second_data, ulong *second_len); > bool android_image_get_dtbo(ulong hdr_addr, ulong *addr, u32 *size); > -bool android_image_get_dtb_by_index(ulong hdr_addr, u32 index, ulong *addr, > - u32 *size); > + > +/** > + * android_image_get_dtb_by_index() - Get address and size of blob in DTB area. > + * @hdr_addr: Boot image header address > + * @vendor_boot_img: Pointer to vendor boot image header, which is at the start of the image. > + * @index: Index of desired DTB in DTB area (starting from 0) > + * @addr: If not NULL, will contain address to specified DTB > + * @size: If not NULL, will contain size of specified DTB > + * > + * Get the address and size of DTB blob by its index in DTB area of Android > + * Boot Image in RAM. > + * > + * Return: true on success or false on error. > + */ > +bool android_image_get_dtb_by_index(ulong hdr_addr, ulong vendor_boot_img, > + u32 index, ulong *addr, u32 *size); > > /** > * android_image_get_end() - Get the end of Android boot image > @@ -1802,9 +1822,11 @@ bool android_image_get_dtb_by_index(ulong hdr_addr, u32 index, ulong *addr, > * This returns the end address of Android boot image address > * > * @hdr: Pointer to image header > + * @vendor_boot_img : Pointer to vendor boot image header > * Return: The end address of Android boot image > */ > -ulong android_image_get_end(const struct andr_boot_img_hdr_v0 *hdr); > +ulong android_image_get_end(const struct andr_boot_img_hdr_v0 *hdr, > + const void *vendor_boot_img); > > /** > * android_image_get_kload() - Get the kernel load address > @@ -1813,9 +1835,11 @@ ulong android_image_get_end(const struct andr_boot_img_hdr_v0 *hdr); > * from the boot image header or the "kernel_addr_r" environment variable > * > * @hdr: Pointer to image header > + * @vendor_boot_img : Pointer to vendor boot image header > * Return: The kernel load address > */ > -ulong android_image_get_kload(const struct andr_boot_img_hdr_v0 *hdr); > +ulong android_image_get_kload(const struct andr_boot_img_hdr_v0 *hdr, > + const void *vendor_boot_img); > > /** > * android_image_get_kcomp() - Get kernel compression type > @@ -1823,9 +1847,11 @@ ulong android_image_get_kload(const struct andr_boot_img_hdr_v0 *hdr); > * This gets the kernel compression type from the boot image header > * > * @hdr: Pointer to image header > + * @vendor_boot_img : Pointer to vendor boot image header > * Return: Kernel compression type > */ > -ulong android_image_get_kcomp(const struct andr_boot_img_hdr_v0 *hdr); > +ulong android_image_get_kcomp(const struct andr_boot_img_hdr_v0 *hdr, > + const void *vendor_boot_img); > > /** > * android_print_contents() - Prints out the contents of the Android format image > -- > 2.34.1