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: <20210810183914.2wd7hehdz7y4crla@linutronix.de>
Date:   Tue, 10 Aug 2021 20:39:14 +0200
From:   Sebastian Andrzej Siewior <bigeasy@...utronix.de>
To:     Thomas Gleixner <tglx@...utronix.de>
Cc:     Valentin Schneider <valentin.schneider@....com>,
        linux-kernel@...r.kernel.org, linux-rt-users@...r.kernel.org,
        Will Deacon <will@...nel.org>,
        Mark Rutland <mark.rutland@....com>,
        Marc Zyngier <maz@...nel.org>,
        Mel Gorman <mgorman@...hsingularity.net>
Subject: Re: [SPLAT 1/3] arm_pmu: Sleeping spinlocks down
 armpmu_alloc_atomic()

On 2021-08-10 19:16:19 [+0200], Thomas Gleixner wrote:
> On Tue, Aug 10 2021 at 15:54, Sebastian Andrzej Siewior wrote:
> > On 2021-08-10 14:41:25 [+0100], Valentin Schneider wrote:
> >> [    4.172817] BUG: sleeping function called from invalid context at kernel/locking/spinlock_rt.c:35
> >
> > Would it work to allocate the memory upfront and invoke the HP callback
> > via smp_function_call()?
> 
> Huch? If the memory is allocated during the prepare stage then the
> actual hotplug callback can just use it. So what's the SMP function call
> for?

You allocate the memory per-node (based on cpuid id) and you figure that
out on the target CPU. That is the smp-function call for unless there
another way to gather that information.
That is done in
 arm_pmu_acpi_find_alloc_pmu() -> read_cpuid_id()

> Thanks,
> 
>         tglx

Sebastian

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ