From: david.andrey@netmodule.com (David Andrey)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] clk: remove clock notifier at unregister
Date: Mon, 22 Apr 2013 14:22:41 +0200 [thread overview]
Message-ID: <1366633361-28887-1-git-send-email-david.andrey@netmodule.com> (raw)
Clock notifier node is now removed from the
notifier list during unregister
Signed-off-by: David Andrey <david.andrey@netmodule.com>
Acked-by: Martin Meuli <martin.meuli@netmodule.com>
---
drivers/clk/clk.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/drivers/clk/clk.c b/drivers/clk/clk.c
index 20ce67f..eb66434 100644
--- a/drivers/clk/clk.c
+++ b/drivers/clk/clk.c
@@ -1941,7 +1941,10 @@ int clk_notifier_unregister(struct clk *clk, struct notifier_block *nb)
/* XXX the notifier code should handle this better */
if (!cn->notifier_head.head) {
+ if (clk->notifier_count)
+ BUG();
srcu_cleanup_notifier_head(&cn->notifier_head);
+ list_del(&cn->node);
kfree(cn);
}
--
1.7.4.1
next reply other threads:[~2013-04-22 12:22 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-22 12:22 David Andrey [this message]
2013-05-06 22:41 ` [PATCH] clk: remove clock notifier at unregister Mike Turquette
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=1366633361-28887-1-git-send-email-david.andrey@netmodule.com \
--to=david.andrey@netmodule.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).