From 9c130c6e14be8da248670e629e9a020e5cb25110 Mon Sep 17 00:00:00 2001 From: Bart Van Assche Date: Tue, 10 Nov 2015 15:32:52 +0000 Subject: [PATCH] backport.h: Fix build on 3.2.x kernels for versions >= 3.2.52 git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@6653 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- scst/include/backport.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/scst/include/backport.h b/scst/include/backport.h index f349bb80a..790bb3e1d 100644 --- a/scst/include/backport.h +++ b/scst/include/backport.h @@ -427,7 +427,9 @@ static inline void sg_set_page(struct scatterlist *sg, struct page *page, (__flags), NULL, NULL) #endif -#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 4, 0) +#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 4, 0) && \ + !(LINUX_VERSION_CODE >= KERNEL_VERSION(3, 2, 52) && \ + LINUX_VERSION_CODE < KERNEL_VERSION(3, 3, 0)) static inline void *kmalloc_array(size_t n, size_t size, gfp_t flags) { if (size != 0 && n > ULONG_MAX / size)