Received: by 2002:a05:6a10:c604:0:0:0:0 with SMTP id y4csp244541pxt; Wed, 4 Aug 2021 10:01:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwOK/Fsoa480ZT85OONMJp++rH2nUQvf2Peg7BKqKydJuf5hHtTwgC5dzz6Au8SBIihXfU6 X-Received: by 2002:a05:6402:40f:: with SMTP id q15mr918637edv.86.1628096518648; Wed, 04 Aug 2021 10:01:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628096518; cv=none; d=google.com; s=arc-20160816; b=ffDls7JxgDx8y30adeFr/sULSu9zbAWGB9njTWB2Lf0KrVFugfh37UuaG1Q4WVOeFz tWZJxFhOoQPsI4EDAoBFrM14R+LU0HLu4BLkOtZlfxGPE8zVue6U5llG7DLhVbkYtGIP qHmghRGCKEdnm1KvIosPjoK03fFv5lhYtOoCj9RssVfUB0YrihFG6gBbJm47my9srnjs 0DUiGovJ09mgOsLy/fgC8H2HF9pbSltZgcLza5PiTzbpbnzK6FZQrp8wY1GRXQP5DsGH DgO3WaIumIbAh+e2FHVg/yOKU5pw1nl5eOnHsfI60csyWjiEErwIob3Z5U0zJx/O2LY/ f5eg== 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:dkim-signature :dkim-signature:date; bh=bEU04sMLn2XAxbcar2dz/MSQvx8xXtoduoODOnXIeZw=; b=MEgWknL7gIfRC8r8+4yjPT7lP7g3cI/rz1Seq0G4YC1fMGGCGtRBFf4Gjnn7tNPb8U msTmGVBO5Kfe0H6gl4Gay5Cgxh6WI4C3BQeiqT+2dIEoCuaVqEZnE0Gy/eBnPz3HWbZs VWU2khm6MoM3ygAaLmGBmAzCRqz4a317nuIObhEvh9Jt6IPC0/TpS5ChwD+JqXRDZaIE 0kWoZRLq5TVXTXbTZMQKE7ogK9w9ulcLlRijKkHRE6sJcv1k97jK9vuzg2bmK+uPH/g9 BNvl4XHd06nYTA21tVGuGYMlLhp0NHLRKzC3+YA0yZchpD9hM0b0InXorjHELK2wg3xv S0aw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=B71AnKWQ; dkim=neutral (no key) header.i=@linutronix.de; 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=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m8si2473845eds.382.2021.08.04.10.01.24; Wed, 04 Aug 2021 10:01:58 -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=@linutronix.de header.s=2020 header.b=B71AnKWQ; dkim=neutral (no key) header.i=@linutronix.de; 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=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239721AbhHDQ6H (ORCPT + 99 others); Wed, 4 Aug 2021 12:58:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33202 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239620AbhHDQ6G (ORCPT ); Wed, 4 Aug 2021 12:58:06 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [IPv6:2a0a:51c0:0:12e:550::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D46D6C0613D5; Wed, 4 Aug 2021 09:57:53 -0700 (PDT) Date: Wed, 4 Aug 2021 18:57:51 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1628096272; 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=bEU04sMLn2XAxbcar2dz/MSQvx8xXtoduoODOnXIeZw=; b=B71AnKWQUvI2QH3W1ya76U7laqh9/gKbT95g0MDX+NKnLpvVOv+FzNAbCDYYbHOFpWZMBW HgqJgaKJQJSJ/7Ldqe2XOS5x1MkJBmvIBzKx8O/wkbwu7GGe5WZuRw/e9vL6WkJyEIB3JF PvWy11CE3LP3UlHLFH82dRpofEHezkFkr00yL31Xla1YBMc0thatngUN9A4mysOWAjonKJ I3+0RK7jNTeKfs8C0YgqBBaLPqV//NsR5og4eTSh9HgFgzhZ4vHKYFbphRjnqGrsaIn74M 8Zkbgf2UXv1L5FGuKXJsZMAJ+7RQjZaZH82s3OR097ng5lSyYNmgY7+I/Wwu8g== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1628096272; 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=bEU04sMLn2XAxbcar2dz/MSQvx8xXtoduoODOnXIeZw=; b=Efcr+yMJaqvetBjdEzabDUQTx1/yASGSLz7EatnRZdFJ+fCtv3J4P6IKbL/I10QLYOBSpz TZmKe7+IY+QKlrBQ== From: Sebastian Andrzej Siewior To: Steven Rostedt Cc: Jens Axboe , Peter Zijlstra , Daniel Wagner , Thomas Gleixner , LKML , linux-rt-users@vger.kernel.org Subject: Re: [ANNOUNCE] v5.14-rc4-rt4 Message-ID: <20210804165751.ifppsn3eqjnvfgqs@linutronix.de> References: <20210804153308.oasahcxjmcw7vivo@linutronix.de> <20210804154743.niogqvnladdkfgi2@linutronix.de> <7c946918-ae0d-6195-6a78-b019f9bc1fd3@kernel.dk> <20210804121704.1587c41b@oasis.local.home> <20210804162231.rfj5i736lqc4nsio@linutronix.de> <20210804122541.741cf858@oasis.local.home> <20210804163119.t4c7bkpdk33byxtx@linutronix.de> <20210804124755.21ca7e3d@oasis.local.home> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20210804124755.21ca7e3d@oasis.local.home> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2021-08-04 12:47:55 [-0400], Steven Rostedt wrote: > On Wed, 4 Aug 2021 18:31:19 +0200 > Sebastian Andrzej Siewior wrote: > > > CPU-local wake-ups just set NEED_RESCHED and wait for preempt_enable() > > to do the magic. Just because the code not perform wake_up() now does > > not mean it will not do so in the future. Also it is here as an example > > which might be copied somewhere else. > > Does this mean all local_irq_disable/enable() is audited? What do you do for; > > local_irq_disable(); > [..] > wakeup_process(x); /* on local CPU */ > [..] > local_irq_enable(); I hunted and fixed a few of those. I still have few preempt_check_resched_rt() which I want fix other than what is in RT. > And if local_irq_disable() is not used anymore, or seldom, what harm > would it be to add a preemption check to that caller? And change > local_irq_enable() that is used internally by other atom functions be > called __local_irq_enable()? > > Not to mention that we could just open code that too: > > if (IS_ENABLED(CONFIG_PREEMPT_RT)) { > local_irq_enable(); > preempt_check_resched(); > } > > And make it ugly enough that nobody will want to copy it :-) I remember that the amount of enthusiasm was quite low when it was suggested that local_irq_enable() gets additionally the preempt-check. Maybe was due to the people involved :) But we managed to work around it for most callers. Therefore we I wouldn't suggest local_irq_disable_rt(). We had it in -RT, we had a bunch of users and all of them were fixed in a different way. Same goes btw. for preempt_disable_rt() which has been reduced to vmstat and had previously more users :) > -- Steve Sebastian