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: <20210930140118.z352cj3uzjscctcb@linutronix.de>
Date:   Thu, 30 Sep 2021 16:01:18 +0200
From:   Sebastian Andrzej Siewior <bigeasy@...utronix.de>
To:     "Longpeng(Mike)" <longpeng2@...wei.com>
Cc:     peterz@...radead.org, valentin.schneider@....com, mingo@...nel.org,
        tglx@...utronix.de, linux-kernel@...r.kernel.org,
        arei.gonglei@...wei.com
Subject: Re: [RFC] cpu/hotplug: allow the cpu in UP_PREPARE state to bringup
 again

On 2021-09-01 13:11:43 [+0800], Longpeng(Mike) wrote:
> The cpu's cpu_hotplug_state will be set to CPU_UP_PREPARE before
> the cpu is waken up, but it won't be reset when the failure occurs.
> Then the user cannot to make the cpu online anymore, because the
> CPU_UP_PREPARE state makes cpu_check_up_prepare() unhappy.
> 
> We should allow the user to try again in this case.

Can you please describe where it failed / what did you reach that state?

> Signed-off-by: Longpeng(Mike) <longpeng2@...wei.com>
> ---
>  kernel/smpboot.c | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/kernel/smpboot.c b/kernel/smpboot.c
> index f6bc0bc..d18f8ff 100644
> --- a/kernel/smpboot.c
> +++ b/kernel/smpboot.c
> @@ -392,6 +392,13 @@ int cpu_check_up_prepare(int cpu)
>  		 */
>  		return -EAGAIN;
>  
> +	case CPU_UP_PREPARE:
> +		/*
> +		 * The CPU failed to bringup last time, allow the user
> +		 * continue to try to start it up.
> +		 */
> +		return 0;
> +
>  	default:
>  
>  		/* Should not happen.  Famous last words. */
> -- 
> 1.8.3.1

Sebastian

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ