X-Git-Url: http://git.liburcu.org/?a=blobdiff_plain;f=urcu%2Farch%2Fhppa.h;h=f92b0ab594b43cf801aab944a1b47bf6df82c0b5;hb=3fa182868e25068413fdaa1bef290365e99ab246;hp=61e8283886db941a9d0f48965ece1f25a0efc3c9;hpb=999991c6e4600c410181baea65bda9f406464872;p=userspace-rcu.git diff --git a/urcu/arch/hppa.h b/urcu/arch/hppa.h index 61e8283..f92b0ab 100644 --- a/urcu/arch/hppa.h +++ b/urcu/arch/hppa.h @@ -1,6 +1,26 @@ #ifndef _URCU_ARCH_HPPA_H #define _URCU_ARCH_HPPA_H +/* + * arch/hppa.h: definitions for hppa architecture + * + * Copyright (c) 2014 Helge Deller + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + */ + #include #include #include @@ -12,11 +32,12 @@ extern "C" { #include #include -typedef unsigned long cycles_t; +#define HAS_CAA_GET_CYCLES +typedef unsigned long caa_cycles_t; -static inline cycles_t caa_get_cycles(void) +static inline caa_cycles_t caa_get_cycles(void) { - cycles_t cycles; + caa_cycles_t cycles; asm volatile("mfctl 16, %0" : "=r" (cycles)); return cycles;