Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp3783366imm; Sun, 13 May 2018 20:12:32 -0700 (PDT) X-Google-Smtp-Source: AB8JxZqPQs7XLlz1JRy5ersBMUSmTeI8I+N5XJLmt5uJjRVvEAhcypz6hRCkakEO2CFcOawGqF3o X-Received: by 2002:a17:902:7109:: with SMTP id a9-v6mr8028269pll.271.1526267552049; Sun, 13 May 2018 20:12:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526267551; cv=none; d=google.com; s=arc-20160816; b=F0Q2XvMyx3JG4a2+u73X/0BPzCXpzAT8I1vPLIpCT9biHOB3EMljZ4w7hkp0iWHiCO lK67N55d8LRs1FQh6FH4EpGZjeSgNIQBVo+VXCT6LzL9ky/P5jpDCcvJdWmVUEJtl2QZ QxzDm7cAV/jQonqIOM4gdTwgHldfsINOsnZPl+U9Rk2CgjvPB3WMrEqERJHlPdEORP8I FuB3e6x3JABo+TsWu6niKqn5Y1J24j3PwYYXNlQKzm4DqWylWeWY6cCG/88pgaFM2cC2 jpKvYwP9XFIwy33HWvkXjtM0dp39FJhqLm7zP5fP2z+1azawCa1CESwIWIZVZsETYoDn peZA== 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 :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:arc-authentication-results; bh=aZ4qBnVe0na7seg4LLQ/U5MlePy/05Ul9MYkiVy5uNA=; b=dptqjX3F38r0Hm5GFYqO4a/eB9uFUcyNtaQYK3wEhCb1iaLuM1MBPbkN8WqAoRCG5d Kg3lS8ZkbD1+fCv7UWR5uhNwtCbcb7H2LOXkGSqlaVPhonzDQKbsHBltvmoGgbnXAV7h kpFb8CPQisAewHsAw99GHPeRkQR5LUqXwGq41UTIUJhHnNSdvQEzKW7a3aGuXJjpEmi1 bJd/AcBfrptC/y/dM1mUILKIKO37M/TiP2ac67JTbyXxASpwd89mg0MijitFWb9rbVzL 0F352aTdnqeREKmieL0xJQ3IrQyN5Jj6DrHThu8FDjpjTaoVZ6ic50DSvngcwqQr6OCj TDVg== 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 e191-v6si6926203pgc.233.2018.05.13.20.12.15; Sun, 13 May 2018 20:12:31 -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 S1752028AbeENDMD (ORCPT + 99 others); Sun, 13 May 2018 23:12:03 -0400 Received: from lgeamrelo13.lge.com ([156.147.23.53]:33094 "EHLO lgeamrelo11.lge.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751953AbeENDMC (ORCPT ); Sun, 13 May 2018 23:12:02 -0400 Received: from unknown (HELO lgemrelse6q.lge.com) (156.147.1.121) by 156.147.23.53 with ESMTP; 14 May 2018 12:11:59 +0900 X-Original-SENDERIP: 156.147.1.121 X-Original-MAILFROM: byungchul.park@lge.com Received: from unknown (HELO ?10.177.220.135?) (10.177.220.135) by 156.147.1.121 with ESMTP; 14 May 2018 12:11:59 +0900 X-Original-SENDERIP: 10.177.220.135 X-Original-MAILFROM: byungchul.park@lge.com Subject: Re: [PATCH] rcu: Report a quiescent state when it's exactly in the state To: Steven Rostedt , "Paul E. McKenney" Cc: Joel Fernandes , jiangshanlai@gmail.com, josh@joshtriplett.org, mathieu.desnoyers@efficios.com, linux-kernel@vger.kernel.org, kernel-team@lge.com, peterz@infradead.org References: <1526027434-21237-1-git-send-email-byungchul.park@lge.com> <3af4cec0-4019-e3ac-77f9-8631252fb6da@lge.com> <20180511161746.GX26088@linux.vnet.ibm.com> <20180511224138.GA89902@joelaf.mtv.corp.google.com> <20180512050824.GF26088@linux.vnet.ibm.com> <20180512063037.GC192642@joelaf.mtv.corp.google.com> <20180512144119.GJ26088@linux.vnet.ibm.com> <20180512132647.2923f7cf@gandalf.local.home> From: Byungchul Park Message-ID: Date: Mon, 14 May 2018 12:11:59 +0900 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0 MIME-Version: 1.0 In-Reply-To: <20180512132647.2923f7cf@gandalf.local.home> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2018-05-13 오전 2:26, Steven Rostedt wrote: > On Sat, 12 May 2018 07:41:19 -0700 > "Paul E. McKenney" wrote: > >> Don't get me wrong, this discussion was quite useful to me. We probably >> need to at least change the comments, and perhaps the code as well. But >> I agree that we need input from Peter and Steven to make much more forward >> progress. > > It's the weekend so I skimmed more than read this thread, but I will > just add this. > > The table Joel posted is interesting, and perhaps we should keep things > consistent with that. But that said, with respect to task-RCU, as > nothing on a trampoline should ever call cond_resched() (and perhaps I > should add code in lockdep that verifies this), we just want a > quiescent state that tells us that the task has left the trampoline. A > cond_resched() should be one of those points that does. > > It really has nothing to do with scheduling or preemption. The issue is > that if a task is on a trampoline and gets preempted, there's no > knowing when it is off that trampoline where we can free it. We need to > have places in the kernel that we know is a quiescent state to move > task-RCU forward. cond_resched() seems to be one of them. schedule > itself can not be, because it can be called from an interrupt preempting > a task while it is on the trampoline. Exactly. I think Steven explained how we should consider them exactly. > -- Steve -- Thanks, Byungchul