From: gururaja.hebbar@ti.com (Hebbar Gururaja)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v2] ARM: OMAP2: hwmod: Fix "register offset NULL check" bug
Date: Tue, 18 Dec 2012 18:26:18 +0530 [thread overview]
Message-ID: <1355835378-23437-1-git-send-email-gururaja.hebbar@ti.com> (raw)
From: "Hebbar, Gururaja" <gururaja.hebbar@ti.com>
omap4_cminst_wait_module_ready() checks if register offset is NULL.
int omap4_cminst_wait_module_ready(u8 part, u16 inst, s16 cdoffs,
u16 clkctrl_offs)
{
int i = 0;
if (!clkctrl_offs)
return 0;
In case of AM33xx, CLKCTRL register offset for different clock domains
are not uniformly placed. An example of this would be the RTC clock
domain with CLKCTRL offset at 0x00.
In such cases the module ready check is skipped which leads to a data
abort during boot-up when RTC registers is accessed.
Since the actual base address is verified in
omap4_cminst_read_inst_reg(), this check here is not required at all
and hence can be removed.
Signed-off-by: Hebbar, Gururaja <gururaja.hebbar@ti.com>
---
Changes in v2:
- update commit message to reflect the actual cause. Previous
message conveyed a wrong/opposite message.
:100644 100644 7f9a464... 40545ff... M arch/arm/mach-omap2/cminst44xx.c
arch/arm/mach-omap2/cminst44xx.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/arch/arm/mach-omap2/cminst44xx.c b/arch/arm/mach-omap2/cminst44xx.c
index 7f9a464..40545ff 100644
--- a/arch/arm/mach-omap2/cminst44xx.c
+++ b/arch/arm/mach-omap2/cminst44xx.c
@@ -271,9 +271,6 @@ int omap4_cminst_wait_module_ready(u8 part, u16 inst, s16 cdoffs,
{
int i = 0;
- if (!clkctrl_offs)
- return 0;
-
omap_test_timeout(_is_module_ready(part, inst, cdoffs, clkctrl_offs),
MAX_MODULE_READY_TIME, i);
--
1.7.9.5
next reply other threads:[~2012-12-18 12:56 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-18 12:56 Hebbar Gururaja [this message]
2012-12-18 12:55 ` [PATCH v2] ARM: OMAP2: hwmod: Fix "register offset NULL check" bug Felipe Balbi
2012-12-19 2:13 ` Paul Walmsley
2012-12-20 4:20 ` Hebbar, Gururaja
2012-12-20 7:35 ` Paul Walmsley
2013-01-30 14:07 ` Hebbar, Gururaja
2013-01-30 16:39 ` Paul Walmsley
2013-01-31 5:25 ` Hebbar, Gururaja
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1355835378-23437-1-git-send-email-gururaja.hebbar@ti.com \
--to=gururaja.hebbar@ti.com \
--cc=linux-arm-kernel@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox