[PATCH][2/2][MIPS] move clockevent_set_clock() before clockevent_delta2ns()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



clockevent_delta2ns() use shift and mult value.
It should call clockevent_set_clock() first.
Pointed out by Atsushi Nemoto.

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@xxxxxxxxxxxxxx>

diff -pruN -X mips/Documentation/dontdiff mips-orig/arch/mips/kernel/cevt-gt641xx.c mips/arch/mips/kernel/cevt-gt641xx.c
--- mips-orig/arch/mips/kernel/cevt-gt641xx.c	2007-10-23 16:29:19.831141250 +0900
+++ mips/arch/mips/kernel/cevt-gt641xx.c	2007-10-23 16:29:09.702508250 +0900
@@ -131,9 +131,9 @@ static int __init gt641xx_timer0_clockev
 
 	cd = &gt641xx_timer0_clockevent;
 	cd->rating = 200 + gt641xx_base_clock / 10000000;
+	clockevent_set_clock(cd, gt641xx_base_clock);
 	cd->max_delta_ns = clockevent_delta2ns(0x7fffffff, cd);
 	cd->min_delta_ns = clockevent_delta2ns(0x300, cd);
-	clockevent_set_clock(cd, gt641xx_base_clock);
 
 	clockevents_register_device(&gt641xx_timer0_clockevent);
 


[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux