aboutsummaryrefslogtreecommitdiff
path: root/sys/ia64/include/param.h
diff options
context:
space:
mode:
authorSam Leffler <sam@FreeBSD.org>2009-07-05 17:45:48 +0000
committerSam Leffler <sam@FreeBSD.org>2009-07-05 17:45:48 +0000
commit8c393fd1f0cc514a007104469b11eaeeefb829b6 (patch)
tree5014c430476acd9a353d9342a22288dd1b848162 /sys/ia64/include/param.h
parent559bfa18dce5da2a1ffd664bc16e2c4a6e49d8fc (diff)
downloadsrc-8c393fd1f0cc514a007104469b11eaeeefb829b6.tar.gz
src-8c393fd1f0cc514a007104469b11eaeeefb829b6.zip
Cleanup ALIGNED_POINTER:
o add to platforms where it was missing (arm, i386, powerpc, sparc64, sun4v) o define as "1" on amd64 and i386 where there is no restriction o make the type returned consistent with ALIGN o remove _ALIGNED_POINTER o make associated comments consistent Reviewed by: bde, imp, marcel Approved by: re (kensmith)
Notes
Notes: svn path=/head/; revision=195376
Diffstat (limited to 'sys/ia64/include/param.h')
-rw-r--r--sys/ia64/include/param.h20
1 files changed, 3 insertions, 17 deletions
diff --git a/sys/ia64/include/param.h b/sys/ia64/include/param.h
index f59c40883b79..cb805a6b344e 100644
--- a/sys/ia64/include/param.h
+++ b/sys/ia64/include/param.h
@@ -46,12 +46,6 @@
* Round p (pointer or byte index) up to a correctly-aligned value for all
* data types (int, long, ...). The result is u_long and must be cast to
* any desired pointer type.
- *
- * ALIGNED_POINTER is a boolean macro that checks whether an address
- * is valid to fetch data elements of type t from on this architecture.
- * This does not reflect the optimal alignment, just the possibility
- * (within reasonable limits).
- *
*/
#ifndef _ALIGNBYTES
#define _ALIGNBYTES 15
@@ -59,9 +53,6 @@
#ifndef _ALIGN
#define _ALIGN(p) (((u_long)(p) + _ALIGNBYTES) &~ _ALIGNBYTES)
#endif
-#ifndef _ALIGNED_POINTER
-#define _ALIGNED_POINTER(p,t) ((((u_long)(p)) & (sizeof(t)-1)) == 0)
-#endif
#ifndef _NO_NAMESPACE_POLLUTION
@@ -84,20 +75,15 @@
#define MAXCPU 1
#endif
+#define ALIGNBYTES _ALIGNBYTES
+#define ALIGN(p) _ALIGN(p)
/*
- * Round p (pointer or byte index) up to a correctly-aligned value for all
- * data types (int, long, ...). The result is u_long and must be cast to
- * any desired pointer type.
- *
* ALIGNED_POINTER is a boolean macro that checks whether an address
* is valid to fetch data elements of type t from on this architecture.
* This does not reflect the optimal alignment, just the possibility
* (within reasonable limits).
- *
*/
-#define ALIGNBYTES _ALIGNBYTES
-#define ALIGN(p) _ALIGN(p)
-#define ALIGNED_POINTER(p,t) _ALIGNED_POINTER(p,t)
+#define ALIGNED_POINTER(p,t) ((((u_long)(p)) & (sizeof(t)-1)) == 0)
/*
* CACHE_LINE_SIZE is the compile-time maximum cache line size for an