From f7fd6bbce0cba86182b50dfbda8afd082b25dd9c Mon Sep 17 00:00:00 2001 From: Vladislav Bolkhovitin Date: Tue, 11 Sep 2012 01:26:48 +0000 Subject: [PATCH] qla2x00t: Display a clear error message if the kernel is too old For the people who try to build this driver before reading qla2x00t/qla2x00-target/README. Signed-off-by: Bart Van Assche git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@4510 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- qla2x00t/qla_os.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/qla2x00t/qla_os.c b/qla2x00t/qla_os.c index d6a894e24..3336574ee 100644 --- a/qla2x00t/qla_os.c +++ b/qla2x00t/qla_os.c @@ -4,8 +4,6 @@ * * See LICENSE.qla2xxx for copyright and licensing details. */ -#include "qla_def.h" - #include #include #include @@ -13,11 +11,16 @@ #include #include +#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 26) +#error Kernel 2.6.26 or above is needed to build the qla2x00t driver +#endif + #include #include #include #include +#include "qla_def.h" #include "qla2x_tgt.h" #ifndef RHEL_RELEASE_VERSION