dahdi: Do not define dev_name if already backported.
RHEL 5.6 has backported dev_name in include/dahdi/devices.h. We now need to check for a back ported definition before defining our own version on pre 2.6.26 kernels. (closes issue #18992) Reported by: ndupeux, AlexCeli Tested by: elguero Signed-off-by: Tzafrir Cohen <tzafrir.cohen@xorcom.com> Acked-by: Shaun Ruffell <sruffell@digium.com> git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@9894 a0bf4364-ded3-4de4-8d8a-66a801d63aff
This commit is contained in:
committed by
Shaun Ruffell
parent
1ea9309756
commit
868dd3f0d5
@@ -87,7 +87,13 @@
|
||||
#endif
|
||||
|
||||
#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,26)
|
||||
#define dev_name(dev) (dev)->bus_id
|
||||
# ifdef RHEL_RELEASE_VERSION
|
||||
# if RHEL_RELEASE_CODE < RHEL_RELEASE_VERSION(5, 6)
|
||||
#define dev_name(dev) ((dev)->bus_id)
|
||||
# endif
|
||||
# else
|
||||
#define dev_name(dev) ((dev)->bus_id)
|
||||
# endif
|
||||
#define dev_set_name(dev, format, ...) \
|
||||
snprintf((dev)->bus_id, BUS_ID_SIZE, format, ## __VA_ARGS__);
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user