From patchwork Thu Oct 19 23:35:39 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Frederic Weisbecker X-Patchwork-Id: 13429938 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0000AC001DF for ; Thu, 19 Oct 2023 23:35:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233335AbjJSXfz (ORCPT ); Thu, 19 Oct 2023 19:35:55 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48794 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233356AbjJSXfy (ORCPT ); Thu, 19 Oct 2023 19:35:54 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 86CB7115; Thu, 19 Oct 2023 16:35:52 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 3AD2EC433C7; Thu, 19 Oct 2023 23:35:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1697758551; bh=SzLWgqoBPQQV6V/J505+0jRncHFp919ngRzIfJhC4vg=; h=From:To:Cc:Subject:Date:From; b=kdlrCLav/1qxe+M3GYO1Mt3VSCTSLV695AQlk5hcUYK7f8k5YG8jeexEqBnddmSCF cj2sxDOoteNjSh/oGgmCdbNKq67BTYV0VPlJ6uOXoIZqSmz9sPwwoEn9b2UXBNxrnQ mutI3F+8Fq9zoXNcmSzgDeIXdf1OaH20XpUHlZ7nQSaHMHITf/5zLGhT2JQ3sUOy9/ R8D+X1bKaQpzOTmi1yuDlBJD0l39ZK+koMwdYH0d6/+L5JNwWe5wagC+BG9AIEJMwA faSGciZKKVeoDCQxtAGIQg5ZQJtDST1mxkx3CaeILSGfxFqmn9zHuD0ngVb62r2l/u +cEP/irpUWV1Q== From: Frederic Weisbecker To: LKML Cc: Frederic Weisbecker , Boqun Feng , Joel Fernandes , Josh Triplett , Mathieu Desnoyers , Neeraj Upadhyay , "Paul E . McKenney" , Steven Rostedt , Uladzislau Rezki , rcu , "Liam R . Howlett" , Peter Zijlstra , Sebastian Siewior , Thomas Gleixner , Zqiang , Lai Jiangshan Subject: [PATCH 0/4] rcu: Fix PF_IDLE related issues, part. 1 Date: Fri, 20 Oct 2023 01:35:39 +0200 Message-Id: <20231019233543.1243121-1-frederic@kernel.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: rcu@vger.kernel.org The modification of PF_IDLE semantics lately to fix a bug in rcutiny eventually introduced new bugs in RCU-tasks. This series revert that PF_IDLE modification and fix rcutiny in an alternate way. More issues need to be fixed in RCU-tasks: * The boot code preceding the idle entry is included in this quiescent state. Especially after the completion of kthreadd_done after which init/1 can launch userspace concurrently. The window is tiny before PF_IDLE is set but it exists. * Similarly, the boot code preceding the idle entry on secondary CPUs is wrongly accounted as RCU tasks quiescent state. And those will be fixed separetely. Frederic Weisbecker (4): softirq: Rename __raise_softirq_irqoff() to raise_softirq_no_wake() softirq: Introduce raise_ksoftirqd_irqoff() rcu: Make tiny RCU use ksoftirqd to trigger a QS from idle Revert "kernel/sched: Modify initial boot task idle setup" block/blk-mq.c | 2 +- include/linux/interrupt.h | 3 ++- kernel/rcu/tiny.c | 21 +++++++++++++----- kernel/sched/core.c | 2 +- kernel/sched/idle.c | 1 - kernel/softirq.c | 45 +++++++++++++++++++++++++-------------- lib/irq_poll.c | 4 ++-- net/core/dev.c | 8 +++---- 8 files changed, 55 insertions(+), 31 deletions(-)