Re: mvme68k timecounters.... untested
Garrett D'Amore <[email protected]> Sun, 17 Sep 2006 00:55:30 -0700
| Newsgroups | gmane.os.netbsd.ports.m68k,gmane.os.netbsd.ports.mvme68k |
|---|---|
| Message-ID | <[email protected]> |
Izumi Tsutsui wrote: > [email protected] wrote: > > >> + cnt += (0xffff - PCC_TIMER100HZ); /* adds 1600 */ >> > : > >> + /* record progress for timecounter */ >> + clock_pcc_count += (0xffff - PCC_TIMER100HZ); >> > > > These should use 0x10000 instead of 0xffff? > Yes. > Anyway, "pcc_timer_hz2lin(100)" macro is better. > Maybe. But the 0x10000 has to stand, because the counter counts _up_ from PCC_TIMER100HZ and ticks when it overflows to 0. I think the macro PCC_TIMER100HZ is actually easier to read, but I'm not terribly "close" to this platform. > Probably you also have to apply the similar changes against > sys/dev/mvme/clock_pcctwo.c. (shared with mvmeppc. umm) > Really? I know nothing about VME, really. Should this driver be shared? In any case I assumed that powerpc platforms would just use their on-chip cycle counters. > --- > Izumi Tsutsui > -- Garrett D'Amore, Principal Software Engineer Tadpole Computer / Computing Technologies Division, General Dynamics C4 Systems http://www.tadpolecomputer.com/ Phone: 951 325-2134 Fax: 951 325-2191