From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9E2CD2D6409 for ; Thu, 5 Feb 2026 09:52:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=90.155.92.199 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770285169; cv=none; b=nByGokzLKmd455fsaMlfUwcZdQbf8BIG1grDYUu7YPoMLAGZT9ymsYPrlaSL9cIKgdFp4XZgzMvQGmpGijZs2yJh4/ZNMUibAGQ5iiYnR9qBblxiq5xTMR8r5DQK4nix3WzhZPzxsmguvVRAsuwO9rbzU4gvi73A3t7uURJaiKo= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770285169; c=relaxed/simple; bh=U+BVopovSC8b2lqEXdP3iUFPBUkvAOghnYynyAeDwlI=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=baD1kFHdD87cjEkPLDdE6r8fMHuZnPQDu2dRFqBwl9ULx6+hco3Rhg0I14XG44BvHhtx5ivIfImSl9zAzONs/9iAGoGtC9P8gPOYTD2ZqIeXVMx0PBMUgTFYBQkmtoth4gsaSzf+F1BXCRMNJFmAigUMkyNGjIl6xypYgxmhZW0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=infradead.org; spf=none smtp.mailfrom=infradead.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b=GvEZ7JZ5; arc=none smtp.client-ip=90.155.92.199 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=infradead.org Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=infradead.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b="GvEZ7JZ5" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; 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=m9Cw8XmmagX6zgx5vn8oiDpzkcQ/bp1vjOgUhf1O1Ws=; b=GvEZ7JZ5jEmS4RTsL289UFXbov hX45vRG3+QjJcDm0xxV9xXG8fIHsNbnPNxH4Wq6BsYAEXZGHPWa+fXkMjVa7g4JPr2fjDwSp6B4Pb bJNINSVASMnJtaFDcQBUVd3g5qRCD3LdoAWCiFg+6rwJ/Cvy41DWA+v0KVjOwVa/TnoewklvrBS14 9GP0TwJffINNJvGmAtBZRYxd2Hm/Im+iYFNr6xs2+Vijpg3q2nRDvDgjQoSAC+AV2TOSyCMc3Vywq R9U2jXSr2GwOIPFfTC7xAgss6CCh7gq3ViBL3m1FcLBZD0onv5qc4ySfCH8nDa3QZlCBkdsg4LXrY aA9S1+nA==; Received: from 2001-1c00-8d85-5700-266e-96ff-fe07-7dcc.cable.dynamic.v6.ziggo.nl ([2001:1c00:8d85:5700:266e:96ff:fe07:7dcc] helo=noisy.programming.kicks-ass.net) by desiato.infradead.org with esmtpsa (Exim 4.98.2 #2 (Red Hat Linux)) id 1vnw2O-00000001vNF-45lb; Thu, 05 Feb 2026 09:52:37 +0000 Received: by noisy.programming.kicks-ass.net (Postfix, from userid 1000) id 6D7D3300BD2; Thu, 05 Feb 2026 10:52:36 +0100 (CET) Date: Thu, 5 Feb 2026 10:52:36 +0100 From: Peter Zijlstra To: Chuyi Zhou Cc: tglx@linutronix.de, mingo@redhat.com, luto@kernel.org, paulmck@kernel.org, muchun.song@linux.dev, bp@alien8.de, dave.hansen@linux.intel.com, linux-kernel@vger.kernel.org Subject: Re: [PATCH 05/11] smp: Enable preemption early in smp_call_function_many_cond Message-ID: <20260205095236.GI232055@noisy.programming.kicks-ass.net> References: <20260203112401.3889029-1-zhouchuyi@bytedance.com> <20260203112401.3889029-6-zhouchuyi@bytedance.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20260203112401.3889029-6-zhouchuyi@bytedance.com> On Tue, Feb 03, 2026 at 07:23:55PM +0800, Chuyi Zhou wrote: > + /* > + * Prevent the current CPU from going offline. > + * Being migrated to another CPU and calling csd_lock_wait() may cause > + * UAF due to smpcfd_dead_cpu() during the current CPU offline process. > + */ > + migrate_disable(); This is horrible crap. migrate_disable() is *NOT* supposed to be used to serialize cpu hotplug.