From: Will Deacon <will.deacon-5wv7dgnIgG8@public.gmane.org>
To: Kobe Wu <kobe-cp.wu-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org>
Cc: Peter Zijlstra <peterz-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org>,
Eason Lin <eason-yh.lin-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org>,
Ingo Molnar <mingo-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>,
linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
wsd_upstream-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org
Subject: Re: [PATCH] locking/lockdep: Remove unnecessary DEBUG_LOCKS_WARN_ON()
Date: Wed, 5 Jun 2019 13:46:33 +0100 [thread overview]
Message-ID: <20190605124633.GM15030@fuggles.cambridge.arm.com> (raw)
In-Reply-To: <1559217575-30298-1-git-send-email-kobe-cp.wu-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org>
On Thu, May 30, 2019 at 07:59:35PM +0800, Kobe Wu wrote:
> DEBUG_LOCKS_WARN_ON() will turn off debug_locks and
> makes print_unlock_imbalance_bug() return directly.
>
> Remove a redundant whitespace.
>
> Signed-off-by: Kobe Wu <kobe-cp.wu-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org>
> ---
> kernel/locking/lockdep.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/kernel/locking/lockdep.c b/kernel/locking/lockdep.c
> index d06190f..37c0a5e 100644
> --- a/kernel/locking/lockdep.c
> +++ b/kernel/locking/lockdep.c
> @@ -4049,8 +4049,8 @@ static int __lock_downgrade(struct lockdep_map *lock, unsigned long ip)
> * So we're all set to release this lock.. wait what lock? We don't
> * own any locks, you've been drinking again?
> */
> - if (DEBUG_LOCKS_WARN_ON(depth <= 0))
> - return print_unlock_imbalance_bug(curr, lock, ip);
> + if (depth <= 0)
> + return print_unlock_imbalance_bug(curr, lock, ip);
Hmm, feels more like we should keep the DEBUG_LOCKS_WARN_ON but just
return 0 when it fires.
Peter?
Will
next prev parent reply other threads:[~2019-06-05 12:46 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-05-30 11:59 [PATCH] locking/lockdep: Remove unnecessary DEBUG_LOCKS_WARN_ON() Kobe Wu
[not found] ` <1559217575-30298-1-git-send-email-kobe-cp.wu-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org>
2019-06-05 12:46 ` Will Deacon [this message]
[not found] ` <20190605124633.GM15030-UDVVEH7NWB15pKCnmE3YQBJ8xKzm50AiAL8bYrjMMd8@public.gmane.org>
2019-06-05 13:35 ` Peter Zijlstra
2019-06-17 14:18 ` [tip:locking/core] " tip-bot for Kobe Wu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190605124633.GM15030@fuggles.cambridge.arm.com \
--to=will.deacon-5wv7dgnigg8@public.gmane.org \
--cc=eason-yh.lin-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org \
--cc=kobe-cp.wu-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org \
--cc=linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
--cc=mingo-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
--cc=peterz-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org \
--cc=wsd_upstream-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.