lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAMuHMdU-dHU2cjfGHS1c1p-mEfHWb70Ltm697up=ej8-jET=fg@mail.gmail.com>
Date:   Wed, 26 Feb 2020 10:01:37 +0100
From:   Geert Uytterhoeven <geert@...ux-m68k.org>
To:     "Isaac J. Manjarres" <isaacm@...eaurora.org>
Cc:     Rob Herring <robh+dt@...nel.org>,
        Frank Rowand <frowand.list@...il.com>,
        Patrick Daly <pdaly@...eaurora.org>,
        "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" 
        <devicetree@...r.kernel.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        lmark@...eaurora.org, Pratik Patel <pratikp@...eaurora.org>,
        Android Kernel Team <kernel-team@...roid.com>
Subject: Re: [PATCH] of: of_reserved_mem: Increase limit on number of reserved regions

Hi Isaac,

On Mon, Feb 24, 2020 at 7:03 PM Isaac J. Manjarres
<isaacm@...eaurora.org> wrote:
> From: Patrick Daly <pdaly@...eaurora.org>
>
> Certain SoCs need to support a large amount of reserved memory
> regions. For example, Qualcomm's SM8150 SoC requires that 20
> regions of memory be reserved for a variety of reasons (e.g.
> loading a peripheral subsystem's firmware image into a
> particular space).
>
> When adding more reserved memory regions to cater to different
> usecases, the remaining number of reserved memory regions--12
> to be exact--becomes too small. Thus, double the existing
> limit of reserved memory regions.
>
> Signed-off-by: Patrick Daly <pdaly@...eaurora.org>
> Signed-off-by: Isaac J. Manjarres <isaacm@...eaurora.org>

Thanks for your patch!

> --- a/drivers/of/of_reserved_mem.c
> +++ b/drivers/of/of_reserved_mem.c
> @@ -22,7 +22,7 @@
>  #include <linux/slab.h>
>  #include <linux/memblock.h>
>
> -#define MAX_RESERVED_REGIONS   32
> +#define MAX_RESERVED_REGIONS   64
>  static struct reserved_mem reserved_mem[MAX_RESERVED_REGIONS];
>  static int reserved_mem_count;

This increases the size of reserved_mem[] by 896 (32-bit), 1280 (32-bit LPAE),
or 1792 (64-bit) bytes. While some systems don't need reserved memory
regions at all, and may be RAM-limited.

Perhaps this array can be replaced by some dynamically increasing
structure?

Gr{oetje,eeting}s,

                        Geert

-- 
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@...ux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ