* [PATCH 0/4] ARM: OMAP2+: Misc cleanup part2
@ 2012-05-10 17:06 R Sricharan
2012-05-10 17:06 ` [PATCH 1/4] ARM: OMAP2+: Introduce CONFIG_SOC_HAS_OMAP_DPLL macro R Sricharan
` (4 more replies)
0 siblings, 5 replies; 16+ messages in thread
From: R Sricharan @ 2012-05-10 17:06 UTC (permalink / raw)
To: linux-arm-kernel
This is a continuation of the previous cleanup series from
santosh.shilimkar at ti.com [1]. Patches are outcome of the OMAP5
review suggestions from Tony/Benoit/Santosh/Rajendra.
[1] http://www.spinics.net/lists/linux-omap/msg69730.html
R Sricharan (4):
ARM: OMAP2+: Introduce CONFIG_SOC_HAS_OMAP_DPLL macro
ARM: OMAP2+: Move the stubbed prm and cm functions to prcm.c file and
make them __weak.
ARM: OMAP2+: Move stubbed secure_sram_reserve function to a common.c
and call it __weak
ARM: OMAP: counter-32k: Select the CR register offset using the IP
scheme.
arch/arm/mach-omap2/Kconfig | 5 ++
arch/arm/mach-omap2/clock.c | 2 +-
arch/arm/mach-omap2/cminst44xx.h | 25 --------
arch/arm/mach-omap2/prcm.c | 77 +++++++++++++++++++++++++
arch/arm/mach-omap2/prm2xxx_3xxx.h | 65 ---------------------
arch/arm/plat-omap/common.c | 9 +++
arch/arm/plat-omap/counter_32k.c | 16 ++++-
arch/arm/plat-omap/include/plat/clock.h | 4 +-
arch/arm/plat-omap/include/plat/omap-secure.h | 5 --
9 files changed, 107 insertions(+), 101 deletions(-)
^ permalink raw reply [flat|nested] 16+ messages in thread
* [PATCH 1/4] ARM: OMAP2+: Introduce CONFIG_SOC_HAS_OMAP_DPLL macro
2012-05-10 17:06 [PATCH 0/4] ARM: OMAP2+: Misc cleanup part2 R Sricharan
@ 2012-05-10 17:06 ` R Sricharan
2012-05-10 18:26 ` Hiremath, Vaibhav
2012-05-10 17:06 ` [PATCH 2/4] ARM: OMAP2+: Move the stubbed prm and cm functions to prcm.c file and make them __weak R Sricharan
` (3 subsequent siblings)
4 siblings, 1 reply; 16+ messages in thread
From: R Sricharan @ 2012-05-10 17:06 UTC (permalink / raw)
To: linux-arm-kernel
The DPLL ip was introduced and used in the OMAP3PLUS socs, while
OMAP2 had the APLL IP. There are some features which are common
to both ips, and some which are only applicable to DPLL ip's.
Currently CONFIG_ARCH_OMAP_XXX checks is used to conditionally
compile the additional features for every applicable SOC. This
makes it nessecary to add new a check for every new SOC added
in the future.
So by introducing a new "SOC_HAS_OMAP_DPLL" config such new #ifdefs
can be avoided for the future socs and also to cleanup the existing
ifdefferies.
Signed-off-by: R Sricharan <r.sricharan@ti.com>
---
arch/arm/mach-omap2/Kconfig | 5 +++++
arch/arm/mach-omap2/clock.c | 2 +-
arch/arm/plat-omap/include/plat/clock.h | 4 ++--
3 files changed, 8 insertions(+), 3 deletions(-)
diff --git a/arch/arm/mach-omap2/Kconfig b/arch/arm/mach-omap2/Kconfig
index 0685dc8..9a8d691 100644
--- a/arch/arm/mach-omap2/Kconfig
+++ b/arch/arm/mach-omap2/Kconfig
@@ -27,9 +27,13 @@ config ARCH_OMAP2
select CPU_V6
select MULTI_IRQ_HANDLER
+config SOC_HAS_OMAP_DPLL
+ bool
+
config ARCH_OMAP3
bool "TI OMAP3"
depends on ARCH_OMAP2PLUS
+ select SOC_HAS_OMAP_DPLL
default y
select CPU_V7
select USB_ARCH_HAS_EHCI if USB_SUPPORT
@@ -42,6 +46,7 @@ config ARCH_OMAP4
bool "TI OMAP4"
default y
depends on ARCH_OMAP2PLUS
+ select SOC_HAS_OMAP_DPLL
select CACHE_L2X0
select CPU_V7
select ARM_GIC
diff --git a/arch/arm/mach-omap2/clock.c b/arch/arm/mach-omap2/clock.c
index d9f4931..629cd2d 100644
--- a/arch/arm/mach-omap2/clock.c
+++ b/arch/arm/mach-omap2/clock.c
@@ -400,7 +400,7 @@ int omap2_clk_set_parent(struct clk *clk, struct clk *new_parent)
/* OMAP3/4 non-CORE DPLL clkops */
-#if defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_ARCH_OMAP4)
+#ifdef CONFIG_SOC_HAS_OMAP_DPLL
const struct clkops clkops_omap3_noncore_dpll_ops = {
.enable = omap3_noncore_dpll_enable,
diff --git a/arch/arm/plat-omap/include/plat/clock.h b/arch/arm/plat-omap/include/plat/clock.h
index d0ef57c..095bee8 100644
--- a/arch/arm/plat-omap/include/plat/clock.h
+++ b/arch/arm/plat-omap/include/plat/clock.h
@@ -156,7 +156,7 @@ struct dpll_data {
u8 min_divider;
u16 max_divider;
u8 modes;
-#if defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_ARCH_OMAP4)
+#ifdef CONFIG_SOC_HAS_OMAP_DPLL
void __iomem *autoidle_reg;
void __iomem *idlest_reg;
u32 autoidle_mask;
@@ -167,7 +167,7 @@ struct dpll_data {
u8 auto_recal_bit;
u8 recal_en_bit;
u8 recal_st_bit;
-# endif
+#endif
u8 flags;
};
--
1.7.1
^ permalink raw reply related [flat|nested] 16+ messages in thread
* [PATCH 2/4] ARM: OMAP2+: Move the stubbed prm and cm functions to prcm.c file and make them __weak.
2012-05-10 17:06 [PATCH 0/4] ARM: OMAP2+: Misc cleanup part2 R Sricharan
2012-05-10 17:06 ` [PATCH 1/4] ARM: OMAP2+: Introduce CONFIG_SOC_HAS_OMAP_DPLL macro R Sricharan
@ 2012-05-10 17:06 ` R Sricharan
2012-05-10 17:41 ` Paul Walmsley
2012-05-10 17:06 ` [PATCH 3/4] ARM: OMAP2+: Move stubbed secure_sram_reserve function to a common.c and call it __weak R Sricharan
` (2 subsequent siblings)
4 siblings, 1 reply; 16+ messages in thread
From: R Sricharan @ 2012-05-10 17:06 UTC (permalink / raw)
To: linux-arm-kernel
Some prm and cm registers read/write and status functions
are built only for some custom OMAP2+ builds and are stubbed
in header files for other builds under ifdef statements.
But this results in adding new CONFIG_ARCH_OMAPXXX
checks when SOCs are added in the future. So move them
to a common place for OMAP2+ and make them 'weak' implementations.
This way no new ifdefs would be required in the future and also
cleans up the existing code.
Signed-off-by: R Sricharan <r.sricharan@ti.com>
---
arch/arm/mach-omap2/cminst44xx.h | 25 ------------
arch/arm/mach-omap2/prcm.c | 77 ++++++++++++++++++++++++++++++++++++
arch/arm/mach-omap2/prm2xxx_3xxx.h | 65 ------------------------------
3 files changed, 77 insertions(+), 90 deletions(-)
diff --git a/arch/arm/mach-omap2/cminst44xx.h b/arch/arm/mach-omap2/cminst44xx.h
index a018a73..d69fdef 100644
--- a/arch/arm/mach-omap2/cminst44xx.h
+++ b/arch/arm/mach-omap2/cminst44xx.h
@@ -16,38 +16,13 @@ extern void omap4_cminst_clkdm_enable_hwsup(u8 part, s16 inst, u16 cdoffs);
extern void omap4_cminst_clkdm_disable_hwsup(u8 part, s16 inst, u16 cdoffs);
extern void omap4_cminst_clkdm_force_sleep(u8 part, s16 inst, u16 cdoffs);
extern void omap4_cminst_clkdm_force_wakeup(u8 part, s16 inst, u16 cdoffs);
-
extern int omap4_cminst_wait_module_ready(u8 part, u16 inst, s16 cdoffs, u16 clkctrl_offs);
-
-# ifdef CONFIG_ARCH_OMAP4
extern int omap4_cminst_wait_module_idle(u8 part, u16 inst, s16 cdoffs,
u16 clkctrl_offs);
-
extern void omap4_cminst_module_enable(u8 mode, u8 part, u16 inst, s16 cdoffs,
u16 clkctrl_offs);
extern void omap4_cminst_module_disable(u8 part, u16 inst, s16 cdoffs,
u16 clkctrl_offs);
-
-# else
-
-static inline int omap4_cminst_wait_module_idle(u8 part, u16 inst, s16 cdoffs,
- u16 clkctrl_offs)
-{
- return 0;
-}
-
-static inline void omap4_cminst_module_enable(u8 mode, u8 part, u16 inst,
- s16 cdoffs, u16 clkctrl_offs)
-{
-}
-
-static inline void omap4_cminst_module_disable(u8 part, u16 inst, s16 cdoffs,
- u16 clkctrl_offs)
-{
-}
-
-# endif
-
/*
* In an ideal world, we would not export these low-level functions,
* but this will probably take some time to fix properly
diff --git a/arch/arm/mach-omap2/prcm.c b/arch/arm/mach-omap2/prcm.c
index 480f40a..9bc3f5d 100644
--- a/arch/arm/mach-omap2/prcm.c
+++ b/arch/arm/mach-omap2/prcm.c
@@ -164,3 +164,80 @@ void __init omap2_set_globals_prcm(struct omap_globals *omap2_globals)
omap_cm_base_init();
}
}
+
+/*
+ * Stubbed functions so that common files
+ * continue to build when custom builds are used
+ */
+u32 __weak omap2_prm_read_mod_reg(s16 module, u16 idx)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function and "
+ "not suppose to be used on omap4\n");
+ return 0;
+}
+
+void __weak omap2_prm_write_mod_reg(u32 val, s16 module, u16 idx)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function and "
+ "not suppose to be used on omap4\n");
+}
+u32 __weak omap2_prm_rmw_mod_reg_bits(u32 mask, u32 bits,
+ s16 module, s16 idx)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function and "
+ "not suppose to be used on omap4\n");
+ return 0;
+}
+u32 __weak omap2_prm_set_mod_reg_bits(u32 bits, s16 module, s16 idx)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function and "
+ "not suppose to be used on omap4\n");
+ return 0;
+}
+u32 __weak omap2_prm_clear_mod_reg_bits(u32 bits, s16 module, s16 idx)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function and "
+ "not suppose to be used on omap4\n");
+ return 0;
+}
+u32 __weak omap2_prm_read_mod_bits_shift(s16 domain, s16 idx, u32 mask)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function and "
+ "not suppose to be used on omap4\n");
+ return 0;
+}
+int __weak omap2_prm_is_hardreset_asserted(s16 prm_mod, u8 shift)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function and "
+ "not suppose to be used on omap4\n");
+ return 0;
+}
+int __weak omap2_prm_assert_hardreset(s16 prm_mod, u8 shift)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function and "
+ "not suppose to be used on omap4\n");
+ return 0;
+}
+int __weak omap2_prm_deassert_hardreset(s16 prm_mod, u8 rst_shift,
+ u8 st_shift)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function and "
+ "not suppose to be used on omap4\n");
+ return 0;
+}
+
+int __weak omap4_cminst_wait_module_idle(u8 part, u16 inst, s16 cdoffs,
+ u16 clkctrl_offs)
+{
+ return 0;
+}
+
+void __weak omap4_cminst_module_enable(u8 mode, u8 part, u16 inst,
+ s16 cdoffs, u16 clkctrl_offs)
+{
+}
+
+void __weak omap4_cminst_module_disable(u8 part, u16 inst, s16 cdoffs,
+ u16 clkctrl_offs)
+{
+}
diff --git a/arch/arm/mach-omap2/prm2xxx_3xxx.h b/arch/arm/mach-omap2/prm2xxx_3xxx.h
index 70ac2a1..f7bb57f 100644
--- a/arch/arm/mach-omap2/prm2xxx_3xxx.h
+++ b/arch/arm/mach-omap2/prm2xxx_3xxx.h
@@ -228,68 +228,6 @@
#ifndef __ASSEMBLER__
-/*
- * Stub omap2xxx/omap3xxx functions so that common files
- * continue to build when custom builds are used
- */
-#if defined(CONFIG_ARCH_OMAP4) && !(defined(CONFIG_ARCH_OMAP2) || \
- defined(CONFIG_ARCH_OMAP3))
-static inline u32 omap2_prm_read_mod_reg(s16 module, u16 idx)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
- return 0;
-}
-static inline void omap2_prm_write_mod_reg(u32 val, s16 module, u16 idx)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
-}
-static inline u32 omap2_prm_rmw_mod_reg_bits(u32 mask, u32 bits,
- s16 module, s16 idx)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
- return 0;
-}
-static inline u32 omap2_prm_set_mod_reg_bits(u32 bits, s16 module, s16 idx)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
- return 0;
-}
-static inline u32 omap2_prm_clear_mod_reg_bits(u32 bits, s16 module, s16 idx)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
- return 0;
-}
-static inline u32 omap2_prm_read_mod_bits_shift(s16 domain, s16 idx, u32 mask)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
- return 0;
-}
-static inline int omap2_prm_is_hardreset_asserted(s16 prm_mod, u8 shift)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
- return 0;
-}
-static inline int omap2_prm_assert_hardreset(s16 prm_mod, u8 shift)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
- return 0;
-}
-static inline int omap2_prm_deassert_hardreset(s16 prm_mod, u8 rst_shift,
- u8 st_shift)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
- return 0;
-}
-#else
/* Power/reset management domain register get/set */
extern u32 omap2_prm_read_mod_reg(s16 module, u16 idx);
extern void omap2_prm_write_mod_reg(u32 val, s16 module, u16 idx);
@@ -320,9 +258,6 @@ extern void omap3xxx_prm_read_pending_irqs(unsigned long *events);
extern void omap3xxx_prm_ocp_barrier(void);
extern void omap3xxx_prm_save_and_clear_irqen(u32 *saved_mask);
extern void omap3xxx_prm_restore_irqen(u32 *saved_mask);
-
-#endif /* CONFIG_ARCH_OMAP4 */
-
#endif
/*
--
1.7.1
^ permalink raw reply related [flat|nested] 16+ messages in thread
* [PATCH 3/4] ARM: OMAP2+: Move stubbed secure_sram_reserve function to a common.c and call it __weak
2012-05-10 17:06 [PATCH 0/4] ARM: OMAP2+: Misc cleanup part2 R Sricharan
2012-05-10 17:06 ` [PATCH 1/4] ARM: OMAP2+: Introduce CONFIG_SOC_HAS_OMAP_DPLL macro R Sricharan
2012-05-10 17:06 ` [PATCH 2/4] ARM: OMAP2+: Move the stubbed prm and cm functions to prcm.c file and make them __weak R Sricharan
@ 2012-05-10 17:06 ` R Sricharan
2012-05-10 17:06 ` [PATCH 4/4] ARM: OMAP: counter-32k: Select the CR register offset using the IP scheme R Sricharan
2012-05-10 17:17 ` [PATCH 0/4] ARM: OMAP2+: Misc cleanup part2 Sricharan R
4 siblings, 0 replies; 16+ messages in thread
From: R Sricharan @ 2012-05-10 17:06 UTC (permalink / raw)
To: linux-arm-kernel
omap_secure_ram_reserve_memblock is stubbed for OMAP1,2 only builds using a
ifdef check. But this results in adding CONFIG_ARCH_OMAPxx checks for
future socs that use the real function. So move this to common.c file and
call it __weak.
Signed-off-by: R Sricharan <r.sricharan@ti.com>
---
arch/arm/plat-omap/common.c | 9 +++++++++
arch/arm/plat-omap/include/plat/omap-secure.h | 5 -----
2 files changed, 9 insertions(+), 5 deletions(-)
diff --git a/arch/arm/plat-omap/common.c b/arch/arm/plat-omap/common.c
index 0a9b9a9..89a3723 100644
--- a/arch/arm/plat-omap/common.c
+++ b/arch/arm/plat-omap/common.c
@@ -77,3 +77,12 @@ void __init omap_init_consistent_dma_size(void)
init_consistent_dma_size(CONFIG_FB_OMAP_CONSISTENT_DMA_SIZE << 20);
#endif
}
+
+/*
+ * Stub function for OMAP2 so that common files
+ * continue to build when custom builds are used
+ */
+int __weak omap_secure_ram_reserve_memblock(void)
+{
+ return 0;
+}
diff --git a/arch/arm/plat-omap/include/plat/omap-secure.h b/arch/arm/plat-omap/include/plat/omap-secure.h
index 8c7994c..0e4acd2 100644
--- a/arch/arm/plat-omap/include/plat/omap-secure.h
+++ b/arch/arm/plat-omap/include/plat/omap-secure.h
@@ -3,12 +3,7 @@
#include <linux/types.h>
-#if defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_ARCH_OMAP4)
extern int omap_secure_ram_reserve_memblock(void);
-#else
-static inline void omap_secure_ram_reserve_memblock(void)
-{ }
-#endif
#ifdef CONFIG_OMAP4_ERRATA_I688
extern int omap_barrier_reserve_memblock(void);
--
1.7.1
^ permalink raw reply related [flat|nested] 16+ messages in thread
* [PATCH 4/4] ARM: OMAP: counter-32k: Select the CR register offset using the IP scheme.
2012-05-10 17:06 [PATCH 0/4] ARM: OMAP2+: Misc cleanup part2 R Sricharan
` (2 preceding siblings ...)
2012-05-10 17:06 ` [PATCH 3/4] ARM: OMAP2+: Move stubbed secure_sram_reserve function to a common.c and call it __weak R Sricharan
@ 2012-05-10 17:06 ` R Sricharan
2012-05-10 17:17 ` [PATCH 0/4] ARM: OMAP2+: Misc cleanup part2 Sricharan R
4 siblings, 0 replies; 16+ messages in thread
From: R Sricharan @ 2012-05-10 17:06 UTC (permalink / raw)
To: linux-arm-kernel
OMAP socs has a legacy and a highlander version of the
32k sync counter IP. The register offsets vary between the
highlander and the legacy scheme. So use the 'SCHEME'
bits(30-31) of the revision register to distinguish between
the two versions and choose the CR register offset accordingly.
Signed-off-by: R Sricharan <r.sricharan@ti.com>
---
arch/arm/plat-omap/counter_32k.c | 16 +++++++++++++---
1 files changed, 13 insertions(+), 3 deletions(-)
diff --git a/arch/arm/plat-omap/counter_32k.c b/arch/arm/plat-omap/counter_32k.c
index b2f634b..cbd939d 100644
--- a/arch/arm/plat-omap/counter_32k.c
+++ b/arch/arm/plat-omap/counter_32k.c
@@ -28,7 +28,10 @@
#include <plat/clock.h>
/* OMAP2_32KSYNCNT_CR_OFF: offset of 32ksync counter register */
-#define OMAP2_32KSYNCNT_CR_OFF 0x10
+#define OMAP2_32KSYNCNT_REV_OFF 0x0
+#define OMAP2_32KSYNCNT_REV_SCHEME (0x3 << 30)
+#define OMAP2_32KSYNCNT_CR_OFF_LOW 0x10
+#define OMAP2_32KSYNCNT_CR_OFF_HIGH 0x30
/*
* 32KHz clocksource ... always available, on pretty most chips except
@@ -83,9 +86,16 @@ int __init omap_init_clocksource_32k(void __iomem *vbase)
int ret;
/*
- * 32k sync Counter register offset is@0x10
+ * 32k sync Counter IP register offsets vary between the
+ * highlander version and the legacy ones.
+ * The 'SCHEME' bits(30-31) of the revision register is used
+ * to identify the version.
*/
- sync32k_cnt_reg = vbase + OMAP2_32KSYNCNT_CR_OFF;
+ if (__raw_readl(vbase + OMAP2_32KSYNCNT_REV_OFF) &
+ OMAP2_32KSYNCNT_REV_SCHEME)
+ sync32k_cnt_reg = vbase + OMAP2_32KSYNCNT_CR_OFF_HIGH;
+ else
+ sync32k_cnt_reg = vbase + OMAP2_32KSYNCNT_CR_OFF_LOW;
/*
* 120000 rough estimate from the calculations in
--
1.7.1
^ permalink raw reply related [flat|nested] 16+ messages in thread
* [PATCH 0/4] ARM: OMAP2+: Misc cleanup part2
2012-05-10 17:06 [PATCH 0/4] ARM: OMAP2+: Misc cleanup part2 R Sricharan
` (3 preceding siblings ...)
2012-05-10 17:06 ` [PATCH 4/4] ARM: OMAP: counter-32k: Select the CR register offset using the IP scheme R Sricharan
@ 2012-05-10 17:17 ` Sricharan R
4 siblings, 0 replies; 16+ messages in thread
From: Sricharan R @ 2012-05-10 17:17 UTC (permalink / raw)
To: linux-arm-kernel
> -----Original Message-----
> From: R Sricharan [mailto:r.sricharan at ti.com]
> Sent: Thursday, May 10, 2012 10:37 PM
> To: linux-omap at vger.kernel.org
> Cc: linux-arm-kernel at lists.infradead.org; santosh.shilimkar at ti.com;
> tony at atomide.com; b-cousson at ti.com; r.sricharan at ti.com; paul at pswan.com
> Subject: [PATCH 0/4] ARM: OMAP2+: Misc cleanup part2
>
> This is a continuation of the previous cleanup series from
> santosh.shilimkar at ti.com [1]. Patches are outcome of the OMAP5
> review suggestions from Tony/Benoit/Santosh/Rajendra.
>
> [1] http://www.spinics.net/lists/linux-omap/msg69730.html
>
> R Sricharan (4):
> ARM: OMAP2+: Introduce CONFIG_SOC_HAS_OMAP_DPLL macro
> ARM: OMAP2+: Move the stubbed prm and cm functions to prcm.c file and
> make them __weak.
> ARM: OMAP2+: Move stubbed secure_sram_reserve function to a common.c
> and call it __weak
> ARM: OMAP: counter-32k: Select the CR register offset using the IP
> scheme.
>
Forgot to add the below reviewed-by tag.
Reviewed-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Thanks,
Sricharan
^ permalink raw reply [flat|nested] 16+ messages in thread
* [PATCH 2/4] ARM: OMAP2+: Move the stubbed prm and cm functions to prcm.c file and make them __weak.
2012-05-10 17:06 ` [PATCH 2/4] ARM: OMAP2+: Move the stubbed prm and cm functions to prcm.c file and make them __weak R Sricharan
@ 2012-05-10 17:41 ` Paul Walmsley
2012-05-10 17:44 ` Sricharan R
2012-06-14 11:56 ` R, Sricharan
0 siblings, 2 replies; 16+ messages in thread
From: Paul Walmsley @ 2012-05-10 17:41 UTC (permalink / raw)
To: linux-arm-kernel
Hi
On Thu, 10 May 2012, R Sricharan wrote:
> Some prm and cm registers read/write and status functions
> are built only for some custom OMAP2+ builds and are stubbed
> in header files for other builds under ifdef statements.
> But this results in adding new CONFIG_ARCH_OMAPXXX
> checks when SOCs are added in the future. So move them
> to a common place for OMAP2+ and make them 'weak' implementations.
Thanks for the patch. These stubs aren't needed any longer, so we can
just get rid of them; no need to mark them __weak. I've got a patch to
just drop them here to be posted soon as part of a larger PRCM cleanup.
- Paul
^ permalink raw reply [flat|nested] 16+ messages in thread
* [PATCH 2/4] ARM: OMAP2+: Move the stubbed prm and cm functions to prcm.c file and make them __weak.
2012-05-10 17:41 ` Paul Walmsley
@ 2012-05-10 17:44 ` Sricharan R
2012-06-14 11:56 ` R, Sricharan
1 sibling, 0 replies; 16+ messages in thread
From: Sricharan R @ 2012-05-10 17:44 UTC (permalink / raw)
To: linux-arm-kernel
Hi Paul,
>
> On Thu, 10 May 2012, R Sricharan wrote:
>
> > Some prm and cm registers read/write and status functions
> > are built only for some custom OMAP2+ builds and are stubbed
> > in header files for other builds under ifdef statements.
> > But this results in adding new CONFIG_ARCH_OMAPXXX
> > checks when SOCs are added in the future. So move them
> > to a common place for OMAP2+ and make them 'weak' implementations.
>
> Thanks for the patch. These stubs aren't needed any longer, so we can
> just get rid of them; no need to mark them __weak. I've got a patch to
> just drop them here to be posted soon as part of a larger PRCM cleanup.
>
Thanks. I will pick up your series.
Thanks,
Sricharan
^ permalink raw reply [flat|nested] 16+ messages in thread
* [PATCH 1/4] ARM: OMAP2+: Introduce CONFIG_SOC_HAS_OMAP_DPLL macro
2012-05-10 17:06 ` [PATCH 1/4] ARM: OMAP2+: Introduce CONFIG_SOC_HAS_OMAP_DPLL macro R Sricharan
@ 2012-05-10 18:26 ` Hiremath, Vaibhav
2012-05-11 6:16 ` R, Sricharan
0 siblings, 1 reply; 16+ messages in thread
From: Hiremath, Vaibhav @ 2012-05-10 18:26 UTC (permalink / raw)
To: linux-arm-kernel
On Thu, May 10, 2012 at 22:36:52, R, Sricharan wrote:
> The DPLL ip was introduced and used in the OMAP3PLUS socs, while
> OMAP2 had the APLL IP. There are some features which are common
> to both ips, and some which are only applicable to DPLL ip's.
> Currently CONFIG_ARCH_OMAP_XXX checks is used to conditionally
> compile the additional features for every applicable SOC. This
> makes it nessecary to add new a check for every new SOC added
> in the future.
>
> So by introducing a new "SOC_HAS_OMAP_DPLL" config such new #ifdefs
> can be avoided for the future socs and also to cleanup the existing
> ifdefferies.
>
> Signed-off-by: R Sricharan <r.sricharan@ti.com>
> ---
> arch/arm/mach-omap2/Kconfig | 5 +++++
> arch/arm/mach-omap2/clock.c | 2 +-
> arch/arm/plat-omap/include/plat/clock.h | 4 ++--
> 3 files changed, 8 insertions(+), 3 deletions(-)
>
> diff --git a/arch/arm/mach-omap2/Kconfig b/arch/arm/mach-omap2/Kconfig
> index 0685dc8..9a8d691 100644
> --- a/arch/arm/mach-omap2/Kconfig
> +++ b/arch/arm/mach-omap2/Kconfig
> @@ -27,9 +27,13 @@ config ARCH_OMAP2
> select CPU_V6
> select MULTI_IRQ_HANDLER
>
> +config SOC_HAS_OMAP_DPLL
> + bool
> +
> config ARCH_OMAP3
> bool "TI OMAP3"
> depends on ARCH_OMAP2PLUS
> + select SOC_HAS_OMAP_DPLL
> default y
> select CPU_V7
> select USB_ARCH_HAS_EHCI if USB_SUPPORT
> @@ -42,6 +46,7 @@ config ARCH_OMAP4
> bool "TI OMAP4"
> default y
> depends on ARCH_OMAP2PLUS
> + select SOC_HAS_OMAP_DPLL
> select CACHE_L2X0
> select CPU_V7
> select ARM_GIC
> diff --git a/arch/arm/mach-omap2/clock.c b/arch/arm/mach-omap2/clock.c
> index d9f4931..629cd2d 100644
> --- a/arch/arm/mach-omap2/clock.c
> +++ b/arch/arm/mach-omap2/clock.c
> @@ -400,7 +400,7 @@ int omap2_clk_set_parent(struct clk *clk, struct clk *new_parent)
>
> /* OMAP3/4 non-CORE DPLL clkops */
>
> -#if defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_ARCH_OMAP4)
> +#ifdef CONFIG_SOC_HAS_OMAP_DPLL
>
> const struct clkops clkops_omap3_noncore_dpll_ops = {
> .enable = omap3_noncore_dpll_enable,
> diff --git a/arch/arm/plat-omap/include/plat/clock.h b/arch/arm/plat-omap/include/plat/clock.h
> index d0ef57c..095bee8 100644
> --- a/arch/arm/plat-omap/include/plat/clock.h
> +++ b/arch/arm/plat-omap/include/plat/clock.h
> @@ -156,7 +156,7 @@ struct dpll_data {
> u8 min_divider;
> u16 max_divider;
> u8 modes;
> -#if defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_ARCH_OMAP4)
> +#ifdef CONFIG_SOC_HAS_OMAP_DPLL
> void __iomem *autoidle_reg;
> void __iomem *idlest_reg;
> u32 autoidle_mask;
> @@ -167,7 +167,7 @@ struct dpll_data {
> u8 auto_recal_bit;
> u8 recal_en_bit;
> u8 recal_st_bit;
> -# endif
> +#endif
I had submitted similar patch recently, and Kevin had suggested that
Instead of adding config option, we shoule simply get rid of this ifdef
completely.
Refer to
http://www.mail-archive.com/linux-omap at vger.kernel.org/msg68293.html
Waiting for Paul to conform here.
Thanks,
Vaibhav
^ permalink raw reply [flat|nested] 16+ messages in thread
* [PATCH 1/4] ARM: OMAP2+: Introduce CONFIG_SOC_HAS_OMAP_DPLL macro
2012-05-10 18:26 ` Hiremath, Vaibhav
@ 2012-05-11 6:16 ` R, Sricharan
2012-05-11 6:22 ` Hiremath, Vaibhav
0 siblings, 1 reply; 16+ messages in thread
From: R, Sricharan @ 2012-05-11 6:16 UTC (permalink / raw)
To: linux-arm-kernel
Vaibhav,
[snip]
>> diff --git a/arch/arm/plat-omap/include/plat/clock.h b/arch/arm/plat-omap/include/plat/clock.h
>> index d0ef57c..095bee8 100644
>> --- a/arch/arm/plat-omap/include/plat/clock.h
>> +++ b/arch/arm/plat-omap/include/plat/clock.h
>> @@ -156,7 +156,7 @@ struct dpll_data {
>> ? ? ? u8 ? ? ? ? ? ? ? ? ? ? ?min_divider;
>> ? ? ? u16 ? ? ? ? ? ? ? ? ? ? max_divider;
>> ? ? ? u8 ? ? ? ? ? ? ? ? ? ? ?modes;
>> -#if defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_ARCH_OMAP4)
>> +#ifdef CONFIG_SOC_HAS_OMAP_DPLL
>> ? ? ? void __iomem ? ? ? ? ? ?*autoidle_reg;
>> ? ? ? void __iomem ? ? ? ? ? ?*idlest_reg;
>> ? ? ? u32 ? ? ? ? ? ? ? ? ? ? autoidle_mask;
>> @@ -167,7 +167,7 @@ struct dpll_data {
>> ? ? ? u8 ? ? ? ? ? ? ? ? ? ? ?auto_recal_bit;
>> ? ? ? u8 ? ? ? ? ? ? ? ? ? ? ?recal_en_bit;
>> ? ? ? u8 ? ? ? ? ? ? ? ? ? ? ?recal_st_bit;
>> -# ?endif
>> +#endif
>
> I had submitted similar patch recently, and Kevin had suggested that
> Instead of adding config option, we shoule simply get rid of this ifdef
> completely.
>
> Refer to
> http://www.mail-archive.com/linux-omap at vger.kernel.org/msg68293.html
>
>
> Waiting for Paul to conform here.
>
Thanks for pointing that out. Will check on this and Paul's PRCM series
cleanup series then.
Thanks,
Sricharan
^ permalink raw reply [flat|nested] 16+ messages in thread
* [PATCH 1/4] ARM: OMAP2+: Introduce CONFIG_SOC_HAS_OMAP_DPLL macro
2012-05-11 6:16 ` R, Sricharan
@ 2012-05-11 6:22 ` Hiremath, Vaibhav
2012-05-11 6:23 ` R, Sricharan
0 siblings, 1 reply; 16+ messages in thread
From: Hiremath, Vaibhav @ 2012-05-11 6:22 UTC (permalink / raw)
To: linux-arm-kernel
On Fri, May 11, 2012 at 11:46:32, R, Sricharan wrote:
> Vaibhav,
> [snip]
> > Waiting for Paul to conform here.
> >
> Thanks for pointing that out. Will check on this and Paul's PRCM series
> cleanup series then.
>
Sricharan,
Yesterday, Paul confirmed that, removing ifdef is the way to go. So
just few mins back I had submitted patch for the same.
http://permalink.gmane.org/gmane.linux.ports.arm.omap/76972
Thanks,
Vaibhav
^ permalink raw reply [flat|nested] 16+ messages in thread
* [PATCH 1/4] ARM: OMAP2+: Introduce CONFIG_SOC_HAS_OMAP_DPLL macro
2012-05-11 6:22 ` Hiremath, Vaibhav
@ 2012-05-11 6:23 ` R, Sricharan
0 siblings, 0 replies; 16+ messages in thread
From: R, Sricharan @ 2012-05-11 6:23 UTC (permalink / raw)
To: linux-arm-kernel
Hi Vaibhav,
>
> Sricharan,
>
> Yesterday, Paul confirmed that, removing ifdef is the way to go. So
> just few mins back I had submitted patch for the same.
>
> http://permalink.gmane.org/gmane.linux.ports.arm.omap/76972
>
oh ya, was just looking at that.
Thanks,
Sricharan
^ permalink raw reply [flat|nested] 16+ messages in thread
* [PATCH 2/4] ARM: OMAP2+: Move the stubbed prm and cm functions to prcm.c file and make them __weak.
2012-05-10 17:41 ` Paul Walmsley
2012-05-10 17:44 ` Sricharan R
@ 2012-06-14 11:56 ` R, Sricharan
2012-06-28 11:58 ` R, Sricharan
1 sibling, 1 reply; 16+ messages in thread
From: R, Sricharan @ 2012-06-14 11:56 UTC (permalink / raw)
To: linux-arm-kernel
Hi Paul,
>> Some prm and cm registers read/write and status functions
>> are built only for some custom OMAP2+ builds and are stubbed
>> in header files for other builds under ifdef statements.
>> But this results in adding new CONFIG_ARCH_OMAPXXX
>> checks when SOCs are added in the future. So move them
>> to a common place for OMAP2+ and make them 'weak' implementations.
>
> Thanks for the patch. ?These stubs aren't needed any longer, so we can
> just get rid of them; no need to mark them __weak. ?I've got a patch to
> just drop them here to be posted soon as part of a larger PRCM cleanup.
>
>
Is the PRCM cleanup series available now ?
Thanks,
Sricharan
^ permalink raw reply [flat|nested] 16+ messages in thread
* [PATCH 2/4] ARM: OMAP2+: Move the stubbed prm and cm functions to prcm.c file and make them __weak.
2012-06-14 11:56 ` R, Sricharan
@ 2012-06-28 11:58 ` R, Sricharan
2012-07-04 15:19 ` Paul Walmsley
0 siblings, 1 reply; 16+ messages in thread
From: R, Sricharan @ 2012-06-28 11:58 UTC (permalink / raw)
To: linux-arm-kernel
Ping..
Thanks,
Sricharan
On Thu, Jun 14, 2012 at 5:26 PM, R, Sricharan <r.sricharan@ti.com> wrote:
> Hi Paul,
>
>>> Some prm and cm registers read/write and status functions
>>> are built only for some custom OMAP2+ builds and are stubbed
>>> in header files for other builds under ifdef statements.
>>> But this results in adding new CONFIG_ARCH_OMAPXXX
>>> checks when SOCs are added in the future. So move them
>>> to a common place for OMAP2+ and make them 'weak' implementations.
>>
>> Thanks for the patch. ?These stubs aren't needed any longer, so we can
>> just get rid of them; no need to mark them __weak. ?I've got a patch to
>> just drop them here to be posted soon as part of a larger PRCM cleanup.
>>
>>
> ?Is the PRCM cleanup series available now ?
>
> Thanks,
> ?Sricharan
^ permalink raw reply [flat|nested] 16+ messages in thread
* [PATCH 2/4] ARM: OMAP2+: Move the stubbed prm and cm functions to prcm.c file and make them __weak.
2012-06-28 11:58 ` R, Sricharan
@ 2012-07-04 15:19 ` Paul Walmsley
2012-07-04 15:25 ` R, Sricharan
0 siblings, 1 reply; 16+ messages in thread
From: Paul Walmsley @ 2012-07-04 15:19 UTC (permalink / raw)
To: linux-arm-kernel
Hi
On Thu, 28 Jun 2012, R, Sricharan wrote:
> Ping..
Since the prcm.c cleanup series isn't ready yet, I've queued this modified
version of your patch.
Once the prcm.c cleanup series is ready, hopefully in the 3.7 time frame,
we'll be able to get rid of all of these nasty stubs.
- Paul
From: R Sricharan <r.sricharan@ti.com>
Date: Thu, 10 May 2012 22:36:53 +0530
Subject: [PATCH] ARM: OMAP2+: PRM/CM: Move the stubbed prm and cm functions
to prcm.c file and make them __weak
Some prm and cm registers read/write and status functions
are built only for some custom OMAP2+ builds and are stubbed
in header files for other builds under ifdef statements.
But this results in adding new CONFIG_ARCH_OMAPXXX
checks when SOCs are added in the future. So move them
to a common place for OMAP2+ and make them 'weak' implementations.
This way no new ifdefs would be required in the future and also
cleans up the existing code.
Signed-off-by: R Sricharan <r.sricharan@ti.com>
[paul at pwsan.com: unsplit quoted strings; moved PRM functions to
mach-omap2/prm_common.c; resolved sparse warnings]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
---
arch/arm/mach-omap2/cminst44xx.h | 25 --------------
arch/arm/mach-omap2/prcm.c | 23 +++++++++++++
arch/arm/mach-omap2/prm2xxx_3xxx.h | 65 ------------------------------------
arch/arm/mach-omap2/prm_common.c | 62 ++++++++++++++++++++++++++++++++++
4 files changed, 85 insertions(+), 90 deletions(-)
diff --git a/arch/arm/mach-omap2/cminst44xx.h b/arch/arm/mach-omap2/cminst44xx.h
index a018a73..d69fdef 100644
--- a/arch/arm/mach-omap2/cminst44xx.h
+++ b/arch/arm/mach-omap2/cminst44xx.h
@@ -16,38 +16,13 @@ extern void omap4_cminst_clkdm_enable_hwsup(u8 part, s16 inst, u16 cdoffs);
extern void omap4_cminst_clkdm_disable_hwsup(u8 part, s16 inst, u16 cdoffs);
extern void omap4_cminst_clkdm_force_sleep(u8 part, s16 inst, u16 cdoffs);
extern void omap4_cminst_clkdm_force_wakeup(u8 part, s16 inst, u16 cdoffs);
-
extern int omap4_cminst_wait_module_ready(u8 part, u16 inst, s16 cdoffs, u16 clkctrl_offs);
-
-# ifdef CONFIG_ARCH_OMAP4
extern int omap4_cminst_wait_module_idle(u8 part, u16 inst, s16 cdoffs,
u16 clkctrl_offs);
-
extern void omap4_cminst_module_enable(u8 mode, u8 part, u16 inst, s16 cdoffs,
u16 clkctrl_offs);
extern void omap4_cminst_module_disable(u8 part, u16 inst, s16 cdoffs,
u16 clkctrl_offs);
-
-# else
-
-static inline int omap4_cminst_wait_module_idle(u8 part, u16 inst, s16 cdoffs,
- u16 clkctrl_offs)
-{
- return 0;
-}
-
-static inline void omap4_cminst_module_enable(u8 mode, u8 part, u16 inst,
- s16 cdoffs, u16 clkctrl_offs)
-{
-}
-
-static inline void omap4_cminst_module_disable(u8 part, u16 inst, s16 cdoffs,
- u16 clkctrl_offs)
-{
-}
-
-# endif
-
/*
* In an ideal world, we would not export these low-level functions,
* but this will probably take some time to fix properly
diff --git a/arch/arm/mach-omap2/prcm.c b/arch/arm/mach-omap2/prcm.c
index 480f40a..28cbfb2 100644
--- a/arch/arm/mach-omap2/prcm.c
+++ b/arch/arm/mach-omap2/prcm.c
@@ -35,6 +35,7 @@
#include "prm2xxx_3xxx.h"
#include "prm44xx.h"
#include "prminst44xx.h"
+#include "cminst44xx.h"
#include "prm-regbits-24xx.h"
#include "prm-regbits-44xx.h"
#include "control.h"
@@ -164,3 +165,25 @@ void __init omap2_set_globals_prcm(struct omap_globals *omap2_globals)
omap_cm_base_init();
}
}
+
+/*
+ * Stubbed functions so that common files continue to build when
+ * custom builds are used
+ * XXX These are temporary and should be removed at the earliest possible
+ * opportunity
+ */
+int __weak omap4_cminst_wait_module_idle(u8 part, u16 inst, s16 cdoffs,
+ u16 clkctrl_offs)
+{
+ return 0;
+}
+
+void __weak omap4_cminst_module_enable(u8 mode, u8 part, u16 inst,
+ s16 cdoffs, u16 clkctrl_offs)
+{
+}
+
+void __weak omap4_cminst_module_disable(u8 part, u16 inst, s16 cdoffs,
+ u16 clkctrl_offs)
+{
+}
diff --git a/arch/arm/mach-omap2/prm2xxx_3xxx.h b/arch/arm/mach-omap2/prm2xxx_3xxx.h
index 70ac2a1..f7bb57f 100644
--- a/arch/arm/mach-omap2/prm2xxx_3xxx.h
+++ b/arch/arm/mach-omap2/prm2xxx_3xxx.h
@@ -228,68 +228,6 @@
#ifndef __ASSEMBLER__
-/*
- * Stub omap2xxx/omap3xxx functions so that common files
- * continue to build when custom builds are used
- */
-#if defined(CONFIG_ARCH_OMAP4) && !(defined(CONFIG_ARCH_OMAP2) || \
- defined(CONFIG_ARCH_OMAP3))
-static inline u32 omap2_prm_read_mod_reg(s16 module, u16 idx)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
- return 0;
-}
-static inline void omap2_prm_write_mod_reg(u32 val, s16 module, u16 idx)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
-}
-static inline u32 omap2_prm_rmw_mod_reg_bits(u32 mask, u32 bits,
- s16 module, s16 idx)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
- return 0;
-}
-static inline u32 omap2_prm_set_mod_reg_bits(u32 bits, s16 module, s16 idx)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
- return 0;
-}
-static inline u32 omap2_prm_clear_mod_reg_bits(u32 bits, s16 module, s16 idx)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
- return 0;
-}
-static inline u32 omap2_prm_read_mod_bits_shift(s16 domain, s16 idx, u32 mask)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
- return 0;
-}
-static inline int omap2_prm_is_hardreset_asserted(s16 prm_mod, u8 shift)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
- return 0;
-}
-static inline int omap2_prm_assert_hardreset(s16 prm_mod, u8 shift)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
- return 0;
-}
-static inline int omap2_prm_deassert_hardreset(s16 prm_mod, u8 rst_shift,
- u8 st_shift)
-{
- WARN(1, "prm: omap2xxx/omap3xxx specific function and "
- "not suppose to be used on omap4\n");
- return 0;
-}
-#else
/* Power/reset management domain register get/set */
extern u32 omap2_prm_read_mod_reg(s16 module, u16 idx);
extern void omap2_prm_write_mod_reg(u32 val, s16 module, u16 idx);
@@ -320,9 +258,6 @@ extern void omap3xxx_prm_read_pending_irqs(unsigned long *events);
extern void omap3xxx_prm_ocp_barrier(void);
extern void omap3xxx_prm_save_and_clear_irqen(u32 *saved_mask);
extern void omap3xxx_prm_restore_irqen(u32 *saved_mask);
-
-#endif /* CONFIG_ARCH_OMAP4 */
-
#endif
/*
diff --git a/arch/arm/mach-omap2/prm_common.c b/arch/arm/mach-omap2/prm_common.c
index dfe00dd..663ade3 100644
--- a/arch/arm/mach-omap2/prm_common.c
+++ b/arch/arm/mach-omap2/prm_common.c
@@ -319,3 +319,65 @@ err:
omap_prcm_irq_cleanup();
return -ENOMEM;
}
+
+/*
+ * Stubbed functions so that common files continue to build when
+ * custom builds are used
+ * XXX These are temporary and should be removed at the earliest possible
+ * opportunity
+ */
+u32 __weak omap2_prm_read_mod_reg(s16 module, u16 idx)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function called on non-omap2xxx/3xxx\n");
+ return 0;
+}
+
+void __weak omap2_prm_write_mod_reg(u32 val, s16 module, u16 idx)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function called on non-omap2xxx/3xxx\n");
+}
+
+u32 __weak omap2_prm_rmw_mod_reg_bits(u32 mask, u32 bits,
+ s16 module, s16 idx)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function called on non-omap2xxx/3xxx\n");
+ return 0;
+}
+
+u32 __weak omap2_prm_set_mod_reg_bits(u32 bits, s16 module, s16 idx)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function called on non-omap2xxx/3xxx\n");
+ return 0;
+}
+
+u32 __weak omap2_prm_clear_mod_reg_bits(u32 bits, s16 module, s16 idx)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function called on non-omap2xxx/3xxx\n");
+ return 0;
+}
+
+u32 __weak omap2_prm_read_mod_bits_shift(s16 domain, s16 idx, u32 mask)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function called on non-omap2xxx/3xxx\n");
+ return 0;
+}
+
+int __weak omap2_prm_is_hardreset_asserted(s16 prm_mod, u8 shift)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function called on non-omap2xxx/3xxx\n");
+ return 0;
+}
+
+int __weak omap2_prm_assert_hardreset(s16 prm_mod, u8 shift)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function called on non-omap2xxx/3xxx\n");
+ return 0;
+}
+
+int __weak omap2_prm_deassert_hardreset(s16 prm_mod, u8 rst_shift,
+ u8 st_shift)
+{
+ WARN(1, "prm: omap2xxx/omap3xxx specific function called on non-omap2xxx/3xxx\n");
+ return 0;
+}
+
--
1.7.10
^ permalink raw reply related [flat|nested] 16+ messages in thread
* [PATCH 2/4] ARM: OMAP2+: Move the stubbed prm and cm functions to prcm.c file and make them __weak.
2012-07-04 15:19 ` Paul Walmsley
@ 2012-07-04 15:25 ` R, Sricharan
0 siblings, 0 replies; 16+ messages in thread
From: R, Sricharan @ 2012-07-04 15:25 UTC (permalink / raw)
To: linux-arm-kernel
Hi Paul,
On Wed, Jul 4, 2012 at 8:49 PM, Paul Walmsley <paul@pwsan.com> wrote:
> Hi
>
> On Thu, 28 Jun 2012, R, Sricharan wrote:
>
>> Ping..
>
> Since the prcm.c cleanup series isn't ready yet, I've queued this modified
> version of your patch.
>
> Once the prcm.c cleanup series is ready, hopefully in the 3.7 time frame,
> we'll be able to get rid of all of these nasty stubs.
>
Thanks a lot. I think this should help to get rid of the OMAP5 dependency.
Thanks,
Sricharan
^ permalink raw reply [flat|nested] 16+ messages in thread
end of thread, other threads:[~2012-07-04 15:25 UTC | newest]
Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-05-10 17:06 [PATCH 0/4] ARM: OMAP2+: Misc cleanup part2 R Sricharan
2012-05-10 17:06 ` [PATCH 1/4] ARM: OMAP2+: Introduce CONFIG_SOC_HAS_OMAP_DPLL macro R Sricharan
2012-05-10 18:26 ` Hiremath, Vaibhav
2012-05-11 6:16 ` R, Sricharan
2012-05-11 6:22 ` Hiremath, Vaibhav
2012-05-11 6:23 ` R, Sricharan
2012-05-10 17:06 ` [PATCH 2/4] ARM: OMAP2+: Move the stubbed prm and cm functions to prcm.c file and make them __weak R Sricharan
2012-05-10 17:41 ` Paul Walmsley
2012-05-10 17:44 ` Sricharan R
2012-06-14 11:56 ` R, Sricharan
2012-06-28 11:58 ` R, Sricharan
2012-07-04 15:19 ` Paul Walmsley
2012-07-04 15:25 ` R, Sricharan
2012-05-10 17:06 ` [PATCH 3/4] ARM: OMAP2+: Move stubbed secure_sram_reserve function to a common.c and call it __weak R Sricharan
2012-05-10 17:06 ` [PATCH 4/4] ARM: OMAP: counter-32k: Select the CR register offset using the IP scheme R Sricharan
2012-05-10 17:17 ` [PATCH 0/4] ARM: OMAP2+: Misc cleanup part2 Sricharan R
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).