* [PATCH 0/2] ARM: OMAP3: fix boot regression for N9
@ 2017-10-30 9:11 Tero Kristo
2017-10-30 9:11 ` [PATCH 1/2] ARM: OMAP3: hwmod_data: add missing module_offs for MMC3 Tero Kristo
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: Tero Kristo @ 2017-10-30 9:11 UTC (permalink / raw)
To: linux-arm-kernel
Hi,
N9 boot is apparently broken with mainline, caused by some recent
changes to TI clock drivers. The reason for failing boot is effectively
missing hwmod data piece for MMC3, so add this in place. The CM
related fix is also needed to properly handle idlest functionality
on OMAP3; currently this is mostly masked but will cause issues in
some places.
-Tero
--
Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki. Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki
^ permalink raw reply [flat|nested] 5+ messages in thread* [PATCH 1/2] ARM: OMAP3: hwmod_data: add missing module_offs for MMC3 2017-10-30 9:11 [PATCH 0/2] ARM: OMAP3: fix boot regression for N9 Tero Kristo @ 2017-10-30 9:11 ` Tero Kristo 2017-10-30 9:11 ` [PATCH 2/2] ARM: OMAP2/3: CM: fix cm_split_idlest functionality Tero Kristo 2017-10-30 16:19 ` [PATCH 0/2] ARM: OMAP3: fix boot regression for N9 Tony Lindgren 2 siblings, 0 replies; 5+ messages in thread From: Tero Kristo @ 2017-10-30 9:11 UTC (permalink / raw) To: linux-arm-kernel MMC3 hwmod data is missing the module_offs definition. MMC3 belongs under core, so add CORE_MOD for it. Signed-off-by: Tero Kristo <t-kristo@ti.com> --- arch/arm/mach-omap2/omap_hwmod_3xxx_data.c | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c b/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c index c327643..c12e7b5 100644 --- a/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c +++ b/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c @@ -1656,6 +1656,7 @@ .main_clk = "mmchs3_fck", .prcm = { .omap2 = { + .module_offs = CORE_MOD, .prcm_reg_id = 1, .module_bit = OMAP3430_EN_MMC3_SHIFT, .idlest_reg_id = 1, -- 1.9.1 -- Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki. Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki ^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCH 2/2] ARM: OMAP2/3: CM: fix cm_split_idlest functionality 2017-10-30 9:11 [PATCH 0/2] ARM: OMAP3: fix boot regression for N9 Tero Kristo 2017-10-30 9:11 ` [PATCH 1/2] ARM: OMAP3: hwmod_data: add missing module_offs for MMC3 Tero Kristo @ 2017-10-30 9:11 ` Tero Kristo 2017-10-30 16:19 ` [PATCH 0/2] ARM: OMAP3: fix boot regression for N9 Tony Lindgren 2 siblings, 0 replies; 5+ messages in thread From: Tero Kristo @ 2017-10-30 9:11 UTC (permalink / raw) To: linux-arm-kernel cm_split_idlest doesn't take the CM base offset into account right now, causing it to read reserved registers which show idlestatus as active always. This will cause the wait_module_ready functionality to be effectively an expensive NOP, which will cause problems if the module hasn't really activated during its execution. Fix by adding the CM offset into the calculation so the wait_module_ready will access correct register. Signed-off-by: Tero Kristo <t-kristo@ti.com> Reported-by: Filip Matijevic <filip.matijevic.pz@gmail.com> --- arch/arm/mach-omap2/cm_common.c | 6 +++++- arch/arm/mach-omap2/prcm-common.h | 1 + 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/arch/arm/mach-omap2/cm_common.c b/arch/arm/mach-omap2/cm_common.c index 1752e92..b7511a5 100644 --- a/arch/arm/mach-omap2/cm_common.c +++ b/arch/arm/mach-omap2/cm_common.c @@ -68,14 +68,17 @@ void __init omap2_set_globals_cm(void __iomem *cm, void __iomem *cm2) int cm_split_idlest_reg(struct clk_omap_reg *idlest_reg, s16 *prcm_inst, u8 *idlest_reg_id) { + int ret; if (!cm_ll_data->split_idlest_reg) { WARN_ONCE(1, "cm: %s: no low-level function defined\n", __func__); return -EINVAL; } - return cm_ll_data->split_idlest_reg(idlest_reg, prcm_inst, + ret = cm_ll_data->split_idlest_reg(idlest_reg, prcm_inst, idlest_reg_id); + *prcm_inst -= cm_base.offset; + return ret; } /** @@ -347,6 +350,7 @@ int __init omap2_cm_base_init(void) if (mem) { mem->pa = res.start + data->offset; mem->va = data->mem + data->offset; + mem->offset = data->offset; } data->np = np; diff --git a/arch/arm/mach-omap2/prcm-common.h b/arch/arm/mach-omap2/prcm-common.h index ee7041d..ac9ee2e 100644 --- a/arch/arm/mach-omap2/prcm-common.h +++ b/arch/arm/mach-omap2/prcm-common.h @@ -529,6 +529,7 @@ struct omap_prcm_irq_setup { struct omap_domain_base { u32 pa; void __iomem *va; + s16 offset; }; /** -- 1.9.1 -- Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki. Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki ^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCH 0/2] ARM: OMAP3: fix boot regression for N9 2017-10-30 9:11 [PATCH 0/2] ARM: OMAP3: fix boot regression for N9 Tero Kristo 2017-10-30 9:11 ` [PATCH 1/2] ARM: OMAP3: hwmod_data: add missing module_offs for MMC3 Tero Kristo 2017-10-30 9:11 ` [PATCH 2/2] ARM: OMAP2/3: CM: fix cm_split_idlest functionality Tero Kristo @ 2017-10-30 16:19 ` Tony Lindgren 2017-10-30 19:44 ` Tero Kristo 2 siblings, 1 reply; 5+ messages in thread From: Tony Lindgren @ 2017-10-30 16:19 UTC (permalink / raw) To: linux-arm-kernel * Tero Kristo <t-kristo@ti.com> [171030 02:13]: > Hi, > > N9 boot is apparently broken with mainline, caused by some recent > changes to TI clock drivers. The reason for failing boot is effectively > missing hwmod data piece for MMC3, so add this in place. The CM > related fix is also needed to properly handle idlest functionality > on OMAP3; currently this is mostly masked but will cause issues in > some places. Thanks applying both into omap-for-v4.14/fixes. If these don't make it to v4.14, these can always be requested for stable releases as needed as specified in Documentation/process/stable-kernel-rules.rst. Regards, Tony ^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH 0/2] ARM: OMAP3: fix boot regression for N9 2017-10-30 16:19 ` [PATCH 0/2] ARM: OMAP3: fix boot regression for N9 Tony Lindgren @ 2017-10-30 19:44 ` Tero Kristo 0 siblings, 0 replies; 5+ messages in thread From: Tero Kristo @ 2017-10-30 19:44 UTC (permalink / raw) To: linux-arm-kernel On 30/10/17 18:19, Tony Lindgren wrote: > * Tero Kristo <t-kristo@ti.com> [171030 02:13]: >> Hi, >> >> N9 boot is apparently broken with mainline, caused by some recent >> changes to TI clock drivers. The reason for failing boot is effectively >> missing hwmod data piece for MMC3, so add this in place. The CM >> related fix is also needed to properly handle idlest functionality >> on OMAP3; currently this is mostly masked but will cause issues in >> some places. > > Thanks applying both into omap-for-v4.14/fixes. If these don't make > it to v4.14, these can always be requested for stable releases as > needed as specified in Documentation/process/stable-kernel-rules.rst. Yeah, really sorry about the delay but was kind of out of my hands this time. Hopefully my email issues have been solved for now and this won't happen again. -Tero -- Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki. Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2017-10-30 19:44 UTC | newest] Thread overview: 5+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2017-10-30 9:11 [PATCH 0/2] ARM: OMAP3: fix boot regression for N9 Tero Kristo 2017-10-30 9:11 ` [PATCH 1/2] ARM: OMAP3: hwmod_data: add missing module_offs for MMC3 Tero Kristo 2017-10-30 9:11 ` [PATCH 2/2] ARM: OMAP2/3: CM: fix cm_split_idlest functionality Tero Kristo 2017-10-30 16:19 ` [PATCH 0/2] ARM: OMAP3: fix boot regression for N9 Tony Lindgren 2017-10-30 19:44 ` Tero Kristo
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).