diff options
author | Michael Brown <mcb30@etherboot.org> | 2005-05-17 12:16:28 +0000 |
---|---|---|
committer | Michael Brown <mcb30@etherboot.org> | 2005-05-17 12:16:28 +0000 |
commit | 3bbf5f28a37e2dda53a835de59c99fdb6fdf631e (patch) | |
tree | 954b88c043ada9877855342dae041598c96a2238 /src/include/compiler.h | |
parent | 301b2d40f0f2604a698198142a1f420b737e56d4 (diff) | |
download | ipxe-3bbf5f28a37e2dda53a835de59c99fdb6fdf631e.tar.gz |
Use __unused instead of __used for static data structures.
Remove compiler.h defines from osdep.h
Diffstat (limited to 'src/include/compiler.h')
-rw-r--r-- | src/include/compiler.h | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/src/include/compiler.h b/src/include/compiler.h index 4912b4242..4a7c48a1c 100644 --- a/src/include/compiler.h +++ b/src/include/compiler.h @@ -84,9 +84,18 @@ __asm__ ( ".equ\tDEBUG_LEVEL, " DEBUG_SYMBOL_STR ); } while (0) #endif -#define PACKED __attribute__((packed)) -#define __unused __attribute__((unused)) -#define __used __attribute__((used)) +/* + * Commonly-used attributes. + * + * Note that __used can be used only for functions. If you have a + * static variable declaration that you want to force to be included, + * use __unused. + * + */ +#define PACKED __attribute__ (( packed )) +#define __unused __attribute__ (( unused )) +#define __used __attribute__ (( used )) +#define __aligned __attribute__ (( aligned ( 16 ) )) /* * To save space in the binary when multiple-driver images are |