From: Vladimir Sokolovsky Date: Wed, 28 Aug 2019 19:00:53 +0000 (-0500) Subject: Added support for iSERT on RHEL7.6 X-Git-Url: https://openfabrics.org/gitweb/?a=commitdiff_plain;h=db4a736d3a2f7f3a8d6f9b626e7c3ce11647fdd3;p=compat-rdma%2Fcompat.git Added support for iSERT on RHEL7.6 Signed-off-by: Vladimir Sokolovsky --- diff --git a/config/rdma.m4 b/config/rdma.m4 index 2b77c3c..fec82c2 100644 --- a/config/rdma.m4 +++ b/config/rdma.m4 @@ -4281,7 +4281,7 @@ AC_DEFUN([LINUX_CONFIG_COMPAT], AC_MSG_RESULT(no) ]) - AC_MSG_CHECKING([if iscsi_transport.h struct iscsit_transport has member iscsit_get_sup_prot_ops]) + AC_MSG_CHECKING([if iscsi_transport.h struct iscsit_transport has member iscsit_get_sup_prot_ops]) LB_LINUX_TRY_COMPILE([ #include @@ -4304,6 +4304,21 @@ AC_DEFUN([LINUX_CONFIG_COMPAT], AC_MSG_RESULT(no) ]) + AC_MSG_CHECKING([if iscsi_transport.h has iscsit_set_unsolicited_dataout]) + LB_LINUX_TRY_COMPILE([ + #include + + iscsit_set_unsolicited_dataout(NULL); + + return 0; + ],[ + AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_ISCSIT_SET_UNSOLICITED_DATAOUT, 1, + [iscsi_transport.h has iscsit_set_unsolicited_dataout]) + ],[ + AC_MSG_RESULT(no) + ]) + AC_MSG_CHECKING([if highmem.h has kmap_atomic function with km_type]) LB_LINUX_TRY_COMPILE([ #include diff --git a/include/linux/compat-2.6.h b/include/linux/compat-2.6.h index bc4a1b1..1a46957 100644 --- a/include/linux/compat-2.6.h +++ b/include/linux/compat-2.6.h @@ -60,6 +60,7 @@ void backport_dependency_symbol(void); #include #include #include +#include #include #endif /* CONFIG_COMPAT_RDMA */ diff --git a/include/linux/compat-5.1.h b/include/linux/compat-5.1.h new file mode 100644 index 0000000..07239d1 --- /dev/null +++ b/include/linux/compat-5.1.h @@ -0,0 +1,14 @@ +#ifndef LINUX_5_1_COMPAT_H +#define LINUX_5_1_COMPAT_H + +#include + +#if (LINUX_VERSION_CODE < KERNEL_VERSION(5,1,0)) + +#ifndef HAVE_ISCSIT_SET_UNSOLICITED_DATAOUT +#define iscsit_set_unsolicited_dataout iscsit_set_unsoliticed_dataout +#endif + +#endif /* (LINUX_VERSION_CODE < KERNEL_VERSION(5,1,0)) */ + +#endif /* LINUX_5_1_COMPAT_H */