From f106056095049c2c748c2a2797e5353295240e04 Mon Sep 17 00:00:00 2001 From: Prafulla Wadaskar Date: Thu, 26 Aug 2010 14:43:55 +0530 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 --- arch/arm/cpu/arm926ejs/kirkwood/cpu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/cpu/arm926ejs/kirkwood/cpu.c b/arch/arm/cpu/arm926ejs/kirkwood/cpu.c index c63e8641f2..82c978bd93 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; } -- 2.39.5