From: vzapolskiy@gmail.com (Vladimir Zapolskiy)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 2/2] [ARM] [IMX]: Fix clock usecount counter from underflow.
Date: Wed, 17 Mar 2010 13:57:57 +0300 [thread overview]
Message-ID: <acc484891003170357t151171e7of57a459cc46e9c4e@mail.gmail.com> (raw)
In-Reply-To: <eedb5541003170315t55f3aff1n4dadd25d08a35d7b@mail.gmail.com>
Hello all,
and thank you for helpful comments.
2010/3/17 javier Martin <javier.martin@vista-silicon.com>
> 2010/3/17 Uwe Kleine-K?nig <u.kleine-koenig@pengutronix.de>:
> > I'm not sure this is worth it. IMHO an unbalanced clk_disable is a
> > severe bug that doesn't need to be handled smoothly.
> >
> > But maybe move the WARN_ON before the __clk_disable(clk->parent)? This
> > way the disabled parent clock cannot stop the message to appear.
> >
> > Other than that, please use WARN instead of printk + WARN_ON. Then the
> > message is printed only after the oops begin marker.
>
> I agree with Uwe, I myself tried to do something similar in the past and
> people
> made me realize that we don't have to fix here what is really a problem in
> some
> driver which calls unbalanced disable/enable.
>
> However, I think using WARN would be a good idea since it allows the
> kernel hacker
> to track an error which according to my own experience is very
> difficult to detect.
>
>
I agree with all of you that this patch is not a bug fix, but definitely a
misfeature elimination.
WARN must be present anyway to inform about an incident of multiple
clk_disable() calls, no doubt. But I assume that if a board can be easily
left in working condition after all, this could help the kernel hacker too.
Let me send a patch with respect to Uwe's comments firstly.
With best wishes,
Vladimir
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20100317/96ceefa3/attachment-0001.htm>
next prev parent reply other threads:[~2010-03-17 10:57 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-17 7:11 [PATCH 1/2] [ARM] [IMX]: Removed superfluous checks for argument validity Vladimir Zapolskiy
2010-03-17 7:11 ` [PATCH 2/2] [ARM] [IMX]: Fix clock usecount counter from underflow Vladimir Zapolskiy
2010-03-17 9:20 ` Uwe Kleine-König
2010-03-17 10:15 ` javier Martin
2010-03-17 10:57 ` Vladimir Zapolskiy [this message]
2010-03-17 11:03 ` [PATCH 2/2 v2] [ARM] [IMX]: Fix clock use counter from underflow on multiple clk_disable() Vladimir Zapolskiy
2010-03-18 8:30 ` Uwe Kleine-König
2010-03-18 13:21 ` Vladimir Zapolskiy
2010-03-17 9:13 ` [PATCH 1/2] [ARM] [IMX]: Removed superfluous checks for argument validity Uwe Kleine-König
2010-03-17 10:34 ` Vladimir Zapolskiy
2010-03-18 8:37 ` Uwe Kleine-König
2010-03-18 13:07 ` Vladimir Zapolskiy
2010-03-18 13:27 ` [PATCH 1/2 v2] imx: optimize __clk_enable() and __clk_disable() functions Vladimir Zapolskiy
2010-03-18 14:23 ` Vladimir Zapolskiy
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=acc484891003170357t151171e7of57a459cc46e9c4e@mail.gmail.com \
--to=vzapolskiy@gmail.com \
--cc=linux-arm-kernel@lists.infradead.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).