Added scsi_tgt-related source files.

git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2171 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
Bart Van Assche
2010-09-22 18:59:04 +00:00
parent 1f709fecfe
commit 780d8b439c
2 changed files with 33 additions and 10 deletions
+14 -4
View File
@@ -382,17 +382,20 @@ function compile_kernel {
# For more information about endianness annotations, see also
# http://lwn.net/Articles/205624/.
function run_sparse {
local k="$1"
local kver="$(kernel_version $1)"
local plevel="$(patchlevel $1)"
local outputfile="${outputdir}/sparse-$1-output.txt"
local subdir="$2"
shift
shift
echo "Running sparse on the patched kernel ..."
(
cd "${outputdir}/linux-$1" \
echo "Running sparse on the patched kernel in ${subdir} $@ ..."
(
cd "${outputdir}/linux-$k" \
&& make -s prepare \
&& make -s scripts \
&& LC_ALL=C make -k C=2 CF=-D__CHECK_ENDIAN__ M="${subdir}"
&& LC_ALL=C make -k C=2 CF=-D__CHECK_ENDIAN__ M="${subdir}" "$@"
) &> "${outputfile}"
local errors=$(grep -c ' error:' "${outputfile}")
local warnings=$(grep -c ' warning:' "${outputfile}")
@@ -593,6 +596,13 @@ do
patch_and_configure_kernel $k
if [ "${run_sparse}" = "true" ]; then
run_sparse $k drivers/scst
mv ${outputdir}/sparse-$k-output.txt ${outputdir}/sparse-$k-scst-output.txt
if [ "$k" = "2.6.35" ]; then
run_sparse $k drivers/scsi libsrp.ko scsi_sysfs.ko \
scsi_transport_fc.ko scsi_transport_srp.ko
mv ${outputdir}/sparse-$k-output.txt \
${outputdir}/sparse-$k-scsi-output.txt
fi
fi
compile_kernel $k drivers/scst
if [ "${full_check}" = "true" ]; then