From mboxrd@z Thu Jan 1 00:00:00 1970 From: Steven Rostedt Subject: Re: RFC on fixing mutex spinning on owner Date: Thu, 17 Mar 2016 08:06:29 -0400 Message-ID: <20160317080629.1af8f733@grimm.local.home> References: <20160316233530.GA8731@kroah.com> <20160316221751.71816309@grimm.local.home> <20160317073605.GM6344@twins.programming.kicks-ass.net> <20160317080526.GB6679@osadl.at> <20160317101823.GQ6344@twins.programming.kicks-ass.net> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: Peter Zijlstra , Nicholas Mc Guire , Joel Fernandes , Greg Kroah-Hartman , linux-rt-users@vger.kernel.org, Linux Kernel Mailing List , kernelnewbies , Ingo Molnar To: Thomas Gleixner Return-path: Received: from smtprelay0221.hostedemail.com ([216.40.44.221]:37545 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1755969AbcCQMGe (ORCPT ); Thu, 17 Mar 2016 08:06:34 -0400 In-Reply-To: Sender: linux-rt-users-owner@vger.kernel.org List-ID: On Thu, 17 Mar 2016 12:16:11 +0100 (CET) Thomas Gleixner wrote: > On Thu, 17 Mar 2016, Peter Zijlstra wrote: > > Also, maybe the tracer should measure the time from need_resched() > > getting true until the next preemption point, instead of the entire time > > preemption was disabled. Which would avoid the entire issue altogether. > > Well, that only gives you the information on a actual preemption, but not > information about long preempt disabled regions which can cause a problem > eventually. > Actually, I was thinking the reverse. If need_resched() is called and is false, then do a reset of the preemption time. But if need_resched() is true, then do nothing, as that would measure the total time preempt disable was set and a task could not schedule. Question is, should this be a hook and each location audited, or add this to need_resched() itself? -- Steve