Skip to content

Commit 98bbc11

Browse files
dgerlachPaul Walmsley
authored andcommitted
ARM: OMAP2+: hwmod: Change hardreset soc_ops for AM43XX
am43xx reset register layout is more similar to am33xx than omap4 so use the am33xx functions for hwmod hardreset soc_ops rather than the currently used omap4 functions. Without this, assert_hardreset and deassert_hardreset will not work on am43xx. Signed-off-by: Dave Gerlach <[email protected]> [[email protected]: fixed build errors for an AM43xx-only Kconfig] Signed-off-by: Paul Walmsley <[email protected]>
1 parent abf04af commit 98bbc11

File tree

3 files changed

+8
-6
lines changed

3 files changed

+8
-6
lines changed

arch/arm/mach-omap2/Makefile

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -110,14 +110,16 @@ obj-y += prm_common.o cm_common.o
110110
obj-$(CONFIG_ARCH_OMAP2) += prm2xxx_3xxx.o prm2xxx.o cm2xxx.o
111111
obj-$(CONFIG_ARCH_OMAP3) += prm2xxx_3xxx.o prm3xxx.o cm3xxx.o
112112
obj-$(CONFIG_ARCH_OMAP3) += vc3xxx_data.o vp3xxx_data.o
113-
obj-$(CONFIG_SOC_AM33XX) += prm33xx.o cm33xx.o
114113
omap-prcm-4-5-common = cminst44xx.o cm44xx.o prm44xx.o \
115114
prcm_mpu44xx.o prminst44xx.o \
116115
vc44xx_data.o vp44xx_data.o
117116
obj-$(CONFIG_ARCH_OMAP4) += $(omap-prcm-4-5-common)
118117
obj-$(CONFIG_SOC_OMAP5) += $(omap-prcm-4-5-common)
119118
obj-$(CONFIG_SOC_DRA7XX) += $(omap-prcm-4-5-common)
120-
obj-$(CONFIG_SOC_AM43XX) += $(omap-prcm-4-5-common)
119+
am33xx-43xx-prcm-common += prm33xx.o cm33xx.o
120+
obj-$(CONFIG_SOC_AM33XX) += $(am33xx-43xx-prcm-common)
121+
obj-$(CONFIG_SOC_AM43XX) += $(omap-prcm-4-5-common) \
122+
$(am33xx-43xx-prcm-common)
121123

122124
# OMAP voltage domains
123125
voltagedomain-common := voltage.o vc.o vp.o

arch/arm/mach-omap2/cm33xx.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -380,7 +380,7 @@ void am33xx_cm_clkdm_disable_hwsup(u16 inst, u16 cdoffs);
380380
void am33xx_cm_clkdm_force_sleep(u16 inst, u16 cdoffs);
381381
void am33xx_cm_clkdm_force_wakeup(u16 inst, u16 cdoffs);
382382

383-
#ifdef CONFIG_SOC_AM33XX
383+
#if defined(CONFIG_SOC_AM33XX) || defined(CONFIG_SOC_AM43XX)
384384
extern int am33xx_cm_wait_module_idle(u16 inst, s16 cdoffs,
385385
u16 clkctrl_offs);
386386
extern void am33xx_cm_module_enable(u8 mode, u16 inst, s16 cdoffs,

arch/arm/mach-omap2/omap_hwmod.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4251,9 +4251,9 @@ void __init omap_hwmod_init(void)
42514251
soc_ops.enable_module = _omap4_enable_module;
42524252
soc_ops.disable_module = _omap4_disable_module;
42534253
soc_ops.wait_target_ready = _omap4_wait_target_ready;
4254-
soc_ops.assert_hardreset = _omap4_assert_hardreset;
4255-
soc_ops.deassert_hardreset = _omap4_deassert_hardreset;
4256-
soc_ops.is_hardreset_asserted = _omap4_is_hardreset_asserted;
4254+
soc_ops.assert_hardreset = _am33xx_assert_hardreset;
4255+
soc_ops.deassert_hardreset = _am33xx_deassert_hardreset;
4256+
soc_ops.is_hardreset_asserted = _am33xx_is_hardreset_asserted;
42574257
soc_ops.init_clkdm = _init_clkdm;
42584258
} else if (soc_is_am33xx()) {
42594259
soc_ops.enable_module = _am33xx_enable_module;

0 commit comments

Comments
 (0)