Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp2621527imm; Thu, 18 Oct 2018 18:51:23 -0700 (PDT) X-Google-Smtp-Source: ACcGV62wI3wzFWyGUzEEmYhsbCO37tX5vMmBgpdS7ImYhUtG3divwW/uLsHkQuUkeXIbFqKtLMkk X-Received: by 2002:a17:902:2de4:: with SMTP id p91-v6mr31688573plb.148.1539913883502; Thu, 18 Oct 2018 18:51:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1539913883; cv=none; d=google.com; s=arc-20160816; b=oDOOH+gBamjt+Yh+L6YD9WY2QuNbbLm36b/5NzUbkfu5z6dgr/uKe1+BCh5cmJ6uef MoHWrsHpoc/kSQrmz1IHts8LxcNHMpXPH18T4Q5IGRMYGNAUFiTZYFNWpc7lrIyFxDoR 5EeVrYOMVQ+rmYvSzb6Zwh3eqyMoS8L1ZjqFYWr0iagXbdswPYpL5DNf2Vh7+JcFCLhR YwHSDZz6K8JCWpRNkFuK/XxVq5CnXHmWKYCF3LqcqCT6zBp2tT6Z2mRNy7eR/QESNJQi LeXfcIpDgTcdtb1NFHOeGMBo2sEH/R/9hRViUIu+vINFkNVaY33dkgJ9XIdHKH98pq5n KKTQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date; bh=ty21MD9ek2wuSbYYr0ulbT52XTzKG192OGFjuQ9fW+A=; b=YtJBbPa03j5pALK7TAYQZWvxCeySTfgaFYLa59Ssmgp0FSMHtwOPBguIJuaF2HobtU oFz8NQ06wt/Z5UXvLc3J0bItQnTfQG5QrbGPtLu9GQSO9IbpClhBjNdumD3EvUtkeU24 Apgaa97cTDqmHcDaqFvsi2blNiRSUSVM/4Eim8dAiapIGwHWroQV5UsH9GVOa2pxV9mw JKRdJ3ouoRmuxFXnJPOxx1bbNPjF0C4ZVI7O5CSdAfHNupQoWFEUqym8OBCub3/jK/wL Tm/V7y5uUw2uT2bXdVLPtQbKVY3z/00N9T1ziKq2dsnSnCAyHJ6N+Fdy9J/SV+XOGbIm xPXA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m39-v6si9088452plg.335.2018.10.18.18.51.08; Thu, 18 Oct 2018 18:51:23 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726667AbeJSJy3 (ORCPT + 99 others); Fri, 19 Oct 2018 05:54:29 -0400 Received: from mail.kernel.org ([198.145.29.99]:33318 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725934AbeJSJy3 (ORCPT ); Fri, 19 Oct 2018 05:54:29 -0400 Received: from vmware.local.home (cpe-66-24-56-78.stny.res.rr.com [66.24.56.78]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 057C620644; Fri, 19 Oct 2018 01:50:36 +0000 (UTC) Date: Thu, 18 Oct 2018 21:50:35 -0400 From: Steven Rostedt To: Joel Fernandes Cc: "Paul E. McKenney" , Nikolay Borisov , linux-kernel@vger.kernel.org, Jonathan Corbet , Josh Triplett , Lai Jiangshan , linux-doc@vger.kernel.org, Mathieu Desnoyers Subject: Re: [PATCH RFC] doc: rcu: remove obsolete (non-)requirement about disabling preemption Message-ID: <20181018215035.5e8ff553@vmware.local.home> In-Reply-To: <20181019012645.GC89903@joelaf.mtv.corp.google.com> References: <20181015210856.GE2674@linux.ibm.com> <20181016112611.GA27405@linux.ibm.com> <20181016204122.GA8176@joelaf.mtv.corp.google.com> <20181017161100.GP2674@linux.ibm.com> <20181017181505.GC107185@joelaf.mtv.corp.google.com> <20181017203324.GS2674@linux.ibm.com> <20181018020751.GB99677@joelaf.mtv.corp.google.com> <20181018144637.GD2674@linux.ibm.com> <20181019000350.GB89903@joelaf.mtv.corp.google.com> <20181019001932.GR2674@linux.ibm.com> <20181019012645.GC89903@joelaf.mtv.corp.google.com> X-Mailer: Claws Mail 3.15.1 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 18 Oct 2018 18:26:45 -0700 Joel Fernandes wrote: > Yes, local_irq_restore is light weight, and does not check for reschedules. > > I was thinking of case where ksoftirqd is woken up, but does not run unless > we set the NEED_RESCHED flag. But that should get set anyway since probably > ksoftirqd is of high enough priority than the currently running task.. > > Roughly speaking the scenario could be something like: > > rcu_read_lock(); > <-- IPI comes in for the expedited GP, sets exp_hint > local_irq_disable(); > // do a bunch of stuff > rcu_read_unlock(); <-- This calls the rcu_read_unlock_special which raises > the soft irq, and wakesup softirqd. If softirqd is of higher priority than the current running task, then the try_to_wake_up() will set NEED_RESCHED of the current task here. -- Steve > local_irq_enable(); > > // Now ksoftirqd is ready to run but we don't switch into the > // scheduler for sometime because tif_need_resched() returns false and > // any cond_resched calls do nothing. So we potentially spend lots of > // time before the next scheduling event. > > You think this should not be an issue?