> Wolfgang Denk wrote:
> > Dear Stefano,
> > 
> 
> Hi Wolfgang,
> 
> > Can you please have a look at this, and eventually send a pull req?
> > Thanks.
> 
> Thanks, I missed it. I would change the name of the maintainer and I
> will set myself for the MX51EVK, because Fred Fan resigned as maintainer
> for this board.
> 
> Li, could you please resend your patch as text ? It was sent as base-64
> encoded, and I cannot directly apply it.
> 
> Thanks,
> Stefano Babic
> 
> 
get_timer_masked() should return current timestamp,
not current ticks from hardware register.

Tested on one custom board with NAND flash.
Without this patch, NAND write always TIMEOUT
because get_timer(0) return a big value.

This patch applies for u-boot-2010.06

Signed-off-by: Li Haibo <h...@sinocastel.com>
---
 arch/arm/cpu/arm_cortexa8/mx51/timer.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/arm/cpu/arm_cortexa8/mx51/timer.c 
b/arch/arm/cpu/arm_cortexa8/mx51/timer.c
index 81c4a06..110edbf 100644
--- a/arch/arm/cpu/arm_cortexa8/mx51/timer.c
+++ b/arch/arm/cpu/arm_cortexa8/mx51/timer.c
@@ -89,7 +89,7 @@ ulong get_timer_masked(void)
                timestamp += ((0xFFFFFFFF / (CONFIG_MX51_CLK32 / CONFIG_SYS_HZ))
                                - lastinc) + val;
        lastinc = val;
-       return val;
+       return timestamp;
 }
 
 ulong get_timer(ulong base)
-- 
1.6.5.2



-- 
Li HaiBo
Tel:+86-755-86185111-3667
email:h...@sinocastel.com
Website:www.sinocastel.com 

This e-mail and its attachments contain confidential information from
Shenzhen CASTEL Wireless Telecommunications Co., Ltd.,
Which is intended only for the person or entity whose address is listed above.
Any use of theinformation contained herein in any way (Including,
but not limited to, total or partial disclosure,reproduction,
or dissemination) by persons other than the Intended recipient(s) is prohibited.
If you receive this e-mail in error, please notify the sender
by phone or email immediately and delete it!




_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to