Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp400192pxb; Wed, 20 Jan 2021 09:36:03 -0800 (PST) X-Google-Smtp-Source: ABdhPJxyjxBhxizgPEIcuE8V6zk/uNdPdiLbaPTj5T0Trf/fRCF+Ojna55zmDhG3Xh2oAKJAwdrc X-Received: by 2002:aa7:d39a:: with SMTP id x26mr7961812edq.51.1611164163583; Wed, 20 Jan 2021 09:36:03 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611164163; cv=none; d=google.com; s=arc-20160816; b=cpmD7NJlSTenO+UzwLwVK3MZr7b6sRdoU8A8952VYvTz7M+dpPrCVVTlxV5fEjqXWI tcjqw6NXV8K+upB5wZvgXeMRGPR2uCiUdMWw5J9EXIlXml/eAUytWD6NFHbIqvdtyPTL JVfKhVfcEul0vujKUtZjHMGNze4J1WQ/3yN1niifzeCGFa/VaE9BDZlWshzLgHh1LxiI h+8odDMgcw8oiWfUSqvHtneeR8GIHrHFj/KR9wSKstjBQi9YKxTSHaY6kpxQf5KzO7nd 6I4jfheDnAVLo14uz9krwzDJbNN3xN4XrSNXBTDIxi6sVVbO5LBkNs6McB8UlMD2fQPR R7DA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=yzAxe3sMWnWr7VcTH/YVHmDCsx4+TBkz57gTfUzD9C4=; b=U5lAj7zUBbwCXBHjjOwBBc96CW/uDvNRifARfb1t+q6U50o+/rH2ZtYj/JyrzHtWBE O7/iAO1o3nfz1cYbvBASQ0X+VftHXyB+zuMrflXhvcKjdpADEba4/UT4EyML2vecoTH3 QAwuCTdMjgGf64tfteL9/DKnfI15bufW1cShu5i4eYrlCBaSu0lfCaS+vpmUslD2DA8s EkJMFbusX8LKANunbZapW2K/QA5bpfOO/nOXJuHw83frTfRV8RT8XGx4T4hnO/wDhwKz T7eiI3f+vZwyJk8uVm2bYdp8z4d2PuDR5zwtQ/yJTizxWYTB1FDcCwipL0I+3QXBiXU2 XrOg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=merlin.20170209 header.b="fqxgOl/2"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h24si948125ejt.638.2021.01.20.09.35.38; Wed, 20 Jan 2021 09:36:03 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=merlin.20170209 header.b="fqxgOl/2"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388582AbhATRcp (ORCPT + 99 others); Wed, 20 Jan 2021 12:32:45 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35780 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388828AbhATRbd (ORCPT ); Wed, 20 Jan 2021 12:31:33 -0500 Received: from merlin.infradead.org (merlin.infradead.org [IPv6:2001:8b0:10b:1231::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7DD05C0613ED for ; Wed, 20 Jan 2021 09:30:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=yzAxe3sMWnWr7VcTH/YVHmDCsx4+TBkz57gTfUzD9C4=; b=fqxgOl/2+SzdiXQrGVd3p/Fd/7 ZlLj3Kx/Twup7EfzlA3kZ2e5urbUKxQ2JFF+Mn0VJe58RnTpRoK23YfWAjKa9T+XbaXY6OkpHYtDc dr/w55umROq9rYYXezotgE/k+s0JEuMwOevXZMJqBSDYUNMeG4OAjhKgqTROubYAHSvlFRdUL27uY w/zjv2c6pTOqtjP3vLOuG5g+MK+jsdjL2rAC+h9J9e3cFFb+siGKN8aCH4G/fg6MqWVo2YHOZRUr3 W8KHPGxRAkpnHoTxmW8Elf11AzVK2w51e86LRcuW8NIeITQe+KxRscmXcqZ2y4STKBL9Z6ZiK1odl Q1F3Gx3w==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=noisy.programming.kicks-ass.net) by merlin.infradead.org with esmtpsa (Exim 4.92.3 #3 (Red Hat Linux)) id 1l2HJh-0001mF-02; Wed, 20 Jan 2021 17:30:49 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id B2BBB303271; Wed, 20 Jan 2021 18:30:45 +0100 (CET) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id 9DA672CEAD197; Wed, 20 Jan 2021 18:30:45 +0100 (CET) Date: Wed, 20 Jan 2021 18:30:45 +0100 From: Peter Zijlstra To: Vincent Donnefort Cc: tglx@linutronix.de, linux-kernel@vger.kernel.org, valentin.schneider@arm.com Subject: Re: [PATCH 2/4] cpu/hotplug: CPUHP_BRINGUP_CPU exception in fail injection Message-ID: References: <1610385047-92151-1-git-send-email-vincent.donnefort@arm.com> <1610385047-92151-3-git-send-email-vincent.donnefort@arm.com> <20210120151723.GA284273@e120877-lin.cambridge.arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210120151723.GA284273@e120877-lin.cambridge.arm.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jan 20, 2021 at 03:17:24PM +0000, Vincent Donnefort wrote: > On Wed, Jan 20, 2021 at 01:58:35PM +0100, Peter Zijlstra wrote: > > On Mon, Jan 11, 2021 at 05:10:45PM +0000, vincent.donnefort@arm.com wrote: > > > + if (cpuhp_is_atomic_state(fail) || > > > + (fail == CPUHP_BRINGUP_CPU && st->state > CPUHP_BRINGUP_CPU)) > > > return -EINVAL; > > > > Should we instead disallow failing any state that has .cant_stop ? > > We would reduce the scope of what can be tested: bringup_cpu() and > takedown_cpu() are both marked as "cant_stop". Still, those callbacks are > allowed to fail. Fair enough. I suppose we can add an additional cant_fail field, but I'm not sure that's worth the effort over this.