From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5E48DE71060 for ; Thu, 21 Sep 2023 12:22:14 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id B92E56B0203; Thu, 21 Sep 2023 08:22:13 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id B434F6B0204; Thu, 21 Sep 2023 08:22:13 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id A0B046B0205; Thu, 21 Sep 2023 08:22:13 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0013.hostedemail.com [216.40.44.13]) by kanga.kvack.org (Postfix) with ESMTP id 916296B0203 for ; Thu, 21 Sep 2023 08:22:13 -0400 (EDT) Received: from smtpin11.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id 678C1808C0 for ; Thu, 21 Sep 2023 12:22:13 +0000 (UTC) X-FDA: 81260516946.11.5D1DDFB Received: from out1-smtp.messagingengine.com (out1-smtp.messagingengine.com [66.111.4.25]) by imf04.hostedemail.com (Postfix) with ESMTP id 3583340013 for ; Thu, 21 Sep 2023 12:22:11 +0000 (UTC) Authentication-Results: imf04.hostedemail.com; dkim=pass header.d=arndb.de header.s=fm1 header.b=L6lYR2Tk; dkim=pass header.d=messagingengine.com header.s=fm2 header.b=RVjMo7y3; dmarc=none; spf=pass (imf04.hostedemail.com: domain of arnd@arndb.de designates 66.111.4.25 as permitted sender) smtp.mailfrom=arnd@arndb.de ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1695298931; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=bICU49f3R5e6tOFgPrJQcVi5tnUnFNXIHPGMh+L+TBg=; b=BI8fQ6z01ihqdo+ssi5nPta6+X0WdLqVYYTC/cVgGYPd9CtA+9Xte19E9K5q42VJ5RRM9Z GJ9CVg+1UknIFodJuxnkMvzy1WvKQkn4i00fbBq49S7AgzT6FN1dR8uvKEHJTY3OBI34Tj N1Ne3N3aOKQrxaZdBMo4L6omSSBBkGY= ARC-Authentication-Results: i=1; imf04.hostedemail.com; dkim=pass header.d=arndb.de header.s=fm1 header.b=L6lYR2Tk; dkim=pass header.d=messagingengine.com header.s=fm2 header.b=RVjMo7y3; dmarc=none; spf=pass (imf04.hostedemail.com: domain of arnd@arndb.de designates 66.111.4.25 as permitted sender) smtp.mailfrom=arnd@arndb.de ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1695298931; a=rsa-sha256; cv=none; b=jog+LkbtExIX+eeE8VBdWbV5IyVCM+F9eaI4O4yCyIoqkmc/y+/jfsbSIdvku+jtAVEZAs 3wgajVpYvyOo3ILRtunn2MBOAG/C17At/fiW765FpTqUf15Ya+ob0Fe2b0M6m5uDeDiv6B AUVRy8sLbKoHqghY1LQbEjHdhNU1rm0= Received: from compute6.internal (compute6.nyi.internal [10.202.2.47]) by mailout.nyi.internal (Postfix) with ESMTP id 6827E5C018F; Thu, 21 Sep 2023 08:22:10 -0400 (EDT) Received: from imap51 ([10.202.2.101]) by compute6.internal (MEProxy); Thu, 21 Sep 2023 08:22:10 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=arndb.de; h=cc :cc:content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:sender :subject:subject:to:to; s=fm1; t=1695298930; x=1695385330; bh=bI CU49f3R5e6tOFgPrJQcVi5tnUnFNXIHPGMh+L+TBg=; b=L6lYR2Tkg6YW09ZEP7 OC3REXNbmFESOwzVxVw2xX2d4Mi1KLdjyBDeCIwOzEDPQelkPCFvhPiTDReuvjRa 0K1hEEajfz0y5nKBcAX7j8/UhzL1ElgAUMXKoBLoTo1KDUxLJWpLAygQ2ew2IDsj yEf5ZXz91216EYizxRSDX6hehjnrwtBmiUcDsF3KmYhM2APrLSnFrmpF/TEJpq25 j3Ps22K2WbFlR6SjGyseavSRtb9b6d8mN8o6jtErbySiShiA4GoNRtuQAnjzlHCi xMcSOr8TwAzbkGJWZcVMfLHINdShZIY7AaXYAdPb5nJpyTv+4zntqwaEt9FTkovz J26g== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:sender:subject :subject:to:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; t=1695298930; x=1695385330; bh=bICU49f3R5e6t OFgPrJQcVi5tnUnFNXIHPGMh+L+TBg=; b=RVjMo7y3by+104e0tpt3AaC3rxAB/ BkN16pzGhr3PFOnA7+MzV5/LwVyFOToOKDEebEeB37my8a5dUM8dxWXyv71kgWpH g8G4rKJYqZNrQuEP2VH5DcjJbhzkWhqCuLtvX7/i62XytcJ1QDvDI8XBMSTLJEBD Zjs7BSkgAJHit6Pq6JzybieBHCckG9lZuYEPH8f3T/JN9tCgDrFEQ79omye4NBL6 1NxzbRH7G4K6UmvQHcjFoxIuEmJjkWSv3iVjrtsoa8UKTZw061MvDMOgFXUhnn/r xH28CZr8YCId7DqtXVl4D3XfokExmYeY/SIZShdXISc78kCqeNrRTcl8g== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedviedrudekiedghedtucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepofgfggfkjghffffhvfevufgtsehttdertderredtnecuhfhrohhmpedftehr nhguuceuvghrghhmrghnnhdfuceorghrnhgusegrrhhnuggsrdguvgeqnecuggftrfgrth htvghrnhepffehueegteeihfegtefhjefgtdeugfegjeelheejueethfefgeeghfektdek teffnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomheprg hrnhgusegrrhhnuggsrdguvg X-ME-Proxy: Feedback-ID: i56a14606:Fastmail Received: by mailuser.nyi.internal (Postfix, from userid 501) id E4B47B60089; Thu, 21 Sep 2023 08:22:07 -0400 (EDT) X-Mailer: MessagingEngine.com Webmail Interface User-Agent: Cyrus-JMAP/3.9.0-alpha0-761-gece9e40c48-fm-20230913.001-gece9e40c MIME-Version: 1.0 Message-Id: <020d4d23-ee7e-49aa-9ed5-1bde21fd0a5d@app.fastmail.com> In-Reply-To: <20230919141627.GB39281@noisy.programming.kicks-ass.net> References: <20230911150410.GC9098@noisy.programming.kicks-ass.net> <87h6o01w1a.fsf@oracle.com> <20230912082606.GB35261@noisy.programming.kicks-ass.net> <87cyyfxd4k.ffs@tglx> <87led2wdj0.ffs@tglx> <0e69f7df80dc5878071deb0d80938138d19de1d1.camel@physik.fu-berlin.de> <20230919134218.GA39281@noisy.programming.kicks-ass.net> <20230919141627.GB39281@noisy.programming.kicks-ass.net> Date: Thu, 21 Sep 2023 08:20:38 -0400 From: "Arnd Bergmann" To: "Peter Zijlstra" , "John Paul Adrian Glaubitz" Cc: "Matthew Wilcox" , "Thomas Gleixner" , "Linus Torvalds" , "Ankur Arora" , linux-kernel@vger.kernel.org, linux-mm@kvack.org, x86@kernel.org, "Andrew Morton" , "Andy Lutomirski" , "Borislav Petkov" , "Dave Hansen" , "H. Peter Anvin" , "Ingo Molnar" , juri.lelli@redhat.com, "Vincent Guittot" , "Mel Gorman" , "Steven Rostedt" , jon.grimm@amd.com, bharata@amd.com, raghavendra.kt@amd.com, "Boris Ostrovsky" , "Konrad Rzeszutek Wilk" , "Juergen Gross" , andrew.cooper3@citrix.com, "Geert Uytterhoeven" , linux-m68k@lists.linux-m68k.org, "Richard Weinberger" , "Anton Ivanov" , "Johannes Berg" , linux-um@lists.infradead.org, "Brian Cain" , linux-hexagon@vger.kernel.org, "Richard Henderson" , "Ivan Kokshaysky" , "Matt Turner" , linux-alpha@vger.kernel.org Subject: Re: Arches that don't support PREEMPT Content-Type: text/plain X-Rspamd-Queue-Id: 3583340013 X-Rspam-User: X-Rspamd-Server: rspam04 X-Stat-Signature: 9m11hrxkndbfbwybqbddf4cd3krxzh44 X-HE-Tag: 1695298931-195889 X-HE-Meta: U2FsdGVkX1+bDmaPi5R/PJSLsMZs3C2E7Fyq6eEW0noBVHUub3tECGSHIkVFBH5y0ZuH7Qc4VeEYbMw9S6oMQ3f4w5zLOIv+f7adnjtSMO9YZwVV7vdhYdR5zEByvlz/5h/vrPfOM+jyl5cMQRkPeXKW5uj1bOtBmktmrrCa2ovxu6/ZuXCEQW12iS7JZVO/Tssu0haFaYEFHOWKgsddkDTUvqgoUxWJb3To2EsZpBTm+xshxTmYBGmvCMEpvCjEv5jnXXdOzQYhnZ8J4WTchPsgd5Qv4m4xi7siGguooMFzStXzox0e3LzXqR/gMPwqLWVuQDsE6tGp1TPeN1e00gqKMOz+kNSGWewPoCfKQF0bcY7GAh/owi3W/Ljh972MJBANEKg0PZ6jDM0wjaBCDLzxj9avuGMq4V/hNxIOwe2WqySprPmlFwematDXPYDe0JY3A5ibIU1N4E3ecY9ARqxKl68hFrDtXSo1M0IU5qmG2Wsm4M6w9Gb4Ni+4eALyC4+XitXfFirQQzWvPgxoKSYFEtGW61qZnbEfLpomWRlgp8rJHUeBauuaDxAGqVIWjETZB8i59KzD3LLh0RiCOTG9Lqqx7PxLTgCZduYSLX979jAntJH+TDNu0bUEryyBv6h2z6BCxVS4HkcPSpDH7hvaeKxAVA0KaPQHftRfFwPyOX26LUlR2DX+Jh1TM3Ddn5jozFf1UV4IzOsedtrNFsz55mPLxuGOQonVAtayPgUsbNqfhZkg65N4OVvyO0Mggx/WmasvsHBzaMCkkEZdCqWhqVSI+amCwxVw3tPlm6ehqkYzDl4zJ3T9It/5Rh+xGTXpMHOB7aHxosaDJc0o0laQgU+h2roxX07zfZBrWbhlYSxapRVaQpuJbV9UFmDVa9ms3qvj91LAFSqIwMB+VERCvEd+P3DCaeoSDbAdc8WH+0V0PH2CrKu5dZe+37yi0US+uotxHRcndJZplwu wwAwEQAo 9w6YnbFctp7Ufr7UoiR4LQh9VA/9cFE6t8y9l+LUPWiEMpqs+qaW5Fh+g1IG9dix8XdcGbv2T/QVXgTbh7Z3DVCZfQM9SNczH7RPTjDoPRyS8i3U= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Tue, Sep 19, 2023, at 10:16, Peter Zijlstra wrote: > On Tue, Sep 19, 2023 at 03:48:09PM +0200, John Paul Adrian Glaubitz wrote: >> On Tue, 2023-09-19 at 15:42 +0200, Peter Zijlstra wrote: >> > > The agreement to kill off ia64 wasn't an invitation to kill off other stuff >> > > that people are still working on! Can we please not do this? >> > >> > If you're working on one of them, then surely it's a simple matter of >> > working on adding CONFIG_PREEMPT support :-) >> >> As Geert poined out, I'm not seeing anything particular problematic with the >> architectures lacking CONFIG_PREEMPT at the moment. This seems to be more >> something about organizing KConfig files. > > The plan in the parent thread is to remove PREEMPT_NONE and > PREEMPT_VOLUNTARY and only keep PREEMPT_FULL. ... > > PREEMPT isn't something new. Also, I don't think the arch part for > actually supporting it is particularly hard, mostly it is sticking the > preempt_schedule_irq() call in return from interrupt code path. > > If you convert the arch to generic-entry (a much larger undertaking) > then you get this for free. I checked the default configurations for both in-kernel targets and general-purpose distros and was surprised to learn that very few actually turn on full preemption by default: - All distros I looked at (rhel, debian, opensuse) use PREEMPT_VOLUNTARY by default, though they usually also set PREEMPT_DYNAMIC to let users override it at boot time. - The majority (220) of all defconfig files in the kernel don't select any preemption options, and just get PREEMPT_NONE automatically. This includes the generic configs for armv7, s390 and mips. - A small number (24) set PREEMPT_VOLUNTARY, but this notably includes x86 and ppc64. x86 is the only one of those that sets PREEMPT_DYNAMIC - CONFIG_PREEMPT=y (full preemption) is used on 89 defconfigs, including arm64 and a lot of the older arm32, arc and mips platforms. If we want to have a chance of removing both PREEMPT_NONE and PREEMPT_VOLUNTARY, I think we should start with changing the defaults first, so defconfigs that don't specify anything else get PREEMPT=y, and distros that use PREEMPT_VOLUNTARY use it use it in the absence of a command line argument. If that doesn't cause too many regressions, the next step might be to hide the choice under CONFIG_EXPERT until all m68k and alpha no longer require PREEMPT_NONE. Arnd