scst: Rework SCSI pass-through support for kernel versions >= 2.6.30

Changes in this patch:
- Rework the SCSI pass-through code such that for kernel versions
  >= 2.6.30 the scst_exec_req_fifo patch is no longer needed.
- Modify the pass-through code such that blk_rq_append_bio() is only
  called for kernel version 2.6.30. For later kernel versions
  blk_make_request() is called instead.
- Rework scst_scsi_exec_async().
- Add debug tracing of SCSI pass-through result status.
- Add a lockdep_assert_held() call in scsi_end_async().



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5979 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
Bart Van Assche
2015-01-20 15:04:23 +00:00
parent cab2a22480
commit 628f3939bc
44 changed files with 437 additions and 16537 deletions
+1
View File
@@ -282,6 +282,7 @@ for p in scst/kernel/*-${kver}.patch \
echo iscsi-scst/kernel/patches/*-${kver}.patch;
fi)
do
[ -e "$p" ] || continue
# Exclude the put_page_callback patch when command-line option -u has been
# specified since the current approach is not considered acceptable for
# upstream kernel inclusion. See also http://lkml.org/lkml/2008/12/11/213.
+9 -13
View File
@@ -220,11 +220,7 @@ cd SPECS
log "Copying SCST patches to the SOURCES directory"
cd ${rpmbuild_dir}/SOURCES
copy_best_matching_patch $scst_dir/scst/kernel/rhel/scst_exec_req_fifo scst_exec_req_fifo.patch ||
{
echo "No matching scst_exec_req_fifo patch found for kernel version $kver";
exit 1;
}
copy_best_matching_patch $scst_dir/scst/kernel/rhel/scst_exec_req_fifo scst_exec_req_fifo.patch
copy_best_matching_patch $scst_dir/iscsi-scst/kernel/patches/rhel/put_page_callback put_page_callback.patch ||
{
echo "No matching put_page_callback patch found for kernel version $kver";
@@ -300,7 +296,7 @@ diff -u SPECS/kernel.spec{.orig,}
Source82: config-s390x-debug
Source83: config-s390x-debug-rhel
+Patch200: scst_exec_req_fifo.patch
+#Patch200: scst_exec_req_fifo.patch
+Patch201: put_page_callback.patch
+
# empty final patch file to facilitate testing of kernel patches
@@ -310,7 +306,7 @@ diff -u SPECS/kernel.spec{.orig,}
# Dynamically generate kernel .config files from config-* files
make -f %{SOURCE20} VERSION=%{version} configs
+ApplyPatch scst_exec_req_fifo.patch
+#ApplyPatch scst_exec_req_fifo.patch
+ApplyPatch put_page_callback.patch
+
ApplyOptionalPatch linux-kernel-test.patch
@@ -339,7 +335,7 @@ diff -u SPECS/kernel.spec{.orig,}
Source82: config-generic
Source83: config-x86_64-debug-rhel
+Patch200: scst_exec_req_fifo.patch
+#Patch200: scst_exec_req_fifo.patch
+Patch201: put_page_callback.patch
+
# empty final patch file to facilitate testing of kernel patches
@@ -349,7 +345,7 @@ diff -u SPECS/kernel.spec{.orig,}
# Dynamically generate kernel .config files from config-* files
make -f %{SOURCE20} VERSION=%{version} configs
+ApplyPatch scst_exec_req_fifo.patch
+#ApplyPatch scst_exec_req_fifo.patch
+ApplyPatch put_page_callback.patch
+
ApplyOptionalPatch linux-kernel-test.patch
@@ -375,7 +371,7 @@ diff -u SPECS/kernel.spec{.orig,}
Source85: config-powerpc64-debug-rhel
Source86: config-s390x-debug-rhel
+Patch200: scst_exec_req_fifo.patch
+#Patch200: scst_exec_req_fifo.patch
+Patch201: put_page_callback.patch
+
# empty final patch file to facilitate testing of kernel patches
@@ -385,7 +381,7 @@ diff -u SPECS/kernel.spec{.orig,}
# Dynamically generate kernel .config files from config-* files
make -f %{SOURCE20} VERSION=%{version} configs
+ApplyPatch scst_exec_req_fifo.patch
+#ApplyPatch scst_exec_req_fifo.patch
+ApplyPatch put_page_callback.patch
+
ApplyOptionalPatch linux-kernel-test.patch
@@ -418,7 +414,7 @@ patch -p1 ${rpmbuild_dir}/SPECS/kernel.spec <<'EOF' || exit $?
Source2000: cpupower.service
Source2001: cpupower.config
+Patch200: scst_exec_req_fifo.patch
+#Patch200: scst_exec_req_fifo.patch
+Patch201: put_page_callback.patch
+
# empty final patch to facilitate testing of kernel patches
@@ -428,7 +424,7 @@ patch -p1 ${rpmbuild_dir}/SPECS/kernel.spec <<'EOF' || exit $?
# Drop some necessary files from the source dir into the buildroot
cp $RPM_SOURCE_DIR/kernel-%{version}-*.config .
+ApplyPatch scst_exec_req_fifo.patch
+#ApplyPatch scst_exec_req_fifo.patch
+ApplyPatch put_page_callback.patch
+
ApplyOptionalPatch linux-kernel-test.patch