Compare commits

...

2 Commits

Author SHA1 Message Date
Shaun Ruffell
c1d867b8b7 dahdi: Fix previous CentOS 6.5 commit.
The previous commit from earlier today to fix the backport of PDE_DATA was
wrong in that it would not then process the other defines for older kernels if
it detected it was running on a redhat release.

Signed-off-by: Shaun Ruffell <sruffell@digium.com>
(cherry picked from commit 71c003ba49)
2013-12-03 09:36:40 -06:00
Shaun Ruffell
1ff5629078 dahdi: CentOS 6.5 backported PDE_DATA definition.
This will fix the "error: redefinition of 'PDE_DATA'" error when compiling.

Internal-Issue-ID: DAHLIN-330
Signed-off-by: Shaun Ruffell <sruffell@digium.com>
(cherry picked from commit 5ec9d756aa)
2013-12-03 09:36:40 -06:00

View File

@@ -1402,6 +1402,8 @@ static inline short dahdi_txtone_nextsample(struct dahdi_chan *ss)
#define DAHDI_FORMAT_AUDIO_MASK ((1 << 16) - 1)
#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 10, 0)
#ifdef RHEL_RELEASE_VERSION
#if RHEL_RELEASE_CODE < RHEL_RELEASE_VERSION(6, 5)
#ifdef CONFIG_PROC_FS
#include <linux/proc_fs.h>
static inline void *PDE_DATA(const struct inode *inode)
@@ -1409,6 +1411,16 @@ static inline void *PDE_DATA(const struct inode *inode)
return PDE(inode)->data;
}
#endif
#endif
#else
#ifdef CONFIG_PROC_FS
#include <linux/proc_fs.h>
static inline void *PDE_DATA(const struct inode *inode)
{
return PDE(inode)->data;
}
#endif
#endif
#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 31)
#define KERN_CONT ""
#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 26)