All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] Kirkwood: bugfix: window size (mis)calculation
  2010-08-26  9:14 [U-Boot] [PATCH] Kirkwood: bugfix: window size (mis)calculation Prafulla Wadaskar
@ 2010-08-26  5:02 ` Prafulla Wadaskar
  0 siblings, 0 replies; 2+ messages in thread
From: Prafulla Wadaskar @ 2010-08-26  5:02 UTC (permalink / raw)
  To: u-boot

 

> -----Original Message-----
> From: Prafulla Wadaskar [mailto:prafulla at marvell.com] 
> Sent: Thursday, August 26, 2010 2:45 PM
> To: u-boot at lists.denx.de
> Cc: Prabhanjan Sarnaik; Ashish Karkare; Prafulla Wadaskar
> Subject: [PATCH] Kirkwood: bugfix: window size (mis)calculation
> 
> Fixed kw_winctrl_calcsize() off-by-1 bug which caused mapping
> windows size to be cut by half.
> This corrected all windows address configuration
> 
> Signed-off-by: Prafulla Wadaskar <prafulla@marvell.com>
> ---
>  arch/arm/cpu/arm926ejs/kirkwood/cpu.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/arch/arm/cpu/arm926ejs/kirkwood/cpu.c 
> b/arch/arm/cpu/arm926ejs/kirkwood/cpu.c
> index c63e864..82c978b 100644
> --- a/arch/arm/cpu/arm926ejs/kirkwood/cpu.c
> +++ b/arch/arm/cpu/arm926ejs/kirkwood/cpu.c
> @@ -81,7 +81,7 @@ unsigned int kw_winctrl_calcsize(unsigned 
> int sizeval)
>  	unsigned int j = 0;
>  	u32 val = sizeval >> 1;
>  
> -	for (i = 0; val > 0x10000; i++) {
> +	for (i = 0; val >= 0x10000; i++) {
>  		j |= (1 << i);
>  		val = val >> 1;
>  	}

Applied to u-boot-marvell.git master branch
Regards..
Prafulla . .

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

* [U-Boot] [PATCH] Kirkwood: bugfix: window size (mis)calculation
@ 2010-08-26  9:14 Prafulla Wadaskar
  2010-08-26  5:02 ` Prafulla Wadaskar
  0 siblings, 1 reply; 2+ messages in thread
From: Prafulla Wadaskar @ 2010-08-26  9:14 UTC (permalink / raw)
  To: u-boot

Fixed kw_winctrl_calcsize() off-by-1 bug which caused mapping
windows size to be cut by half.
This corrected all windows address configuration

Signed-off-by: Prafulla Wadaskar <prafulla@marvell.com>
---
 arch/arm/cpu/arm926ejs/kirkwood/cpu.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/arm/cpu/arm926ejs/kirkwood/cpu.c b/arch/arm/cpu/arm926ejs/kirkwood/cpu.c
index c63e864..82c978b 100644
--- a/arch/arm/cpu/arm926ejs/kirkwood/cpu.c
+++ b/arch/arm/cpu/arm926ejs/kirkwood/cpu.c
@@ -81,7 +81,7 @@ unsigned int kw_winctrl_calcsize(unsigned int sizeval)
 	unsigned int j = 0;
 	u32 val = sizeval >> 1;
 
-	for (i = 0; val > 0x10000; i++) {
+	for (i = 0; val >= 0x10000; i++) {
 		j |= (1 << i);
 		val = val >> 1;
 	}
-- 
1.5.3.3

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

end of thread, other threads:[~2010-08-26  9:14 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-08-26  9:14 [U-Boot] [PATCH] Kirkwood: bugfix: window size (mis)calculation Prafulla Wadaskar
2010-08-26  5:02 ` Prafulla Wadaskar

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.