From ac156d84c0253576aae7ef7fd13d40fa0dc20a1c Mon Sep 17 00:00:00 2001 From: Bart Van Assche Date: Thu, 9 Jul 2015 19:12:09 +0000 Subject: [PATCH] scst.h: Add cpumask_var_t for kernel versions before 2.6.28 git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@6412 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- scst/include/scst.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/scst/include/scst.h b/scst/include/scst.h index 8b9f490d2..c95b6e143 100644 --- a/scst/include/scst.h +++ b/scst/include/scst.h @@ -150,7 +150,12 @@ static inline int scsi_bidi_cmnd(struct scsi_cmnd *cmd) } #endif -#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 28) +#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 28) && defined(__LINUX_CPUMASK_H) +/* + * See also patch "cpumask: introduce new API, without changing anything" + * (commit ID 2d3854a37e8b). + */ +typedef cpumask_t cpumask_var_t[1]; #define cpumask_bits(maskp) ((maskp)->bits) #ifdef CONFIG_CPUMASK_OFFSTACK /* Assuming NR_CPUS is huge, a runtime limit is more efficient. Also,