/* SPDX-License-Identifier: GPL-2.0-or-later */1/*2* OpenRISC Linux3*4* Linux architectural port borrowing liberally from similar works of5* others. All original copyrights apply as per the original source6* declaration.7*8* OpenRISC implementation:9* Copyright (C) 2010-2011 Jonas Bonn <[email protected]>10*/1112#ifndef __ASM_OPENRISC_TIMEX_H13#define __ASM_OPENRISC_TIMEX_H1415#define get_cycles get_cycles1617#include <asm-generic/timex.h>18#include <asm/spr.h>19#include <asm/spr_defs.h>2021static inline cycles_t get_cycles(void)22{23return mfspr(SPR_TTCR);24}25#define get_cycles get_cycles2627/* This isn't really used any more */28#define CLOCK_TICK_RATE 10002930#define ARCH_HAS_READ_CURRENT_TIMER3132#endif333435