From: Paul Walmsley <paul@pwsan.com>
To: Russell King - ARM Linux <linux@arm.linux.org.uk>
Cc: linux-arm-kernel@lists.arm.linux.org.uk,
linux-kernel@vger.kernel.org, linux-omap@vger.kernel.org,
"Måns Rullgård" <mans@mansr.com>,
"Tony Lindgren" <tony@atomide.com>
Subject: Re: [PATCH D 01/11] OMAP: Add clk_get_parent() for OMAP2/3
Date: Thu, 29 Jan 2009 23:29:31 -0700 (MST) [thread overview]
Message-ID: <alpine.DEB.2.00.0901292327090.26985@utopia.booyaka.com> (raw)
In-Reply-To: <20090129110043.GE12627@n2100.arm.linux.org.uk>
[-- Attachment #1: Type: TEXT/PLAIN, Size: 2236 bytes --]
On Thu, 29 Jan 2009, Russell King - ARM Linux wrote:
> On Wed, Jan 28, 2009 at 12:18:16PM -0700, Paul Walmsley wrote:
> > From: Mans Rullgard <mans@mansr.com>
> >
> > This makes clk_get_parent() work on OMAP2/3.
>
> This is clearly something that the generic code should be doing.
> It's not something specific to OMAP2/3. Please move it to
> arch/arm/plat-omap/clock.c
Done; revised patch below.
- Paul
From: Mans Rullgard <mans@mansr.com>
Date: Thu Jan 29 23:26:35 2009 -0700
OMAP: Add clk_get_parent() for OMAP1/2/3
This makes clk_get_parent() work on OMAP.
linux-omap source commit is efd65273726b12e42c7225bd1703e5252bdb46c0.
Signed-off-by: Måns Rullgård <mans@mansr.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
[paul@pwsan.com: per rmk, made this function available on all OMAPs
and fixated its implementation]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
diff --git a/arch/arm/plat-omap/clock.c b/arch/arm/plat-omap/clock.c
index be6aab9..eb59874 100644
--- a/arch/arm/plat-omap/clock.c
+++ b/arch/arm/plat-omap/clock.c
@@ -210,18 +210,7 @@ EXPORT_SYMBOL(clk_set_parent);
struct clk *clk_get_parent(struct clk *clk)
{
- unsigned long flags;
- struct clk * ret = NULL;
-
- if (clk == NULL || IS_ERR(clk))
- return ret;
-
- spin_lock_irqsave(&clockfw_lock, flags);
- if (arch_clock->clk_get_parent)
- ret = arch_clock->clk_get_parent(clk);
- spin_unlock_irqrestore(&clockfw_lock, flags);
-
- return ret;
+ return clk->parent;
}
EXPORT_SYMBOL(clk_get_parent);
diff --git a/arch/arm/plat-omap/include/mach/clock.h b/arch/arm/plat-omap/include/mach/clock.h
index f6adf39..47c9a11 100644
--- a/arch/arm/plat-omap/include/mach/clock.h
+++ b/arch/arm/plat-omap/include/mach/clock.h
@@ -104,7 +104,6 @@ struct clk_functions {
long (*clk_round_rate)(struct clk *clk, unsigned long rate);
int (*clk_set_rate)(struct clk *clk, unsigned long rate);
int (*clk_set_parent)(struct clk *clk, struct clk *parent);
- struct clk * (*clk_get_parent)(struct clk *clk);
void (*clk_allow_idle)(struct clk *clk);
void (*clk_deny_idle)(struct clk *clk);
void (*clk_disable_unused)(struct clk *clk);
next prev parent reply other threads:[~2009-01-30 6:29 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-28 19:18 [PATCH D 00/11] OMAP clock, D of F: clock code cleanup Paul Walmsley
2009-01-28 19:18 ` [PATCH D 01/11] OMAP: Add clk_get_parent() for OMAP2/3 Paul Walmsley
2009-01-28 19:18 ` Paul Walmsley
2009-01-29 11:00 ` Russell King - ARM Linux
2009-01-30 6:29 ` Paul Walmsley [this message]
2009-01-31 14:23 ` Russell King - ARM Linux
2009-01-31 15:07 ` Måns Rullgård
2009-01-31 15:26 ` Russell King - ARM Linux
2009-01-31 15:26 ` Russell King - ARM Linux
2009-01-31 15:39 ` Måns Rullgård
2009-01-31 15:39 ` Måns Rullgård
2009-01-31 15:56 ` Russell King - ARM Linux
2009-01-31 15:56 ` Russell King - ARM Linux
2009-01-31 16:51 ` Måns Rullgård
2009-01-31 16:51 ` Måns Rullgård
2009-01-28 19:18 ` [PATCH D 02/11] OMAP2/3 clock: clean up mach-omap2/clock.c Paul Walmsley
2009-01-28 19:18 ` [PATCH D 03/11] OMAP2 PRCM: clean up CM_IDLEST bits Paul Walmsley
2009-01-28 19:18 ` [PATCH D 04/11] OMAP3 clock: split mcbspX_src_fck from mcbspX_fck Paul Walmsley
2009-01-28 19:18 ` [PATCH D 05/11] OMAP2 clock: add clk.prcm_mod field; annotate OMAP2xxx clocks Paul Walmsley
2009-01-28 19:18 ` [PATCH D 06/11] OMAP3 clock: add "prcm_mod" field to OMAP3xxx clocks Paul Walmsley
2009-01-28 19:18 ` [PATCH D 07/11] OMAP2/3 clock: add _omap2_clk_{read,write}_reg() Paul Walmsley
2009-01-28 19:18 ` [PATCH D 08/11] OMAP2/3 clock: use clk->prcm_mod for all struct clk register addressing Paul Walmsley
2009-01-28 19:18 ` [PATCH D 09/11] OMAP2/3 clock: encode target IDLEST bits Paul Walmsley
2009-01-28 19:18 ` [PATCH D 10/11] OMAP2/3 clock: clean up omap2_clk_wait_ready() Paul Walmsley
2009-01-28 19:18 ` Paul Walmsley
2009-01-28 19:18 ` [PATCH D 11/11] Fix omap1 clock issues Paul Walmsley
2009-01-29 14:37 ` Russell King - ARM Linux
2009-01-30 7:58 ` Paul Walmsley
2009-02-06 21:19 ` Paul Walmsley
2009-02-06 21:44 ` Russell King - ARM Linux
2009-02-06 23:04 ` Paul Walmsley
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=alpine.DEB.2.00.0901292327090.26985@utopia.booyaka.com \
--to=paul@pwsan.com \
--cc=linux-arm-kernel@lists.arm.linux.org.uk \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-omap@vger.kernel.org \
--cc=linux@arm.linux.org.uk \
--cc=mans@mansr.com \
--cc=tony@atomide.com \
/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.