diff options
-rw-r--r-- | sys/alpha/include/globals.h | 16 | ||||
-rw-r--r-- | sys/ia64/include/globals.h | 16 | ||||
-rw-r--r-- | sys/powerpc/include/globals.h | 22 |
3 files changed, 27 insertions, 27 deletions
diff --git a/sys/alpha/include/globals.h b/sys/alpha/include/globals.h index 10de1b7..496235a 100644 --- a/sys/alpha/include/globals.h +++ b/sys/alpha/include/globals.h @@ -35,18 +35,18 @@ register struct globaldata *globalp __asm__("$8"); #if 1 -#define GLOBALP globalp +#define GLOBALP globalp #else -#define GLOBALP ((struct globaldata *) alpha_pal_rdval()) +#define GLOBALP ((struct globaldata *) alpha_pal_rdval()) #endif -#define PCPU_GET(name) (GLOBALP->gd_##name) -#define PCPU_PTR(name) (&GLOBALP->gd_##name) -#define PCPU_SET(name,value) (GLOBALP->gd_##name = (value)) +#define PCPU_GET(member) (GLOBALP->gd_ ## member) +#define PCPU_PTR(member) (&GLOBALP->gd_ ## member) +#define PCPU_SET(member,value) (GLOBALP->gd_ ## member = (value)) -#define CURPROC PCPU_GET(curproc) -#define CURTHD PCPU_GET(curproc) /* temporary */ -#define curproc PCPU_GET(curproc) +#define CURPROC PCPU_GET(curproc) +#define CURTHD PCPU_GET(curproc) /* temporary */ +#define curproc PCPU_GET(curproc) #endif /* _KERNEL */ diff --git a/sys/ia64/include/globals.h b/sys/ia64/include/globals.h index 9f879ce..81a4387 100644 --- a/sys/ia64/include/globals.h +++ b/sys/ia64/include/globals.h @@ -35,18 +35,18 @@ register struct globaldata *globalp __asm__("r13"); #if 1 -#define GLOBALP globalp +#define GLOBALP globalp #else -#define GLOBALP ((struct globaldata *) alpha_pal_rdval()) +#define GLOBALP ((struct globaldata *) alpha_pal_rdval()) #endif -#define PCPU_GET(name) (GLOBALP->gd_##name) -#define PCPU_PTR(name) (&GLOBALP->gd_##name) -#define PCPU_SET(name,value) (GLOBALP->gd_##name = (value)) +#define PCPU_GET(member) (GLOBALP->gd_ ## member) +#define PCPU_PTR(member) (&GLOBALP->gd_ ## member) +#define PCPU_SET(member,value) (GLOBALP->gd_ ## member = (value)) -#define CURPROC PCPU_GET(curproc) -#define CURTHD PCPU_GET(curproc) /* temporary */ -#define curproc PCPU_GET(curproc) +#define CURPROC PCPU_GET(curproc) +#define CURTHD PCPU_GET(curproc) /* temporary */ +#define curproc PCPU_GET(curproc) #endif /* _KERNEL */ diff --git a/sys/powerpc/include/globals.h b/sys/powerpc/include/globals.h index 286e5eb..26c21e8 100644 --- a/sys/powerpc/include/globals.h +++ b/sys/powerpc/include/globals.h @@ -35,9 +35,9 @@ #define GLOBALP ((struct globaldata *) powerpc_get_globalp()) -#define PCPU_GET(name) (GLOBALP->gd_##name) -#define PCPU_PTR(name) (&GLOBALP->gd_##name) -#define PCPU_SET(name,value) (GLOBALP->gd_##name = (value)) +#define PCPU_GET(member) (GLOBALP->gd_ ## member) +#define PCPU_PTR(member) (&GLOBALP->gd_ ## member) +#define PCPU_SET(member,value) (GLOBALP->gd_ ## member = (value)) /* * The following set of macros works for UP kernel as well, but for maximum @@ -45,14 +45,14 @@ * other hand, kernel modules should always use these macros to maintain * portability between UP and SMP kernels. */ -#define CURPROC PCPU_GET(curproc) -#define CURTHD PCPU_GET(curproc) /* temporary */ -#define curproc PCPU_GET(curproc) -#define idleproc PCPU_GET(idleproc) -#define curpcb PCPU_GET(curpcb) -#define fpcurproc PCPU_GET(fpcurproc) -#define switchtime PCPU_GET(switchtime) -#define switchticks PCPU_GET(switchticks) +#define CURPROC PCPU_GET(curproc) +#define CURTHD PCPU_GET(curproc) /* temporary */ +#define curproc PCPU_GET(curproc) +#define idleproc PCPU_GET(idleproc) +#define curpcb PCPU_GET(curpcb) +#define fpcurproc PCPU_GET(fpcurproc) +#define switchtime PCPU_GET(switchtime) +#define switchticks PCPU_GET(switchticks) #define witness_spin_check PCPU_GET(witness_spin_check) #endif /* _KERNEL */ |