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] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAMuHMdWo=6jR5WEWkdDWVCs0bUPFL3gyTVM_3HWh+SLCxQV5Gw@mail.gmail.com>
Date:   Wed, 25 Jan 2023 16:29:19 +0100
From:   Geert Uytterhoeven <geert@...ux-m68k.org>
To:     Ley Foon Tan <leyfoon.tan@...rfivetech.com>
Cc:     Palmer Dabbelt <palmer@...belt.com>,
        Paul Walmsley <paul.walmsley@...ive.com>,
        Albert Ou <aou@...s.berkeley.edu>,
        linux-riscv@...ts.infradead.org, linux-kernel@...r.kernel.org,
        Ley Foon Tan <lftan.linux@...il.com>,
        Conor Dooley <conor.dooley@...rochip.com>,
        Andrew Jones <ajones@...tanamicro.com>,
        Sudeep Holla <Sudeep.Holla@....com>,
        Pierre Gondois <pierre.gondois@....com>
Subject: Re: [PATCH v2] riscv: Move call to init_cpu_topology() to later
 initialization stage

Hi Ley,

On Thu, Jan 5, 2023 at 4:45 AM Ley Foon Tan
<leyfoon.tan@...rfivetech.com> wrote:
> If "capacity-dmips-mhz" is present in a CPU DT node,
> topology_parse_cpu_capacity() will fail to allocate memory.
> ARM64, with which this code path is shared, does not call
> topology_parse_cpu_capacity() until later in boot where memory allocation
> is available.
>
> Move init_cpu_topology(), which calls topology_parse_cpu_capacity(), to a
> later initialization stage, to match ARM64.
>
> Tested on Qemu platform.
>
> Fixes: 03f11f03dbfe ("RISC-V: Parse cpu topology during boot.")
> Reviewed-by: Conor Dooley <conor.dooley@...rochip.com>
> Reviewed-by: Andrew Jones <ajones@...tanamicro.com>
> Signed-off-by: Ley Foon Tan <leyfoon.tan@...rfivetech.com>
>
> ---
> Changes:
> v2:
> - Update commit description with suggestion from Conor.
> - Added Reviewed-by.
> - Added Fixes.

This also fixes the error message

    Early cacheinfo failed, ret = -12

seen during early boot on all my RV64 platforms.

Fixes: 5944ce092b97caed ("arch_topology: Build cacheinfo from primary CPU")
Tested-by: Geert Uytterhoeven <geert+renesas@...der.be>

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