Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/bebox/bebox Change tick->ticks to avoid shadowing



details:   https://anonhg.NetBSD.org/src/rev/a0edd27dcf01
branches:  trunk
changeset: 581926:a0edd27dcf01
user:      jmc <jmc%NetBSD.org@localhost>
date:      Fri Jun 10 15:42:41 2005 +0000

description:
Change tick->ticks to avoid shadowing

diffstat:

 sys/arch/bebox/bebox/clock.c |  16 ++++++++--------
 1 files changed, 8 insertions(+), 8 deletions(-)

diffs (49 lines):

diff -r 3af5106e8604 -r a0edd27dcf01 sys/arch/bebox/bebox/clock.c
--- a/sys/arch/bebox/bebox/clock.c      Fri Jun 10 15:41:11 2005 +0000
+++ b/sys/arch/bebox/bebox/clock.c      Fri Jun 10 15:42:41 2005 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: clock.c,v 1.13 2004/06/29 12:01:11 kleink Exp $        */
+/*     $NetBSD: clock.c,v 1.14 2005/06/10 15:42:41 jmc Exp $   */
 /*      $OpenBSD: clock.c,v 1.3 1997/10/13 13:42:53 pefo Exp $  */
 
 /*
@@ -33,7 +33,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: clock.c,v 1.13 2004/06/29 12:01:11 kleink Exp $");
+__KERNEL_RCSID(0, "$NetBSD: clock.c,v 1.14 2005/06/10 15:42:41 jmc Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -57,7 +57,7 @@
        int msr;
        int pri;
        u_long tb;
-       long tick;
+       long ticks;
        int nticks;
        extern long intrcnt[];
 
@@ -71,16 +71,16 @@
         * Based on the actual time delay since the last decrementer reload,
         * we arrange for earlier interrupt next time.
         */
-       asm ("mftb %0; mfdec %1" : "=r"(tb), "=r"(tick));
-       for (nticks = 0; tick < 0; nticks++)
-               tick += ticks_per_intr;
-       asm volatile ("mtdec %0" :: "r"(tick));
+       asm ("mftb %0; mfdec %1" : "=r"(tb), "=r"(ticks));
+       for (nticks = 0; ticks < 0; nticks++)
+               ticks += ticks_per_intr;
+       asm volatile ("mtdec %0" :: "r"(ticks));
 
        /*
         * lasttb is used during microtime. Set it to the virtual
         * start of this tick interval.
         */
-       lasttb = tb + tick - ticks_per_intr;
+       lasttb = tb + ticks - ticks_per_intr;
 
        intrcnt[CNT_CLOCK]++;
 



Home | Main Index | Thread Index | Old Index