[{"id":1765716,"web_url":"http://patchwork.ozlabs.org/comment/1765716/","msgid":"<CAPnjgZ1wg_FHKhRJkhhp2ya-f8d3+gvQ8SuhchLh3RvTS8t=Yw@mail.gmail.com>","list_archive_url":null,"date":"2017-09-09T04:53:51","subject":"Re: [U-Boot] [PATCH v3 06/14] fit: Do not throw away extra\n\tconfiguration on fit_image_load()","submitter":{"id":6170,"url":"http://patchwork.ozlabs.org/api/people/6170/","name":"Simon Glass","email":"sjg@chromium.org"},"content":"Hi,\n\nOn 4 September 2017 at 14:12, Pantelis Antoniou\n<pantelis.antoniou@konsulko.com> wrote:\n> fit_image_load() threw away the extra configuration parts when\n> loading. We need them around for applying extra overlays for\n> building the boot fdt.\n>\n> Signed-off-by: Pantelis Antoniou <pantelis.antoniou@konsulko.com>\n> ---\n>  common/image-fit.c | 11 +++++++----\n>  1 file changed, 7 insertions(+), 4 deletions(-)\n\nAcked-by: Simon Glass <sjg@chromium.org>\n\n>\n> diff --git a/common/image-fit.c b/common/image-fit.c\n> index 74e5557..e75cb64 100644\n> --- a/common/image-fit.c\n> +++ b/common/image-fit.c\n> @@ -1653,6 +1653,7 @@ int fit_image_load(bootm_headers_t *images, ulong addr,\n>         int cfg_noffset, noffset;\n>         const char *fit_uname;\n>         const char *fit_uname_config;\n> +       const char *fit_base_uname_config;\n>         const void *fit;\n>         const void *buf;\n>         size_t size;\n> @@ -1668,6 +1669,7 @@ int fit_image_load(bootm_headers_t *images, ulong addr,\n>         fit = map_sysmem(addr, 0);\n>         fit_uname = fit_unamep ? *fit_unamep : NULL;\n>         fit_uname_config = fit_uname_configp ? *fit_uname_configp : NULL;\n> +       fit_base_uname_config = NULL;\n>         prop_name = fit_get_image_type_property(image_type);\n>         printf(\"## Loading %s from FIT Image at %08lx ...\\n\", prop_name, addr);\n>\n> @@ -1701,11 +1703,11 @@ int fit_image_load(bootm_headers_t *images, ulong addr,\n>                                         BOOTSTAGE_SUB_NO_UNIT_NAME);\n>                         return -ENOENT;\n>                 }\n> -               fit_uname_config = fdt_get_name(fit, cfg_noffset, NULL);\n> -               printf(\"   Using '%s' configuration\\n\", fit_uname_config);\n> +               fit_base_uname_config = fdt_get_name(fit, cfg_noffset, NULL);\n> +               printf(\"   Using '%s' configuration\\n\", fit_base_uname_config);\n>                 if (image_type == IH_TYPE_KERNEL) {\n>                         /* Remember (and possibly verify) this config */\n> -                       images->fit_uname_cfg = fit_uname_config;\n> +                       images->fit_uname_cfg = fit_base_uname_config;\n>                         if (IMAGE_ENABLE_VERIFY && images->verify) {\n>                                 puts(\"   Verifying Hash Integrity ... \");\n>                                 if (fit_config_verify(fit, cfg_noffset)) {\n> @@ -1861,7 +1863,8 @@ int fit_image_load(bootm_headers_t *images, ulong addr,\n>         if (fit_unamep)\n>                 *fit_unamep = (char *)fit_uname;\n>         if (fit_uname_configp)\n> -               *fit_uname_configp = (char *)fit_uname_config;\n> +               *fit_uname_configp = (char *)(fit_uname_config ? :\n> +                                             fit_base_uname_config);\n\nI just learned something I didn't know about C.\n\n>\n>         return noffset;\n>  }\n> --\n> 2.1.4\n>","headers":{"Return-Path":"<u-boot-bounces@lists.denx.de>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@bilbo.ozlabs.org","Authentication-Results":["ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=lists.denx.de\n\t(client-ip=81.169.180.215; helo=lists.denx.de;\n\tenvelope-from=u-boot-bounces@lists.denx.de;\n\treceiver=<UNKNOWN>)","ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n\tunprotected) header.d=google.com header.i=@google.com\n\theader.b=\"QJrFplVc\"; \n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=chromium.org header.i=@chromium.org\n\theader.b=\"l5ZKx6a5\"; dkim-atps=neutral"],"Received":["from lists.denx.de (dione.denx.de [81.169.180.215])\n\tby ozlabs.org (Postfix) with ESMTP id 3xq29b6dxHz9sBZ\n\tfor <incoming@patchwork.ozlabs.org>;\n\tSat,  9 Sep 2017 15:02:11 +1000 (AEST)","by lists.denx.de (Postfix, from userid 105)\n\tid A19BFC21E84; Sat,  9 Sep 2017 04:58:33 +0000 (UTC)","from lists.denx.de (localhost [IPv6:::1])\n\tby lists.denx.de (Postfix) with ESMTP id 9BBE6C21C60;\n\tSat,  9 Sep 2017 04:56:34 +0000 (UTC)","by lists.denx.de (Postfix, from userid 105)\n\tid D3CA1C21E84; Sat,  9 Sep 2017 04:56:30 +0000 (UTC)","from mail-qt0-f169.google.com (mail-qt0-f169.google.com\n\t[209.85.216.169])\n\tby lists.denx.de (Postfix) with ESMTPS id 441FEC21E1D\n\tfor <u-boot@lists.denx.de>; Sat,  9 Sep 2017 04:54:13 +0000 (UTC)","by mail-qt0-f169.google.com with SMTP id q8so10590365qtb.5\n\tfor <u-boot@lists.denx.de>; Fri, 08 Sep 2017 21:54:13 -0700 (PDT)","by 10.200.37.200 with HTTP; Fri, 8 Sep 2017 21:53:51 -0700 (PDT)"],"X-Spam-Checker-Version":"SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de","X-Spam-Level":"","X-Spam-Status":"No, score=-0.0 required=5.0 tests=RCVD_IN_DNSWL_NONE,\n\tRCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL,\n\tT_DKIM_INVALID autolearn=unavailable\n\tautolearn_force=no version=3.4.0","DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com;\n\ts=20161025; \n\th=mime-version:sender:in-reply-to:references:from:date:message-id\n\t:subject:to:cc;\n\tbh=6GuHZAD3u/ZWBydwAg0wYacSXhNgtzg7eZOdWPStWcA=;\n\tb=QJrFplVcArV8eG1UFH3u28xHMnvV9oGg9nJoZ36iLSnIus46EuECTje8Tsz5SWcgY+\n\tWSCb25w97G12p/y68BV3Ci6tp8aFin08g/a2P0sMDnOg7nYaBDPFt1xbQInsNfdXHQG2\n\tjm9KOm98SXbBC6nXk9SS+49VtjJqZeLq3Z4XIUOKW1fIZZmH8bzPp2FVeynAVh6uikFL\n\tmsNdbEixBkdMFXuHEcZ8zmE6xq9AVozutttwfEDGd2Mh3405kmHQbnVQ0WYpCiH7rCrL\n\t/0MtICO4KbU1tlyeAYhccAkl3Sb8LuvkWk5iB/aq0ArI+JAm8JvG6k1qt9B4k6g2+rtT\n\tbqHA==","v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org;\n\ts=google; \n\th=mime-version:sender:in-reply-to:references:from:date:message-id\n\t:subject:to:cc;\n\tbh=6GuHZAD3u/ZWBydwAg0wYacSXhNgtzg7eZOdWPStWcA=;\n\tb=l5ZKx6a5pkQpxS330K1JLMFCnpt+UXhxOal+ortO+DvhE4gor9IKdna7W99EHpx4N3\n\tw2134s41Meb4lq5bJ+sM2F3GSvn9sqAzjIfe0dbF+6Myl9DjPfRz/ZwIRmqYuzf5MX77\n\tzgNsCdvLgz46Vy0u8hsJizmM96n1oh9WNfysA="],"X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:mime-version:sender:in-reply-to:references:from\n\t:date:message-id:subject:to:cc;\n\tbh=6GuHZAD3u/ZWBydwAg0wYacSXhNgtzg7eZOdWPStWcA=;\n\tb=UL+Jxv+GtJ3iFk1wup6ErqlmRyoHdGBuXPJqe5WzrmoAN8284I+6hErexZmJ242I9v\n\t2ZfbEZdLhkavqQuhPiyMebOYuR7PiVRirEOlwPWC97BDkRhXeF+9U6LvufHuUuMUomRD\n\tPx61KdI6CjsetEwHPs6LCfywzc+o01ojfrN5np2BLZ3k8qF0IuNUQVzYdghMwKoKaqhB\n\t5rCC+PtB8WDjbexvg3efux4PcSXsW8hfyVjHvgxYUj60q2F3ybVpHd7yAVkKElie7m4Q\n\txjeF/OincYBYhTpZxyrmqyJ6KIn31QqqeJ8zcBiTaBAmWy2Q8GewvehBRBsUDc3Qrgtq\n\tnCZQ==","X-Gm-Message-State":"AHPjjUjWgR62Bw7CbkMrEZqGitC4bBbcJCSRIJIWWC0f/jqzNMY6lkvd\n\tMCecW2pUw8K1qGh7LeyOHQeEcUj9bke4s/2vCFLCDw==","X-Google-Smtp-Source":"AOwi7QBcdiq/zzg5lRdi7ll2NwCYzIZ8zytB3OwB9Xa4Bhb9OyODItSN3foG7QrLXgEygzxSU9I36sTOoPXS7AYdHF4=","X-Received":"by 10.237.37.182 with SMTP id x51mr6987961qtc.5.1504932851969;\n\tFri, 08 Sep 2017 21:54:11 -0700 (PDT)","MIME-Version":"1.0","In-Reply-To":"<1504555943-12893-7-git-send-email-pantelis.antoniou@konsulko.com>","References":"<1504555943-12893-1-git-send-email-pantelis.antoniou@konsulko.com>\n\t<1504555943-12893-7-git-send-email-pantelis.antoniou@konsulko.com>","From":"Simon Glass <sjg@chromium.org>","Date":"Fri, 8 Sep 2017 22:53:51 -0600","X-Google-Sender-Auth":"YknVE8f-H0br5It4tfM90fRMfRM","Message-ID":"<CAPnjgZ1wg_FHKhRJkhhp2ya-f8d3+gvQ8SuhchLh3RvTS8t=Yw@mail.gmail.com>","To":"Pantelis Antoniou <pantelis.antoniou@konsulko.com>","Cc":"Marek Vasut <marex@denx.de>, Tom Rini <trini@konsulko.com>,\n\tTero Kristo <t-kristo@ti.com>,\n\tU-Boot Mailing List <u-boot@lists.denx.de>, \n\tMaxime Ripard <maxime.ripard@free-electrons.com>,\n\tStefan Roese <sr@denx.de>, Alan Ott <alan@signal11.us>","Subject":"Re: [U-Boot] [PATCH v3 06/14] fit: Do not throw away extra\n\tconfiguration on fit_image_load()","X-BeenThere":"u-boot@lists.denx.de","X-Mailman-Version":"2.1.18","Precedence":"list","List-Id":"U-Boot discussion <u-boot.lists.denx.de>","List-Unsubscribe":"<https://lists.denx.de/options/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=unsubscribe>","List-Archive":"<http://lists.denx.de/pipermail/u-boot/>","List-Post":"<mailto:u-boot@lists.denx.de>","List-Help":"<mailto:u-boot-request@lists.denx.de?subject=help>","List-Subscribe":"<https://lists.denx.de/listinfo/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=subscribe>","Content-Type":"text/plain; charset=\"utf-8\"","Content-Transfer-Encoding":"base64","Errors-To":"u-boot-bounces@lists.denx.de","Sender":"\"U-Boot\" <u-boot-bounces@lists.denx.de>"}},{"id":1769384,"web_url":"http://patchwork.ozlabs.org/comment/1769384/","msgid":"<CAPnjgZ0PV2QwowT=DzR-Yz8oWeykeSVoVgQ4fvMaykzx=ViQjA@mail.gmail.com>","list_archive_url":null,"date":"2017-09-15T19:19:43","subject":"Re: [U-Boot] [PATCH v3 06/14] fit: Do not throw away extra\n\tconfiguration on fit_image_load()","submitter":{"id":12501,"url":"http://patchwork.ozlabs.org/api/people/12501/","name":"Simon Glass","email":"sjg@google.com"},"content":"Hi,\n\nOn 4 September 2017 at 14:12, Pantelis Antoniou\n<pantelis.antoniou@konsulko.com> wrote:\n> fit_image_load() threw away the extra configuration parts when\n> loading. We need them around for applying extra overlays for\n> building the boot fdt.\n>\n> Signed-off-by: Pantelis Antoniou <pantelis.antoniou@konsulko.com>\n> ---\n>  common/image-fit.c | 11 +++++++----\n>  1 file changed, 7 insertions(+), 4 deletions(-)\n\nAcked-by: Simon Glass <sjg@chromium.org>\n\n>\nApplied to u-boot-fdt thanks!","headers":{"Return-Path":"<u-boot-bounces@lists.denx.de>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@bilbo.ozlabs.org","Authentication-Results":["ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=lists.denx.de\n\t(client-ip=81.169.180.215; helo=lists.denx.de;\n\tenvelope-from=u-boot-bounces@lists.denx.de;\n\treceiver=<UNKNOWN>)","ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n\tunprotected) header.d=google.com header.i=@google.com\n\theader.b=\"ABMlIHhq\"; dkim-atps=neutral"],"Received":["from lists.denx.de (dione.denx.de [81.169.180.215])\n\tby ozlabs.org (Postfix) with ESMTP id 3xv58Q5Tx2z9s7g\n\tfor <incoming@patchwork.ozlabs.org>;\n\tSat, 16 Sep 2017 05:30:14 +1000 (AEST)","by lists.denx.de (Postfix, from userid 105)\n\tid 46CBCC2214F; Fri, 15 Sep 2017 19:23:14 +0000 (UTC)","from lists.denx.de (localhost [IPv6:::1])\n\tby lists.denx.de (Postfix) with ESMTP id 289C3C21F60;\n\tFri, 15 Sep 2017 19:21:59 +0000 (UTC)","by lists.denx.de (Postfix, from userid 105)\n\tid 95DE9C21EE0; Fri, 15 Sep 2017 19:19:57 +0000 (UTC)","from mail-qk0-f177.google.com (mail-qk0-f177.google.com\n\t[209.85.220.177])\n\tby lists.denx.de (Postfix) with ESMTPS id 66CE4C21D95\n\tfor <u-boot@lists.denx.de>; Fri, 15 Sep 2017 19:19:53 +0000 (UTC)","by mail-qk0-f177.google.com with SMTP id j5so2963810qkd.0\n\tfor <u-boot@lists.denx.de>; Fri, 15 Sep 2017 12:19:53 -0700 (PDT)","from 480794996271 named unknown by gmailapi.google.com with\n\tHTTPREST; Fri, 15 Sep 2017 21:19:44 +0200"],"X-Spam-Checker-Version":"SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de","X-Spam-Level":"","X-Spam-Status":"No, score=-0.0 required=5.0 tests=RCVD_IN_DNSWL_NONE,\n\tRCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, T_DKIM_INVALID,\n\tUNPARSEABLE_RELAY\n\tautolearn=unavailable autolearn_force=no version=3.4.0","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com;\n\ts=20161025; \n\th=mime-version:sender:from:in-reply-to:references:date:message-id\n\t:subject:to:cc;\n\tbh=t/QOmoPMUTpo1MEefwZ/gt9I4JBDh7KZOO1eY/me4v8=;\n\tb=ABMlIHhqnVKHGbjyB5UcBiWSXu4KEwhNSXZg0YV1MUsZ6GSPyH3GG4vLm+QOWOPiv8\n\tkVjscXyDeoLIGwxnmoqKmZKNzMpclhYXPTDMPCF5bWpuJYPPlmLGFR2ytqbXDZdi+0BG\n\tGDtXkOroQ4AuhnCgdI9sjVbbkCqeSIykpDoZ6Suvc1GKMafhTmzq0ZlGiSLkbAtRJfq5\n\ti5vY52OzlyZK7dcfK2grbj7VCRQePEtloVhkYd722BRyIOAM73vi0oZWxbA0fl0ZZIMi\n\twFYjduQIwa31an+p8my/0C68z0XRVXE0y7OsP8PTUPWBLTkzEMVJMQhRYfa8feQ2IduV\n\tNfrw==","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:mime-version:sender:from:in-reply-to:references\n\t:date:message-id:subject:to:cc;\n\tbh=t/QOmoPMUTpo1MEefwZ/gt9I4JBDh7KZOO1eY/me4v8=;\n\tb=bROMzz9jVR5agV4wTqLGwDRgRIajSVyr/gh5fbahLgJB0dsed7Om0lgynKFLAIZ19q\n\taXkEjgQwkq1atD4l09Xw2mNZj4EFNmIj1Uc+TVBZSWwXRuxpJfxK3VRk644P26BEnskw\n\t0qe/6/MtR9BPt4R1w4zqDVdqoQSTmUQ94e+nB4eB7wEStwko2GtrPlLFFDGWFUPlOhiv\n\tF4Yazwri/ROMYQD3CofmPEq2O7ZzePpkDf30yBY0ClfVlY4EB877CnOdQWHhK+8OinKg\n\tPscxzjxB9v+kicUEgeWt+vVWfB2phs5W2YU9z1FxRrKX80m4eXGx4rYbSHbne+In12yX\n\tjxZg==","X-Gm-Message-State":"AHPjjUhUeC5yvVDbrst7+Nx2oIgyiqH1QAooyDC+FXnmvWOJt40+uu+4\n\t/M7Zacqc3nWBveQCnk6ljUo6hHWaoyqHSb3/jUtNPw==","X-Google-Smtp-Source":"AOwi7QDSDjSY8/ENBxS+G2zNHwBRNh6Mt4jILzQlHdbriXlJrCybtwqFIlKFdOaTduQd4HGdhmOW3aSbDlhY8lPrd6I=","X-Received":"by 10.55.146.198 with SMTP id u189mr8895145qkd.317.1505503192191;\n\tFri, 15 Sep 2017 12:19:52 -0700 (PDT)","MIME-Version":"1.0","From":"sjg@google.com","In-Reply-To":"<CAPnjgZ1wg_FHKhRJkhhp2ya-f8d3+gvQ8SuhchLh3RvTS8t=Yw@mail.gmail.com>","References":"<CAPnjgZ1wg_FHKhRJkhhp2ya-f8d3+gvQ8SuhchLh3RvTS8t=Yw@mail.gmail.com>\n\t<1504555943-12893-1-git-send-email-pantelis.antoniou@konsulko.com>\n\t<1504555943-12893-7-git-send-email-pantelis.antoniou@konsulko.com>","Date":"Fri, 15 Sep 2017 21:19:43 +0200","X-Google-Sender-Auth":"V7SrElYmnIAD8wafkLwtM_ClBLM","Message-ID":"<CAPnjgZ0PV2QwowT=DzR-Yz8oWeykeSVoVgQ4fvMaykzx=ViQjA@mail.gmail.com>","To":"Simon Glass <sjg@chromium.org>","Cc":"Marek Vasut <marex@denx.de>, Tom Rini <trini@konsulko.com>,\n\tPantelis Antoniou <pantelis.antoniou@konsulko.com>,\n\tTero Kristo <t-kristo@ti.com>,\n\tU-Boot Mailing List <u-boot@lists.denx.de>, \n\tMaxime Ripard <maxime.ripard@free-electrons.com>,\n\tStefan Roese <sr@denx.de>, Alan Ott <alan@signal11.us>","Subject":"Re: [U-Boot] [PATCH v3 06/14] fit: Do not throw away extra\n\tconfiguration on fit_image_load()","X-BeenThere":"u-boot@lists.denx.de","X-Mailman-Version":"2.1.18","Precedence":"list","List-Id":"U-Boot discussion <u-boot.lists.denx.de>","List-Unsubscribe":"<https://lists.denx.de/options/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=unsubscribe>","List-Archive":"<http://lists.denx.de/pipermail/u-boot/>","List-Post":"<mailto:u-boot@lists.denx.de>","List-Help":"<mailto:u-boot-request@lists.denx.de?subject=help>","List-Subscribe":"<https://lists.denx.de/listinfo/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=subscribe>","Content-Type":"text/plain; charset=\"utf-8\"","Content-Transfer-Encoding":"base64","Errors-To":"u-boot-bounces@lists.denx.de","Sender":"\"U-Boot\" <u-boot-bounces@lists.denx.de>"}}]