diff options
author | Mark Kettenis <kettenis@cvs.openbsd.org> | 2013-03-17 15:10:34 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@cvs.openbsd.org> | 2013-03-17 15:10:34 +0000 |
commit | ea6735234419cbcd06a29a10a81b86cdcc96fca0 (patch) | |
tree | 8d54491601390b0cb67a74188f84f8ec615932f4 | |
parent | 30859c2f1ac60a5ecf0c3c940138b672d18bb082 (diff) |
Avoid namespace pollution from <powerpc/cpu.h>.
ok mpi@, deraadt@, miod@, millert@
-rw-r--r-- | sys/arch/macppc/include/cpu.h | 11 | ||||
-rw-r--r-- | sys/arch/socppc/include/cpu.h | 11 |
2 files changed, 14 insertions, 8 deletions
diff --git a/sys/arch/macppc/include/cpu.h b/sys/arch/macppc/include/cpu.h index 48f2f982425..0cd4ce37c54 100644 --- a/sys/arch/macppc/include/cpu.h +++ b/sys/arch/macppc/include/cpu.h @@ -1,4 +1,4 @@ -/* $OpenBSD: cpu.h,v 1.11 2012/12/08 12:51:34 mpi Exp $ */ +/* $OpenBSD: cpu.h,v 1.12 2013/03/17 15:10:33 kettenis Exp $ */ /* $NetBSD: cpu.h,v 1.1 1996/09/30 16:34:21 ws Exp $ */ /* @@ -34,8 +34,6 @@ #ifndef _MACHINE_CPU_H_ #define _MACHINE_CPU_H_ -#include <powerpc/cpu.h> - /* * CTL_MACHDEP definitions. */ @@ -49,6 +47,10 @@ { "altivec", CTLTYPE_INT }, \ } +#ifdef _KERNEL + +#include <powerpc/cpu.h> + /* Frequency scaling */ #define FREQ_FULL 0 #define FREQ_HALF 1 @@ -60,4 +62,5 @@ extern int ppc_altivec; extern void (*ppc64_slew_voltage)(u_int); -#endif /* _MACHINE_CPU_H_ */ +#endif /* _KERNEL */ +#endif /* _MACHINE_CPU_H_ */ diff --git a/sys/arch/socppc/include/cpu.h b/sys/arch/socppc/include/cpu.h index 9e21d0c6084..a338e8ceeb5 100644 --- a/sys/arch/socppc/include/cpu.h +++ b/sys/arch/socppc/include/cpu.h @@ -1,4 +1,4 @@ -/* $OpenBSD: cpu.h,v 1.1 2008/05/10 12:02:21 kettenis Exp $ */ +/* $OpenBSD: cpu.h,v 1.2 2013/03/17 15:10:33 kettenis Exp $ */ /* $NetBSD: cpu.h,v 1.1 1996/09/30 16:34:21 ws Exp $ */ /* @@ -35,8 +35,6 @@ #ifndef _MACHINE_CPU_H_ #define _MACHINE_CPU_H_ -#include <powerpc/cpu.h> - /* * CTL_MACHDEP definitions. */ @@ -50,4 +48,9 @@ { "altivec", CTLTYPE_INT }, \ } -#endif /* _MACHINE_CPU_H_ */ +#ifdef _KERNEL + +#include <powerpc/cpu.h> + +#endif /* _KERNEL */ +#endif /* _MACHINE_CPU_H_ */ |