summaryrefslogtreecommitdiff
path: root/include/common.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/common.h')
-rw-r--r--include/common.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/include/common.h b/include/common.h
index c6eeb11fef..235540d220 100644
--- a/include/common.h
+++ b/include/common.h
@@ -32,9 +32,14 @@
#define REG16(addr) (*(volatile uint16_t *)(addr))
/*
- * Define __packed if someone hasn't beat us to it. Linux kernel style
- * checking prefers __packed over __attribute__((packed)).
+ * Define __aligned(n) and __packed if someone hasn't beat us to it. Linux
+ * kernel style checking prefers these over __attribute__((packed)) and
+ * __attribute__((aligned(n))).
*/
+#ifndef __aligned
+#define __aligned(n) __attribute__((aligned(n)))
+#endif
+
#ifndef __packed
#define __packed __attribute__((packed))
#endif