Fix rt_mutex_lock_interruptible() again for RT >= 3.2

This commit is contained in:
Bjarne von Horn
2024-06-06 17:10:13 +02:00
parent d71e362a5e
commit 93b60bb812
2 changed files with 4 additions and 2 deletions

View File

@@ -62,7 +62,8 @@
#else #else
# define ec_ioctl_lock(lock) rt_mutex_lock(lock) # define ec_ioctl_lock(lock) rt_mutex_lock(lock)
# define ec_ioctl_unlock(lock) rt_mutex_unlock(lock) # define ec_ioctl_unlock(lock) rt_mutex_unlock(lock)
# if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 17, 0) # if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 17, 0) || \
(defined(CONFIG_PREEMPT_RT_FULL) && LINUX_VERSION_CODE >= KERNEL_VERSION(3, 2, 0))
# define ec_ioctl_lock_interruptible(lock) \ # define ec_ioctl_lock_interruptible(lock) \
rt_mutex_lock_interruptible(lock) rt_mutex_lock_interruptible(lock)
# else # else

View File

@@ -52,7 +52,8 @@
#include "ethernet.h" #include "ethernet.h"
#endif #endif
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 17, 0) #if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 17, 0) || \
(defined(CONFIG_PREEMPT_RT_FULL) && LINUX_VERSION_CODE >= KERNEL_VERSION(3, 2, 0))
# define ec_rt_lock_interruptible(lock) \ # define ec_rt_lock_interruptible(lock) \
rt_mutex_lock_interruptible(lock) rt_mutex_lock_interruptible(lock)
#else #else