All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] arm: mach-omap2: cache: Explicitly enable I cache
@ 2018-05-03 15:04 Lokesh Vutla
  2018-05-03 15:08 ` Jean-Jacques Hiblot
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Lokesh Vutla @ 2018-05-03 15:04 UTC (permalink / raw)
  To: u-boot

omap-common cache enabling sequence relies on cpu_init_cp15()
(inside start.S) for enabling I-caches. But cpu_init_cp15()
can be skipped if CONFIG_SKIP_LOWLEVEL_INIT is defined. So
enable I-caches if not enabled already.

Debugged-by: Jean-Jacques Hiblot <jjhiblot@ti.com>
Tested-by: Steve Kipisz <s-kipisz2@ti.com>
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
---
 arch/arm/mach-omap2/omap-cache.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/arch/arm/mach-omap2/omap-cache.c b/arch/arm/mach-omap2/omap-cache.c
index b37163a4f3..975ee1b020 100644
--- a/arch/arm/mach-omap2/omap-cache.c
+++ b/arch/arm/mach-omap2/omap-cache.c
@@ -44,7 +44,11 @@ DECLARE_GLOBAL_DATA_PTR;
 
 void enable_caches(void)
 {
-	/* Enable D-cache. I-cache is already enabled in start.S */
+
+	/* Enable I cache if not enabled */
+	if (!icache_status())
+		icache_enable();
+
 	dcache_enable();
 }
 
-- 
2.17.0

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [U-Boot] [PATCH] arm: mach-omap2: cache: Explicitly enable I cache
  2018-05-03 15:04 [U-Boot] [PATCH] arm: mach-omap2: cache: Explicitly enable I cache Lokesh Vutla
@ 2018-05-03 15:08 ` Jean-Jacques Hiblot
  2018-05-03 20:22 ` Tom Rini
  2018-05-06 21:12 ` [U-Boot] " Tom Rini
  2 siblings, 0 replies; 4+ messages in thread
From: Jean-Jacques Hiblot @ 2018-05-03 15:08 UTC (permalink / raw)
  To: u-boot



On 03/05/2018 17:04, Lokesh Vutla wrote:
> omap-common cache enabling sequence relies on cpu_init_cp15()
> (inside start.S) for enabling I-caches. But cpu_init_cp15()
> can be skipped if CONFIG_SKIP_LOWLEVEL_INIT is defined. So
> enable I-caches if not enabled already.
>
> Debugged-by: Jean-Jacques Hiblot <jjhiblot@ti.com>
> Tested-by: Steve Kipisz <s-kipisz2@ti.com>
> Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
> ---
>   arch/arm/mach-omap2/omap-cache.c | 6 +++++-
>   1 file changed, 5 insertions(+), 1 deletion(-)
>
> diff --git a/arch/arm/mach-omap2/omap-cache.c b/arch/arm/mach-omap2/omap-cache.c
> index b37163a4f3..975ee1b020 100644
> --- a/arch/arm/mach-omap2/omap-cache.c
> +++ b/arch/arm/mach-omap2/omap-cache.c
> @@ -44,7 +44,11 @@ DECLARE_GLOBAL_DATA_PTR;
>   
>   void enable_caches(void)
>   {
> -	/* Enable D-cache. I-cache is already enabled in start.S */
> +
> +	/* Enable I cache if not enabled */
> +	if (!icache_status())
> +		icache_enable();
> +
>   	dcache_enable();
>   }
>   

Tested-by: Jean-Jacques Hiblot <jjhiblot@ti.com>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [U-Boot] [PATCH] arm: mach-omap2: cache: Explicitly enable I cache
  2018-05-03 15:04 [U-Boot] [PATCH] arm: mach-omap2: cache: Explicitly enable I cache Lokesh Vutla
  2018-05-03 15:08 ` Jean-Jacques Hiblot
@ 2018-05-03 20:22 ` Tom Rini
  2018-05-06 21:12 ` [U-Boot] " Tom Rini
  2 siblings, 0 replies; 4+ messages in thread
From: Tom Rini @ 2018-05-03 20:22 UTC (permalink / raw)
  To: u-boot

On Thu, May 03, 2018 at 08:34:49PM +0530, Lokesh Vutla wrote:

> omap-common cache enabling sequence relies on cpu_init_cp15()
> (inside start.S) for enabling I-caches. But cpu_init_cp15()
> can be skipped if CONFIG_SKIP_LOWLEVEL_INIT is defined. So
> enable I-caches if not enabled already.
> 
> Debugged-by: Jean-Jacques Hiblot <jjhiblot@ti.com>
> Tested-by: Steve Kipisz <s-kipisz2@ti.com>
> Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>

Reviewed-by: Tom Rini <trini@konsulko.com>

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20180503/d252beec/attachment.sig>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [U-Boot] arm: mach-omap2: cache: Explicitly enable I cache
  2018-05-03 15:04 [U-Boot] [PATCH] arm: mach-omap2: cache: Explicitly enable I cache Lokesh Vutla
  2018-05-03 15:08 ` Jean-Jacques Hiblot
  2018-05-03 20:22 ` Tom Rini
@ 2018-05-06 21:12 ` Tom Rini
  2 siblings, 0 replies; 4+ messages in thread
From: Tom Rini @ 2018-05-06 21:12 UTC (permalink / raw)
  To: u-boot

On Thu, May 03, 2018 at 08:34:49PM +0530, Lokesh Vutla wrote:

> omap-common cache enabling sequence relies on cpu_init_cp15()
> (inside start.S) for enabling I-caches. But cpu_init_cp15()
> can be skipped if CONFIG_SKIP_LOWLEVEL_INIT is defined. So
> enable I-caches if not enabled already.
> 
> Debugged-by: Jean-Jacques Hiblot <jjhiblot@ti.com>
> Tested-by: Steve Kipisz <s-kipisz2@ti.com>
> Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
> Tested-by: Jean-Jacques Hiblot <jjhiblot@ti.com>
> Reviewed-by: Tom Rini <trini@konsulko.com>

Applied to u-boot/master, thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20180506/c2b1c12b/attachment.sig>

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-05-06 21:12 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-05-03 15:04 [U-Boot] [PATCH] arm: mach-omap2: cache: Explicitly enable I cache Lokesh Vutla
2018-05-03 15:08 ` Jean-Jacques Hiblot
2018-05-03 20:22 ` Tom Rini
2018-05-06 21:12 ` [U-Boot] " Tom Rini

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.