Browse Source

net: bugfix: NetSetTimeout assumes CONFIG_SYS_HZ=1000

NetSetTimeout sets incorrect value to timeDelta when CONFIG_SYS_HZ != 1000.

Signed-off-by: Tetsuyuki Kobayashi <koba@kmckk.co.jp>
Tetsuyuki Kobayashi 13 years ago
parent
commit
1389f98fce
1 changed files with 1 additions and 1 deletions
  1. 1 1
      net/net.c

+ 1 - 1
net/net.c

@@ -652,7 +652,7 @@ NetSetTimeout(ulong iv, thand_f *f)
 			"--- NetLoop timeout handler set (%p)\n", f);
 		timeHandler = f;
 		timeStart = get_timer(0);
-		timeDelta = iv;
+		timeDelta = iv * CONFIG_SYS_HZ / 1000;
 	}
 }