* [PATCH 0/4] OMAP2/3: clock/clockdomains: miscellaneous fixes
@ 2011-02-26 0:20 Paul Walmsley
2011-02-26 0:20 ` [PATCH 1/4] OMAP2xxx: clock: remove dsp_irate_ick Paul Walmsley
` (3 more replies)
0 siblings, 4 replies; 6+ messages in thread
From: Paul Walmsley @ 2011-02-26 0:20 UTC (permalink / raw)
To: linux-arm-kernel
Hello,
here are a few miscellaneous OMAP2 clock and clockdomain
data for 2.6.39.
Boot-tested on N800. Compile-tested for omap2plus_defconfig and
omap3_defconfig.
This series is available via git in the branch 'clk_clkdm_a_2.6.39' of
git://git.pwsan.com/linux-2.6.
- Paul
---
clk_clkdm_a_2.6.39
text data bss dec hex filename
3701835 230192 5390012 9322039 8e3e37 vmlinux.n800_config.orig
3701803 230064 5390012 9321879 8e3d97 vmlinux.n800_config
Paul Walmsley (4):
OMAP2xxx: clock: remove dsp_irate_ick
OMAP2/3: clockdomains: remove warnings on an OMAP3-only compile
OMAP2xxx: clock: fix clockdomains on gpt7_ick, 2430 mmchs2_fck clocks
OMAP2xxx: clock data: clean up some comments
arch/arm/mach-omap2/clock.h | 1
arch/arm/mach-omap2/clock2420_data.c | 55 +++++++--------------
arch/arm/mach-omap2/clock2430_data.c | 58 ++++++++--------------
arch/arm/mach-omap2/clock_common_data.c | 6 ++
arch/arm/mach-omap2/clockdomains2xxx_3xxx_data.c | 4 ++
5 files changed, 51 insertions(+), 73 deletions(-)
^ permalink raw reply [flat|nested] 6+ messages in thread* [PATCH 1/4] OMAP2xxx: clock: remove dsp_irate_ick 2011-02-26 0:20 [PATCH 0/4] OMAP2/3: clock/clockdomains: miscellaneous fixes Paul Walmsley @ 2011-02-26 0:20 ` Paul Walmsley 2011-02-26 0:20 ` [PATCH 2/4] OMAP2/3: clockdomains: remove warnings on an OMAP3-only compile Paul Walmsley ` (2 subsequent siblings) 3 siblings, 0 replies; 6+ messages in thread From: Paul Walmsley @ 2011-02-26 0:20 UTC (permalink / raw) To: linux-arm-kernel After commit 81b34fbecbfbf24ed95c2d80d5cb14149652408f ("OMAP2 clock: split OMAP2420, OMAP2430 clock data into their own files"), it's possible to remove dsp_irate_ick from the OMAP2420 and OMAP2430 clock files. It was originally only needed due to a 2420/2430 clock tree difference, and now that the data is in separate files, it's superfluous. Signed-off-by: Paul Walmsley <paul@pwsan.com> --- arch/arm/mach-omap2/clock.h | 1 + arch/arm/mach-omap2/clock2420_data.c | 31 ++++++++----------------------- arch/arm/mach-omap2/clock2430_data.c | 31 ++++++++----------------------- arch/arm/mach-omap2/clock_common_data.c | 6 ++++++ 4 files changed, 23 insertions(+), 46 deletions(-) diff --git a/arch/arm/mach-omap2/clock.h b/arch/arm/mach-omap2/clock.h index 62cfd6c..e10ff2b 100644 --- a/arch/arm/mach-omap2/clock.h +++ b/arch/arm/mach-omap2/clock.h @@ -139,6 +139,7 @@ extern struct clk *vclk, *sclk; extern const struct clksel_rate gpt_32k_rates[]; extern const struct clksel_rate gpt_sys_rates[]; extern const struct clksel_rate gfx_l3_rates[]; +extern const struct clksel_rate dsp_ick_rates[]; #if defined(CONFIG_ARCH_OMAP2) && defined(CONFIG_CPU_FREQ) extern void omap2_clk_init_cpufreq_table(struct cpufreq_frequency_table **table); diff --git a/arch/arm/mach-omap2/clock2420_data.c b/arch/arm/mach-omap2/clock2420_data.c index 22eeafc..53bd999 100644 --- a/arch/arm/mach-omap2/clock2420_data.c +++ b/arch/arm/mach-omap2/clock2420_data.c @@ -454,36 +454,22 @@ static struct clk dsp_fck = { .recalc = &omap2_clksel_recalc, }; -/* DSP interface clock */ -static const struct clksel_rate dsp_irate_ick_rates[] = { - { .div = 1, .val = 1, .flags = RATE_IN_24XX }, - { .div = 2, .val = 2, .flags = RATE_IN_24XX }, - { .div = 0 }, -}; - -static const struct clksel dsp_irate_ick_clksel[] = { - { .parent = &dsp_fck, .rates = dsp_irate_ick_rates }, +static const struct clksel dsp_ick_clksel[] = { + { .parent = &dsp_fck, .rates = dsp_ick_rates }, { .parent = NULL } }; -/* This clock does not exist as such in the TRM. */ -static struct clk dsp_irate_ick = { - .name = "dsp_irate_ick", - .ops = &clkops_null, - .parent = &dsp_fck, - .clksel_reg = OMAP_CM_REGADDR(OMAP24XX_DSP_MOD, CM_CLKSEL), - .clksel_mask = OMAP24XX_CLKSEL_DSP_IF_MASK, - .clksel = dsp_irate_ick_clksel, - .recalc = &omap2_clksel_recalc, -}; - -/* 2420 only */ static struct clk dsp_ick = { .name = "dsp_ick", /* apparently ipi and isp */ .ops = &clkops_omap2_iclk_dflt_wait, - .parent = &dsp_irate_ick, + .parent = &dsp_fck, + .clkdm_name = "dsp_clkdm", .enable_reg = OMAP_CM_REGADDR(OMAP24XX_DSP_MOD, CM_ICLKEN), .enable_bit = OMAP2420_EN_DSP_IPI_SHIFT, /* for ipi */ + .clksel_reg = OMAP_CM_REGADDR(OMAP24XX_DSP_MOD, CM_CLKSEL), + .clksel_mask = OMAP24XX_CLKSEL_DSP_IF_MASK, + .clksel = dsp_ick_clksel, + .recalc = &omap2_clksel_recalc, }; /* @@ -1812,7 +1798,6 @@ static struct omap_clk omap2420_clks[] = { CLK(NULL, "mpu_ck", &mpu_ck, CK_242X), /* dsp domain clocks */ CLK(NULL, "dsp_fck", &dsp_fck, CK_242X), - CLK(NULL, "dsp_irate_ick", &dsp_irate_ick, CK_242X), CLK(NULL, "dsp_ick", &dsp_ick, CK_242X), CLK(NULL, "iva1_ifck", &iva1_ifck, CK_242X), CLK(NULL, "iva1_mpu_int_ifck", &iva1_mpu_int_ifck, CK_242X), diff --git a/arch/arm/mach-omap2/clock2430_data.c b/arch/arm/mach-omap2/clock2430_data.c index df4cac5..36dde26 100644 --- a/arch/arm/mach-omap2/clock2430_data.c +++ b/arch/arm/mach-omap2/clock2430_data.c @@ -433,37 +433,23 @@ static struct clk dsp_fck = { .recalc = &omap2_clksel_recalc, }; -/* DSP interface clock */ -static const struct clksel_rate dsp_irate_ick_rates[] = { - { .div = 1, .val = 1, .flags = RATE_IN_24XX }, - { .div = 2, .val = 2, .flags = RATE_IN_24XX }, - { .div = 3, .val = 3, .flags = RATE_IN_243X }, - { .div = 0 }, -}; - -static const struct clksel dsp_irate_ick_clksel[] = { - { .parent = &dsp_fck, .rates = dsp_irate_ick_rates }, +static const struct clksel dsp_ick_clksel[] = { + { .parent = &dsp_fck, .rates = dsp_ick_rates }, { .parent = NULL } }; -/* This clock does not exist as such in the TRM. */ -static struct clk dsp_irate_ick = { - .name = "dsp_irate_ick", - .ops = &clkops_null, - .parent = &dsp_fck, - .clksel_reg = OMAP_CM_REGADDR(OMAP24XX_DSP_MOD, CM_CLKSEL), - .clksel_mask = OMAP24XX_CLKSEL_DSP_IF_MASK, - .clksel = dsp_irate_ick_clksel, - .recalc = &omap2_clksel_recalc, -}; - /* 2430 only - EN_DSP controls both dsp fclk and iclk on 2430 */ static struct clk iva2_1_ick = { .name = "iva2_1_ick", .ops = &clkops_omap2_dflt_wait, - .parent = &dsp_irate_ick, + .parent = &dsp_fck, + .clkdm_name = "dsp_clkdm", .enable_reg = OMAP_CM_REGADDR(OMAP24XX_DSP_MOD, CM_FCLKEN), .enable_bit = OMAP24XX_CM_FCLKEN_DSP_EN_DSP_SHIFT, + .clksel_reg = OMAP_CM_REGADDR(OMAP24XX_DSP_MOD, CM_CLKSEL), + .clksel_mask = OMAP24XX_CLKSEL_DSP_IF_MASK, + .clksel = dsp_ick_clksel, + .recalc = &omap2_clksel_recalc, }; /* @@ -1900,7 +1886,6 @@ static struct omap_clk omap2430_clks[] = { CLK(NULL, "mpu_ck", &mpu_ck, CK_243X), /* dsp domain clocks */ CLK(NULL, "dsp_fck", &dsp_fck, CK_243X), - CLK(NULL, "dsp_irate_ick", &dsp_irate_ick, CK_243X), CLK(NULL, "iva2_1_ick", &iva2_1_ick, CK_243X), /* GFX domain clocks */ CLK(NULL, "gfx_3d_fck", &gfx_3d_fck, CK_243X), diff --git a/arch/arm/mach-omap2/clock_common_data.c b/arch/arm/mach-omap2/clock_common_data.c index 1cf8131..6424d46 100644 --- a/arch/arm/mach-omap2/clock_common_data.c +++ b/arch/arm/mach-omap2/clock_common_data.c @@ -37,3 +37,9 @@ const struct clksel_rate gfx_l3_rates[] = { { .div = 0 } }; +const struct clksel_rate dsp_ick_rates[] = { + { .div = 1, .val = 1, .flags = RATE_IN_24XX }, + { .div = 2, .val = 2, .flags = RATE_IN_24XX }, + { .div = 3, .val = 3, .flags = RATE_IN_243X }, + { .div = 0 }, +}; ^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 2/4] OMAP2/3: clockdomains: remove warnings on an OMAP3-only compile 2011-02-26 0:20 [PATCH 0/4] OMAP2/3: clock/clockdomains: miscellaneous fixes Paul Walmsley 2011-02-26 0:20 ` [PATCH 1/4] OMAP2xxx: clock: remove dsp_irate_ick Paul Walmsley @ 2011-02-26 0:20 ` Paul Walmsley 2011-03-01 0:17 ` Paul Walmsley 2011-02-26 0:20 ` [PATCH 3/4] OMAP2xxx: clock: fix clockdomains on gpt7_ick, 2430 mmchs2_fck clocks Paul Walmsley 2011-02-26 0:20 ` [PATCH 4/4] OMAP2xxx: clock data: clean up some comments Paul Walmsley 3 siblings, 1 reply; 6+ messages in thread From: Paul Walmsley @ 2011-02-26 0:20 UTC (permalink / raw) To: linux-arm-kernel Resolve these compile-time gcc warnings on OMAP3-only kernel compiles: .../mach-omap2/clockdomains2xxx_3xxx_data.c:95: warning: 'dsp_24xx_wkdeps' defined but not used .../mach-omap2/clockdomains2xxx_3xxx_data.c:119: warning: 'mpu_24xx_wkdeps' defined but not used .../mach-omap2/clockdomains2xxx_3xxx_data.c:147: warning: 'core_24xx_wkdeps' defined but not used Signed-off-by: Paul Walmsley <paul@pwsan.com> --- arch/arm/mach-omap2/clockdomains2xxx_3xxx_data.c | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/arch/arm/mach-omap2/clockdomains2xxx_3xxx_data.c b/arch/arm/mach-omap2/clockdomains2xxx_3xxx_data.c index ffdfe54..f9df791 100644 --- a/arch/arm/mach-omap2/clockdomains2xxx_3xxx_data.c +++ b/arch/arm/mach-omap2/clockdomains2xxx_3xxx_data.c @@ -89,6 +89,8 @@ static struct clkdm_dep gfx_sgx_wkdeps[] = { /* 24XX-specific possible dependencies */ +#ifdef CONFIG_ARCH_OMAP2 + /* Wakeup dependency source arrays */ /* 2420/2430 PM_WKDEP_DSP: CORE, MPU, WKUP */ @@ -168,6 +170,8 @@ static struct clkdm_dep core_24xx_wkdeps[] = { { NULL }, }; +#endif + /* 2430-specific possible wakeup dependencies */ ^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 2/4] OMAP2/3: clockdomains: remove warnings on an OMAP3-only compile 2011-02-26 0:20 ` [PATCH 2/4] OMAP2/3: clockdomains: remove warnings on an OMAP3-only compile Paul Walmsley @ 2011-03-01 0:17 ` Paul Walmsley 0 siblings, 0 replies; 6+ messages in thread From: Paul Walmsley @ 2011-03-01 0:17 UTC (permalink / raw) To: linux-arm-kernel On Fri, 25 Feb 2011, Paul Walmsley wrote: > Resolve these compile-time gcc warnings on OMAP3-only kernel compiles: > > .../mach-omap2/clockdomains2xxx_3xxx_data.c:95: warning: 'dsp_24xx_wkdeps' defined but not used > .../mach-omap2/clockdomains2xxx_3xxx_data.c:119: warning: 'mpu_24xx_wkdeps' defined but not used > .../mach-omap2/clockdomains2xxx_3xxx_data.c:147: warning: 'core_24xx_wkdeps' defined but not used > > Signed-off-by: Paul Walmsley <paul@pwsan.com> > --- > arch/arm/mach-omap2/clockdomains2xxx_3xxx_data.c | 4 ++++ > 1 files changed, 4 insertions(+), 0 deletions(-) For the archives, I've dropped this patch and replaced it with Sanjeev's patch here: http://marc.info/?l=linux-omap&m=129893821929982&w=2 - Paul ^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH 3/4] OMAP2xxx: clock: fix clockdomains on gpt7_ick, 2430 mmchs2_fck clocks 2011-02-26 0:20 [PATCH 0/4] OMAP2/3: clock/clockdomains: miscellaneous fixes Paul Walmsley 2011-02-26 0:20 ` [PATCH 1/4] OMAP2xxx: clock: remove dsp_irate_ick Paul Walmsley 2011-02-26 0:20 ` [PATCH 2/4] OMAP2/3: clockdomains: remove warnings on an OMAP3-only compile Paul Walmsley @ 2011-02-26 0:20 ` Paul Walmsley 2011-02-26 0:20 ` [PATCH 4/4] OMAP2xxx: clock data: clean up some comments Paul Walmsley 3 siblings, 0 replies; 6+ messages in thread From: Paul Walmsley @ 2011-02-26 0:20 UTC (permalink / raw) To: linux-arm-kernel Add a clockdomain to the GPTIMER7 interface and 2430 HSMMC2 functional clocks - both were previously missing them. Also, the 2430 mmchs1_fck is in core_l3_clkdm, but should be in core_l4_clkdm; fix this. Signed-off-by: Paul Walmsley <paul@pwsan.com> --- arch/arm/mach-omap2/clock2420_data.c | 1 + arch/arm/mach-omap2/clock2430_data.c | 4 +++- 2 files changed, 4 insertions(+), 1 deletions(-) diff --git a/arch/arm/mach-omap2/clock2420_data.c b/arch/arm/mach-omap2/clock2420_data.c index 53bd999..5e80d3d 100644 --- a/arch/arm/mach-omap2/clock2420_data.c +++ b/arch/arm/mach-omap2/clock2420_data.c @@ -987,6 +987,7 @@ static struct clk gpt7_ick = { .name = "gpt7_ick", .ops = &clkops_omap2_iclk_dflt_wait, .parent = &l4_ck, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_GPT7_SHIFT, .recalc = &followparent_recalc, diff --git a/arch/arm/mach-omap2/clock2430_data.c b/arch/arm/mach-omap2/clock2430_data.c index 36dde26..8957fc6 100644 --- a/arch/arm/mach-omap2/clock2430_data.c +++ b/arch/arm/mach-omap2/clock2430_data.c @@ -975,6 +975,7 @@ static struct clk gpt7_ick = { .name = "gpt7_ick", .ops = &clkops_omap2_iclk_dflt_wait, .parent = &l4_ck, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_GPT7_SHIFT, .recalc = &followparent_recalc, @@ -1747,7 +1748,7 @@ static struct clk mmchs1_fck = { .name = "mmchs1_fck", .ops = &clkops_omap2_dflt_wait, .parent = &func_96m_ck, - .clkdm_name = "core_l3_clkdm", + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_FCLKEN2), .enable_bit = OMAP2430_EN_MMCHS1_SHIFT, .recalc = &followparent_recalc, @@ -1767,6 +1768,7 @@ static struct clk mmchs2_fck = { .name = "mmchs2_fck", .ops = &clkops_omap2_dflt_wait, .parent = &func_96m_ck, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_FCLKEN2), .enable_bit = OMAP2430_EN_MMCHS2_SHIFT, .recalc = &followparent_recalc, ^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 4/4] OMAP2xxx: clock data: clean up some comments 2011-02-26 0:20 [PATCH 0/4] OMAP2/3: clock/clockdomains: miscellaneous fixes Paul Walmsley ` (2 preceding siblings ...) 2011-02-26 0:20 ` [PATCH 3/4] OMAP2xxx: clock: fix clockdomains on gpt7_ick, 2430 mmchs2_fck clocks Paul Walmsley @ 2011-02-26 0:20 ` Paul Walmsley 3 siblings, 0 replies; 6+ messages in thread From: Paul Walmsley @ 2011-02-26 0:20 UTC (permalink / raw) To: linux-arm-kernel Minor cleanup of some clock data comments. No functional changes. Signed-off-by: Paul Walmsley <paul@pwsan.com> --- arch/arm/mach-omap2/clock2420_data.c | 23 ++++++++++------------- arch/arm/mach-omap2/clock2430_data.c | 23 ++++++++++------------- 2 files changed, 20 insertions(+), 26 deletions(-) diff --git a/arch/arm/mach-omap2/clock2420_data.c b/arch/arm/mach-omap2/clock2420_data.c index 5e80d3d..b6f65d4 100644 --- a/arch/arm/mach-omap2/clock2420_data.c +++ b/arch/arm/mach-omap2/clock2420_data.c @@ -1,12 +1,12 @@ /* - * linux/arch/arm/mach-omap2/clock2420_data.c + * OMAP2420 clock data * - * Copyright (C) 2005-2009 Texas Instruments, Inc. - * Copyright (C) 2004-2011 Nokia Corporation + * Copyright (C) 2005-2009 Texas Instruments, Inc. + * Copyright (C) 2004-2011 Nokia Corporation * - * Contacts: - * Richard Woodruff <r-woodruff2@ti.com> - * Paul Walmsley + * Contacts: + * Richard Woodruff <r-woodruff2@ti.com> + * Paul Walmsley * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 as @@ -34,18 +34,15 @@ /* * 2420 clock tree. * - * NOTE:In many cases here we are assigning a 'default' parent. In many - * cases the parent is selectable. The get/set parent calls will also - * switch sources. - * - * Many some clocks say always_enabled, but they can be auto idled for - * power savings. They will always be available upon clock request. + * NOTE:In many cases here we are assigning a 'default' parent. In + * many cases the parent is selectable. The set parent calls will + * also switch sources. * * Several sources are given initial rates which may be wrong, this will * be fixed up in the init func. * * Things are broadly separated below by clock domains. It is - * noteworthy that most periferals have dependencies on multiple clock + * noteworthy that most peripherals have dependencies on multiple clock * domains. Many get their interface clocks from the L4 domain, but get * functional clocks from fixed sources or other core domain derived * clocks. diff --git a/arch/arm/mach-omap2/clock2430_data.c b/arch/arm/mach-omap2/clock2430_data.c index 8957fc6..5c2a075 100644 --- a/arch/arm/mach-omap2/clock2430_data.c +++ b/arch/arm/mach-omap2/clock2430_data.c @@ -1,12 +1,12 @@ /* - * linux/arch/arm/mach-omap2/clock2430_data.c + * OMAP2430 clock data * - * Copyright (C) 2005-2009 Texas Instruments, Inc. - * Copyright (C) 2004-2011 Nokia Corporation + * Copyright (C) 2005-2009 Texas Instruments, Inc. + * Copyright (C) 2004-2011 Nokia Corporation * - * Contacts: - * Richard Woodruff <r-woodruff2@ti.com> - * Paul Walmsley + * Contacts: + * Richard Woodruff <r-woodruff2@ti.com> + * Paul Walmsley * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 as @@ -34,18 +34,15 @@ /* * 2430 clock tree. * - * NOTE:In many cases here we are assigning a 'default' parent. In many - * cases the parent is selectable. The get/set parent calls will also - * switch sources. - * - * Many some clocks say always_enabled, but they can be auto idled for - * power savings. They will always be available upon clock request. + * NOTE:In many cases here we are assigning a 'default' parent. In + * many cases the parent is selectable. The set parent calls will + * also switch sources. * * Several sources are given initial rates which may be wrong, this will * be fixed up in the init func. * * Things are broadly separated below by clock domains. It is - * noteworthy that most periferals have dependencies on multiple clock + * noteworthy that most peripherals have dependencies on multiple clock * domains. Many get their interface clocks from the L4 domain, but get * functional clocks from fixed sources or other core domain derived * clocks. ^ permalink raw reply related [flat|nested] 6+ messages in thread
end of thread, other threads:[~2011-03-01 0:17 UTC | newest] Thread overview: 6+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2011-02-26 0:20 [PATCH 0/4] OMAP2/3: clock/clockdomains: miscellaneous fixes Paul Walmsley 2011-02-26 0:20 ` [PATCH 1/4] OMAP2xxx: clock: remove dsp_irate_ick Paul Walmsley 2011-02-26 0:20 ` [PATCH 2/4] OMAP2/3: clockdomains: remove warnings on an OMAP3-only compile Paul Walmsley 2011-03-01 0:17 ` Paul Walmsley 2011-02-26 0:20 ` [PATCH 3/4] OMAP2xxx: clock: fix clockdomains on gpt7_ick, 2430 mmchs2_fck clocks Paul Walmsley 2011-02-26 0:20 ` [PATCH 4/4] OMAP2xxx: clock data: clean up some comments Paul Walmsley
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox