浏览代码

i.mx change get_timer(base) to return time since base

This patch changes get_timer() for i.MX to return the time since
'base' instead of the time since the counter was at zero.

Symptom seen is flash timeout errors when erasing or programming a
sector using the common cfi flash code.

Signed-off-by: Andrew Dyer <adyer@righthandtech.com>
Andrew Dyer 16 年之前
父节点
当前提交
274737e5eb
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      cpu/arm920t/imx/interrupts.c

+ 1 - 1
cpu/arm920t/imx/interrupts.c

@@ -60,7 +60,7 @@ void reset_timer (void)
 
 ulong get_timer (ulong base)
 {
-	return get_timer_masked ();
+	return get_timer_masked() - base;
 }
 
 void set_timer (ulong t)