[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <160783689435.1580929.1038454293190061446@swboyd.mtv.corp.google.com>
Date: Sat, 12 Dec 2020 21:21:34 -0800
From: Stephen Boyd <sboyd@...nel.org>
To: Ard Biesheuvel <ardb@...nel.org>,
Dmitry Osipenko <digetx@...il.com>,
Geert Uytterhoeven <geert+renesas@...der.be>,
Linus Walleij <linus.walleij@...aro.org>,
Marek Szyprowski <m.szyprowski@...sung.com>,
Nicolas Pitre <nico@...xnic.net>,
Russell King <linux@...linux.org.uk>
Cc: Arnd Bergmann <arnd@...db.de>, Eric Miao <eric.miao@...dia.com>,
Uwe Kleine-König
<u.kleine-koenig@...gutronix.de>,
Lukasz Stelmach <l.stelmach@...sung.com>,
Chris Brandt <chris.brandt@...esas.com>,
linux-arm-kernel@...ts.infradead.org,
linux-renesas-soc@...r.kernel.org, linux-kernel@...r.kernel.org,
Geert Uytterhoeven <geert+renesas@...der.be>
Subject: Re: [PATCH v11] ARM: uncompress: Validate start of physical memory against passed DTB
Quoting Geert Uytterhoeven (2020-12-10 01:32:01)
> diff --git a/arch/arm/boot/compressed/fdt_check_mem_start.c b/arch/arm/boot/compressed/fdt_check_mem_start.c
> new file mode 100644
> index 0000000000000000..e58c3a79c8a31ec4
> --- /dev/null
> +++ b/arch/arm/boot/compressed/fdt_check_mem_start.c
> @@ -0,0 +1,131 @@
[...]
> +
> +static uint64_t get_val(const fdt32_t *cells, uint32_t ncells)
> +{
> + uint64_t r = 0;
This assignment is unnecessary?
> +
> + r = fdt32_ld(cells);
> + if (ncells > 1)
> + r = (r << 32) | fdt32_ld(cells + 1);
> +
> + return r;
Powered by blists - more mailing lists