Source-Changes-HG archive

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

[src/trunk]: src/sys/arch mftb() has moved to cpu.h.



details:   https://anonhg.NetBSD.org/src/rev/8f1ae75361b9
branches:  trunk
changeset: 534956:8f1ae75361b9
user:      chs <chs%NetBSD.org@localhost>
date:      Wed Aug 07 05:20:46 2002 +0000

description:
mftb() has moved to cpu.h.

diffstat:

 sys/arch/bebox/bebox/clock.c |  13 +------------
 sys/arch/ofppc/ofppc/clock.c |  13 +------------
 2 files changed, 2 insertions(+), 24 deletions(-)

diffs (54 lines):

diff -r 37d7adc83981 -r 8f1ae75361b9 sys/arch/bebox/bebox/clock.c
--- a/sys/arch/bebox/bebox/clock.c      Wed Aug 07 05:18:21 2002 +0000
+++ b/sys/arch/bebox/bebox/clock.c      Wed Aug 07 05:20:46 2002 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: clock.c,v 1.9 2001/08/26 02:47:35 matt Exp $   */
+/*     $NetBSD: clock.c,v 1.10 2002/08/07 05:20:46 chs Exp $   */
 /*      $OpenBSD: clock.c,v 1.3 1997/10/13 13:42:53 pefo Exp $  */
 
 /*
@@ -115,17 +115,6 @@
        asm volatile ("mtdec %0" :: "r"(ticks_per_intr));
 }
 
-static inline u_quad_t
-mftb(void)
-{
-       u_long scratch;
-       u_quad_t tb;
-       
-       asm ("1: mftbu %0; mftb %0+1; mftbu %1; cmpw %0,%1; bne 1b"
-           : "=r"(tb), "=r"(scratch));
-       return tb;
-}
-
 /*
  * Fill in *tvp with current time with microsecond resolution.
  */
diff -r 37d7adc83981 -r 8f1ae75361b9 sys/arch/ofppc/ofppc/clock.c
--- a/sys/arch/ofppc/ofppc/clock.c      Wed Aug 07 05:18:21 2002 +0000
+++ b/sys/arch/ofppc/ofppc/clock.c      Wed Aug 07 05:20:46 2002 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: clock.c,v 1.5 2001/08/26 02:47:40 matt Exp $   */
+/*     $NetBSD: clock.c,v 1.6 2002/08/07 05:20:47 chs Exp $    */
 
 /*
  * Copyright (C) 1995, 1996 Wolfgang Solfrank.
@@ -125,17 +125,6 @@
        __asm __volatile ("mtmsr %0" :: "r"(msr));
 }
 
-static inline u_quad_t
-mftb(void)
-{
-       u_long scratch;
-       u_quad_t tb;
-       
-       asm ("1: mftbu %0; mftb %0+1; mftbu %1; cmpw 0,%0,%1; bne 1b"
-           : "=r"(tb), "=r"(scratch));
-       return tb;
-}
-
 /*
  * Fill in *tvp with current time with microsecond resolution.
  */



Home | Main Index | Thread Index | Old Index