From d88a9f5bd9a4b33daef9ab39eb6cff1fafb18c09 Mon Sep 17 00:00:00 2001 From: jacob Date: Fri, 1 Aug 2003 18:37:16 +0000 Subject: [PATCH] - Fix build with rh 2.4.20 kernel series r=phil b=1663 --- lnet/include/linux/portals_compat25.h | 13 ++++++++++++- lustre/portals/include/linux/portals_compat25.h | 13 ++++++++++++- 2 files changed, 24 insertions(+), 2 deletions(-) diff --git a/lnet/include/linux/portals_compat25.h b/lnet/include/linux/portals_compat25.h index a7cb4d1..43618589 100644 --- a/lnet/include/linux/portals_compat25.h +++ b/lnet/include/linux/portals_compat25.h @@ -18,7 +18,7 @@ #endif // XXX BUG 1511 -- remove this stanza and all callers when bug 1511 is resolved -#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0)) || defined(CONFIG_RH_2_4_20) +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0)) # define SIGNAL_MASK_LOCK(task, flags) \ spin_lock_irqsave(&task->sighand->siglock, flags) @@ -29,6 +29,17 @@ # define RECALC_SIGPENDING recalc_sigpending() # define CURRENT_SECONDS get_seconds() +#elif defined(CONFIG_RH_2_4_20) /* RH 2.4.x */ + +# define SIGNAL_MASK_LOCK(task, flags) \ + spin_lock_irqsave(&task->sighand->siglock, flags) +# define SIGNAL_MASK_UNLOCK(task, flags) \ + spin_unlock_irqrestore(&task->sighand->siglock, flags) +# define USERMODEHELPER(path, argv, envp) \ + call_usermodehelper(path, argv, envp) +# define RECALC_SIGPENDING recalc_sigpending() +# define CURRENT_SECONDS CURRENT_TIME + #else /* 2.4.x */ # define SIGNAL_MASK_LOCK(task, flags) \ diff --git a/lustre/portals/include/linux/portals_compat25.h b/lustre/portals/include/linux/portals_compat25.h index a7cb4d1..43618589 100644 --- a/lustre/portals/include/linux/portals_compat25.h +++ b/lustre/portals/include/linux/portals_compat25.h @@ -18,7 +18,7 @@ #endif // XXX BUG 1511 -- remove this stanza and all callers when bug 1511 is resolved -#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0)) || defined(CONFIG_RH_2_4_20) +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0)) # define SIGNAL_MASK_LOCK(task, flags) \ spin_lock_irqsave(&task->sighand->siglock, flags) @@ -29,6 +29,17 @@ # define RECALC_SIGPENDING recalc_sigpending() # define CURRENT_SECONDS get_seconds() +#elif defined(CONFIG_RH_2_4_20) /* RH 2.4.x */ + +# define SIGNAL_MASK_LOCK(task, flags) \ + spin_lock_irqsave(&task->sighand->siglock, flags) +# define SIGNAL_MASK_UNLOCK(task, flags) \ + spin_unlock_irqrestore(&task->sighand->siglock, flags) +# define USERMODEHELPER(path, argv, envp) \ + call_usermodehelper(path, argv, envp) +# define RECALC_SIGPENDING recalc_sigpending() +# define CURRENT_SECONDS CURRENT_TIME + #else /* 2.4.x */ # define SIGNAL_MASK_LOCK(task, flags) \ -- 1.8.3.1