aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorSantosh Shilimkar <santosh.shilimkar@ti.com>2011-01-04 10:10:27 -0500
committerKevin Hilman <khilman@ti.com>2011-01-07 16:33:10 -0500
commit56a6a19dffda6b75cef8d4183c7c6ff650025cbd (patch)
treead09eac74101563fe7dd8fab8429c95fdfda8836 /arch
parentfaacebc50902d367071e788c6586882a32bf09f2 (diff)
omap2plus: prm: Trvial build break fix for undefined reference to 'omap2_prm_read_mod_reg'
omap2plus_defocnfig build breaks when customised with only ARCH_OMAP4 selected. This is because common files make references to the functions which are defined only for omap2xxx and omap3xxx. LD .tmp_vmlinux1 arch/arm/mach-omap2/built-in.o: In function `pm_dbg_regset_store': arch/arm/mach-omap2/pm-debug.c:335: undefined reference to `omap2_prm_read_mod_reg' arch/arm/mach-omap2/built-in.o: In function `omap2_pm_dump': arch/arm/mach-omap2/pm-debug.c:121: undefined reference to `omap2_prm_read_mod_reg' arch/arm/mach-omap2/pm-debug.c:123: undefined reference to `omap2_prm_read_mod_reg' arch/arm/mach-omap2/pm-debug.c:124: undefined reference to `omap2_prm_read_mod_reg' arch/arm/mach-omap2/pm-debug.c:125: undefined reference to `omap2_prm_read_mod_reg' arch/arm/mach-omap2/built-in.o: In function `omap_prcm_arch_reset': arch/arm/mach-omap2/prcm.c:106: undefined reference to `omap2_prm_set_mod_reg_bits' arch/arm/mach-omap2/prcm.c:108: undefined reference to `omap2_prm_read_mod_reg' arch/arm/mach-omap2/built-in.o: In function `omap_prcm_get_reset_sources': arch/arm/mach-omap2/prcm.c:53: undefined reference to `omap2_prm_read_mod_reg' arch/arm/mach-omap2/built-in.o: In function `clkdm_clear_all_wkdeps': arch/arm/mach-omap2/clockdomain.c:545: undefined reference to `omap2_prm_clear_mod_reg_bits' arch/arm/mach-omap2/built-in.o: In function `clkdm_del_wkdep': arch/arm/mach-omap2/clockdomain.c:475: undefined reference to `omap2_prm_clear_mod_reg_bits' arch/arm/mach-omap2/built-in.o: In function `clkdm_read_wkdep': arch/arm/mach-omap2/clockdomain.c:511: undefined reference to `omap2_prm_read_mod_bits_shift' arch/arm/mach-omap2/built-in.o: In function `clkdm_add_wkdep': arch/arm/mach-omap2/clockdomain.c:440: undefined reference to `omap2_prm_set_mod_reg_bits' make: *** [.tmp_vmlinux1] Error 1 This patch adds stubs for these functions so that build continues to work. Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com> Acked-by: Paul Walmsley <paul@pwsan.com> Signed-off-by: Kevin Hilman <khilman@ti.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/mach-omap2/prm2xxx_3xxx.h63
1 files changed, 62 insertions, 1 deletions
diff --git a/arch/arm/mach-omap2/prm2xxx_3xxx.h b/arch/arm/mach-omap2/prm2xxx_3xxx.h
index 53d44f6e3736..49654c8d18f5 100644
--- a/arch/arm/mach-omap2/prm2xxx_3xxx.h
+++ b/arch/arm/mach-omap2/prm2xxx_3xxx.h
@@ -228,7 +228,67 @@
228 228
229 229
230#ifndef __ASSEMBLER__ 230#ifndef __ASSEMBLER__
231 231/*
232 * Stub omap2xxx/omap3xxx functions so that common files
233 * continue to build when custom builds are used
234 */
235#if defined(CONFIG_ARCH_OMAP4) && !(defined(CONFIG_ARCH_OMAP2) || \
236 defined(CONFIG_ARCH_OMAP3))
237static inline u32 omap2_prm_read_mod_reg(s16 module, u16 idx)
238{
239 WARN(1, "prm: omap2xxx/omap3xxx specific function and "
240 "not suppose to be used on omap4\n");
241 return 0;
242}
243static inline void omap2_prm_write_mod_reg(u32 val, s16 module, u16 idx)
244{
245 WARN(1, "prm: omap2xxx/omap3xxx specific function and "
246 "not suppose to be used on omap4\n");
247}
248static inline u32 omap2_prm_rmw_mod_reg_bits(u32 mask, u32 bits,
249 s16 module, s16 idx)
250{
251 WARN(1, "prm: omap2xxx/omap3xxx specific function and "
252 "not suppose to be used on omap4\n");
253 return 0;
254}
255static inline u32 omap2_prm_set_mod_reg_bits(u32 bits, s16 module, s16 idx)
256{
257 WARN(1, "prm: omap2xxx/omap3xxx specific function and "
258 "not suppose to be used on omap4\n");
259 return 0;
260}
261static inline u32 omap2_prm_clear_mod_reg_bits(u32 bits, s16 module, s16 idx)
262{
263 WARN(1, "prm: omap2xxx/omap3xxx specific function and "
264 "not suppose to be used on omap4\n");
265 return 0;
266}
267static inline u32 omap2_prm_read_mod_bits_shift(s16 domain, s16 idx, u32 mask)
268{
269 WARN(1, "prm: omap2xxx/omap3xxx specific function and "
270 "not suppose to be used on omap4\n");
271 return 0;
272}
273static inline int omap2_prm_is_hardreset_asserted(s16 prm_mod, u8 shift)
274{
275 WARN(1, "prm: omap2xxx/omap3xxx specific function and "
276 "not suppose to be used on omap4\n");
277 return 0;
278}
279static inline int omap2_prm_assert_hardreset(s16 prm_mod, u8 shift)
280{
281 WARN(1, "prm: omap2xxx/omap3xxx specific function and "
282 "not suppose to be used on omap4\n");
283 return 0;
284}
285static inline int omap2_prm_deassert_hardreset(s16 prm_mod, u8 shift)
286{
287 WARN(1, "prm: omap2xxx/omap3xxx specific function and "
288 "not suppose to be used on omap4\n");
289 return 0;
290}
291#else
232/* Power/reset management domain register get/set */ 292/* Power/reset management domain register get/set */
233extern u32 omap2_prm_read_mod_reg(s16 module, u16 idx); 293extern u32 omap2_prm_read_mod_reg(s16 module, u16 idx);
234extern void omap2_prm_write_mod_reg(u32 val, s16 module, u16 idx); 294extern void omap2_prm_write_mod_reg(u32 val, s16 module, u16 idx);
@@ -242,6 +302,7 @@ extern int omap2_prm_is_hardreset_asserted(s16 prm_mod, u8 shift);
242extern int omap2_prm_assert_hardreset(s16 prm_mod, u8 shift); 302extern int omap2_prm_assert_hardreset(s16 prm_mod, u8 shift);
243extern int omap2_prm_deassert_hardreset(s16 prm_mod, u8 shift); 303extern int omap2_prm_deassert_hardreset(s16 prm_mod, u8 shift);
244 304
305#endif /* CONFIG_ARCH_OMAP4 */
245#endif 306#endif
246 307
247/* 308/*