summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorShaun Ruffell <sruffell@digium.com>2011-06-28 15:55:38 +0000
committerShaun Ruffell <sruffell@digium.com>2011-06-28 15:55:38 +0000
commitbe132e667529757d25d0f655aa6b3a8a9ab0ed51 (patch)
treebab14ae34b7b072f2cdc75af621ba21fa98056a8 /include
parent11f0e72cb7cc4bc0db2a816668c8e07399e26b28 (diff)
kernel.h: Define __packed if not already defined.
Linux kernel v2.6.22 introduced the __packed macro to allow the gcc specific __attribute__((packed)) extension to be overridden if required and checkpatch.pl will complain if you don't use it. For some strange reason gcc doesn't complain when you use non-existant decorators. Signed-off-by: Shaun Ruffell <sruffell@digium.com> Signed-off-by: Russ Meyerriecks <rmeyerriecks@digium.com> git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@9989 a0bf4364-ded3-4de4-8d8a-66a801d63aff
Diffstat (limited to 'include')
-rw-r--r--include/dahdi/kernel.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/dahdi/kernel.h b/include/dahdi/kernel.h
index 97e1231..772a4fe 100644
--- a/include/dahdi/kernel.h
+++ b/include/dahdi/kernel.h
@@ -1326,6 +1326,11 @@ static inline short dahdi_txtone_nextsample(struct dahdi_chan *ss)
(signal_pending((p)) && sigismember(&(p)->pending.signal, SIGKILL))
#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 22)
+
+#ifndef __packed
+#define __packed __attribute__((packed))
+#endif
+
#include <linux/ctype.h>
/* A define of 'clamp_val' happened to be added in the patch
* linux-2.6-sata-prep-work-for-rhel5-3.patch kernel-2.6.spec that also