[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <1307471685.9218.7.camel@gandalf.stny.rr.com>
Date: Tue, 07 Jun 2011 14:34:45 -0400
From: Steven Rostedt <rostedt@...dmis.org>
To: Hillf Danton <dhillf@...il.com>
Cc: Peter Zijlstra <peterz@...radead.org>,
LKML <linux-kernel@...r.kernel.org>, Ingo Molnar <mingo@...e.hu>
Subject: Re: [PATCH] sched: correct testing need_resched in
mutex_spin_on_owner()
On Wed, 2011-06-08 at 02:22 +0800, Hillf Danton wrote:
> After hours chewing __mutex_lock_common() and mutex_spin_on_owner(),
> and what you and Peter said, the owner is on different CPU from the waiter,
> and the patched need_resched is simply meaning the waiter is no longer
> willing to wait for whatever reasons.
>
> It is really unlucky tonight:(
Please don't get discouraged.
We just want you to spend a bit more time looking at the code. Do what I
do when something looks wrong. Try to figure out what the author was
doing and why it may actually be correct. You may find out that the code
is indeed correct.
When I see code that looks wrong, I first think my assumptions are
incorrect, and I try to prove myself wrong. Only when I fail to do that,
do I send a patch or bring it up to the author. And then, I do it in
such a way that the author of the code may still have the ability to
prove me wrong. And several times, an author will tell me something that
I overlooked, and the original code stays as is.
Don't take it personally, this is just a learning phase. ;)
-- Steve
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists