[BACK]Return to timex.h CVS log [TXT][DIR] Up to [Development] / linux-2.6-xfs / include / asm-ppc64

File: [Development] / linux-2.6-xfs / include / asm-ppc64 / Attic / timex.h (download)

Revision 1.2, Wed Jan 5 14:17:31 2005 UTC (12 years, 9 months ago) by nathans.longdrop.melbourne.sgi.com
Branch: MAIN
Changes since 1.1: +0 -4 lines

Merge up to 2.6.10.
Merge of 2.6.x-xfs-melb:linux:21010a by kenmcd.

/*
 * linux/include/asm-ppc/timex.h
 *
 * PPC64 architecture timex specifications
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License
 * as published by the Free Software Foundation; either version
 * 2 of the License, or (at your option) any later version.
 */
#ifndef _ASMPPC64_TIMEX_H
#define _ASMPPC64_TIMEX_H

#define CLOCK_TICK_RATE	1193180 /* Underlying HZ */

typedef unsigned long cycles_t;

static inline cycles_t get_cycles(void)
{
	cycles_t ret;

	__asm__ __volatile__("mftb %0" : "=r" (ret) : );
	return ret;
}

#endif