Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp518010pxu; Wed, 7 Oct 2020 08:55:07 -0700 (PDT) X-Google-Smtp-Source: ABdhPJytnsK4MSX5clmArLGUoD7DoTsSPiGpJOtvlNfKQ7Z8SyH07HWv6DeQVk+sqF1ocWKMPwqA X-Received: by 2002:a17:906:118f:: with SMTP id n15mr4189964eja.394.1602086106859; Wed, 07 Oct 2020 08:55:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1602086106; cv=none; d=google.com; s=arc-20160816; b=O+zIDVWZtk/BruTWv6GUqVrCZ7D3twF8DlloVgxzqbJOCgkZ7phC20bNa+YVba2Y9b xUYNf9RHjymnDoq4B8n2eJAjjz4yXEIRYHR+MNS8tltDADM+F8g91pswFUB5/zGF8ii9 qVOYLY9Ov1mAGxh2wKP7dAFZJdeKweRRuLL75jYWIWRz8NN7JK0DUq1uWUCvVBRWap8Q Hjd0p3JnplOuPrT1cpfN0W76h0sTCIUiaEzrxZQB8goDOwPX6y2BFFE93uwSQaJcT0Te D8pTvJ16Cc+Cd5Qt9gi8wB5kXGoQj8uIBkrQyL/W6vAJSAG9Ct+Zk9GVjjw6rQ2BluII 7aKw== 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=JKVoRPDcYIvc3oXdpWLKcaOI1PJO0HyqrM9NWpXvJM0=; b=EVsIr69j17a+jLHDRl1AcTNxMnU8qy2Aw8MgYWMDQYtSW2qBSABLt+iWIGeayLlU1l lAjqFHKKM/+gt5Q5UcDJr9SKyqCX1khIA+Af5gHzb/bbh+75PjaZWvoe/qQ30VicMzxI jzcq86jVSkklyVD696zirvk1Ta2VZgfdygX6w+vsZUNQ75L2hjuIP5xCiEOXEV2y8YrC hwyXQWb4/Kq9fklQr1zXWASVHr2KDfSJAbwGAOImEduR+BlxBksfWkWN56Dm0gHoV/iC 6tJriTMHWqKP/ex5PXAFrlcDU/75f8rJ4fsWukByJgltgjX12A+xhqmWJj+rhd2Rgsc4 GrTQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b="YN/6vhts"; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d1si1706451ejj.113.2020.10.07.08.54.43; Wed, 07 Oct 2020 08:55:06 -0700 (PDT) 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=@suse.com header.s=susede1 header.b="YN/6vhts"; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728267AbgJGMf4 (ORCPT + 99 others); Wed, 7 Oct 2020 08:35:56 -0400 Received: from mx2.suse.de ([195.135.220.15]:54798 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727253AbgJGMfz (ORCPT ); Wed, 7 Oct 2020 08:35:55 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1602074154; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=JKVoRPDcYIvc3oXdpWLKcaOI1PJO0HyqrM9NWpXvJM0=; b=YN/6vhtsbJjQzFcsu+BnmsyGKsVgX51vsszKSEjY6X07PODAfCG1AFGr6hdVkEDqlWa7Qm oOxbk4OQovo+OIpBEU8NfNy1cYFHePXzzXy1MZqzfRmQ/hmp+OCkpCSjMUmqEYDUDpBqji 3VMgEXKIpyx2wEj4x3lOl45BRv8n2xA= Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id 14BFDAB5C; Wed, 7 Oct 2020 12:35:54 +0000 (UTC) Date: Wed, 7 Oct 2020 14:35:53 +0200 From: Michal Hocko To: Peter Zijlstra Cc: Thomas Gleixner , Frederic Weisbecker , LKML , Mel Gorman , Ingo Molnar Subject: Re: [RFC PATCH] kernel: allow to configure PREEMPT_NONE, PREEMPT_VOLUNTARY on kernel command line Message-ID: <20201007123553.GK29020@dhcp22.suse.cz> References: <20201007120401.11200-1-mhocko@kernel.org> <20201007122144.GF2628@hirez.programming.kicks-ass.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20201007122144.GF2628@hirez.programming.kicks-ass.net> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed 07-10-20 14:21:44, Peter Zijlstra wrote: > On Wed, Oct 07, 2020 at 02:04:01PM +0200, Michal Hocko wrote: > > I wanted to make sure that the idea is sound for maintainers first. The > > next step would be extending the command line to support full preemption > > as well but there is much more work in that area. Frederic has promissed > > to look into that. > > The sanest way there is to static_call() __preempt_schedule() I think. Yes, I have checked the code and identified few other places like irqentry_exit_cond_resched. We also need unconditional CONFIG_PREEMPT_COUNT IIUC and there are quite some places guarded by CONFIG_PREEMPTION that would need to be examined. Some of them are likely pretending to be more clever than they really are/should be - e.g. mm/slub.c. So there is likely a lot of leg work. -- Michal Hocko SUSE Labs