Commit Graph

4277 Commits

Author SHA1 Message Date
Bart Van Assche
56fbcf3ce5 srpt/Makefile: SLES + Mellanox OFED build fix
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5681 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-18 09:28:22 +00:00
Bart Van Assche
1ba2b87afa srpt/Makefile: Remove a superfluous assignment statement
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5680 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-18 09:27:41 +00:00
Bart Van Assche
47e087abb4 ib_srpt: Fix Mellanox OFED build
Use the proper include directory when building against Mellanox OFED.
Do not require to remove /lib/modules/$(KVER)/kernel/drivers/infiniband
before building ib_srpt.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5679 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-16 08:29:16 +00:00
Bart Van Assche
bd2625ec1a scst-devel rpm: Include /usr/include/scst/scst_itf_ver.h
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5678 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-16 05:35:40 +00:00
Vladislav Bolkhovitin
2df2e90317 Install scst_itf_ver.h as well
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5677 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-16 03:27:20 +00:00
Bart Van Assche
71acb70c35 nightly build: Update kernel versions
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5676 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-13 07:15:05 +00:00
Vladislav Bolkhovitin
1448cc6c5a BLOCKIO microoptimization: use per-device biosets
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5675 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-12 00:53:46 +00:00
Bart Van Assche
ba876f77d4 scripts/generate-kernel-patch: Remove trailing whitespace
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5674 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-11 07:54:19 +00:00
Bart Van Assche
586ab2f547 scripts/generate-kernel-patch: Also generate scst-itf-ver.h
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5673 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-11 06:48:49 +00:00
Bart Van Assche
77f6bac7ec scripts/rebuild-rhel-kernel-rpm: Move code for downloading a RHEL (clone) RPM into a separate file
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5672 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-10 12:29:59 +00:00
Bart Van Assche
296a29b553 scst.spec.in: Create /var/lib/scst/pr and /var/lib/scst/vdev_mode_pages when installing the SCST RPM
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5670 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-10 06:18:58 +00:00
Bart Van Assche
d6346bcfc7 scst/Makefile: Create /var/lib/scst/vdev_mode_pages while installing SCST
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5669 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-10 06:17:57 +00:00
Vladislav Bolkhovitin
3eb2b2bb7e Make SCST interface compatibility more robust
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5668 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-10 01:00:29 +00:00
Bart Van Assche
56d89d0258 nightly build: Update kernel versions
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5667 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-08 15:11:58 +00:00
Bart Van Assche
020f066cc6 scripts/run-regression-tests: Add command-line option -4 (disable IPv6)
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5662 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-06 08:02:28 +00:00
Bart Van Assche
bdcba0604a Make scripts/kernel-functions again compatible with 2.6.x kernels
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5661 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-04 05:39:28 +00:00
Bart Van Assche
b41aed61e3 scripts/generate-patched-kernel: Clean up
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5659 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-03 08:42:08 +00:00
Bart Van Assche
940e4b2f98 scripts/kernel-functions: Handle 3.x.0 kernel versions correctly
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5658 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-03 08:36:48 +00:00
Bart Van Assche
c2d667406d nightly build: Update kernel versions
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5657 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-01 16:46:12 +00:00
Bart Van Assche
c06e1c5a65 scst_vdisk: Fix a checkpatch warning
Avoid that checkpatch reports the following warning:

WARNING: static const char * array should probably be static const char * const


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5654 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-01 06:38:13 +00:00
Bart Van Assche
47b5c207f1 nightly build: Correct a kernel version
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5651 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-30 09:18:41 +00:00
Bart Van Assche
6c602ff6a9 nightly build: Correct a kernel version
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5650 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-30 08:52:06 +00:00
Bart Van Assche
341564f3db scst_vdisk: Fix a checkpatch warning
Address the following checkpatch warning:

char * array declaration might be better as static const


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5649 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-30 08:40:23 +00:00
Bart Van Assche
e70268341b scst: Build fix for kernel versions <= 2.6.31
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5648 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-30 07:28:18 +00:00
Bart Van Assche
4b192f7fa7 scst: Build fix for Linux kernel versions 2.6.33 and 2.6.34
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5647 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-30 07:18:53 +00:00
Bart Van Assche
2ab81dfa2e scst_local: Avoid that session deletion triggers a kernel warning
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5631 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-28 20:15:45 +00:00
Bart Van Assche
a96b8e9cc4 scst.spec.in: Follow-up for r5628
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5630 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-28 20:00:22 +00:00
Bart Van Assche
035e879dd6 scst_vdisk: Fix 32-bit build
Avoid 64-bit modulo computations since these result in undefined symbol
errors on 32-bit systems (__moddi3 / __umoddi3). Support sizes >= 2**32
bytes on 32-bit systems.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5629 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-28 19:58:44 +00:00
Bart Van Assche
bebce1c99f ib_srpt: Remove existing ib_srpt.ko kernel modules before installation
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5628 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-28 19:56:36 +00:00
Bart Van Assche
7ea74c5a90 nightly build: Update kernel versions
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5627 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-27 10:32:02 +00:00
Vladislav Bolkhovitin
16ab16ee6e scst_vdisk: Three more put_unaligned_*() conversions
Convert three more *(__be16 *)p = cpu_to_be16(v) statements into
put_unaligned_be16(v, p) since the latter is easier to read. Also
convert one "cmd->dev" into "dev" expression. This patch does not
change any functionality.

Signed-off-by: Bart Van Assche <bvanassche@acm.org>



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5626 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-26 23:26:25 +00:00
Vladislav Bolkhovitin
1450d90eac scst_debug.h: Make EXTRACHECKS_*_ON() statements visible to Coverity
Signed-off-by: Bart Van Assche <bvanassche@acm.org>



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5625 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-25 21:38:19 +00:00
Bart Van Assche
1269744924 nightly build: Use http instead of ftp for downloading kernel source code
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5624 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-25 11:50:40 +00:00
Bart Van Assche
8ffdd099e6 ib_srpt: Set SCSI residual fields in SRP_CMD reply
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5622 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-24 13:33:23 +00:00
Bart Van Assche
f4a38d3e6e ib_srpt: Complain if another ib_srpt.ko kernel module already exists
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5621 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-24 13:32:18 +00:00
Vladislav Bolkhovitin
5ba55f4768 scst_vdisk: Split vdisk_exec_inquiry()
Make vdisk_exec_inquiry() easier to read by moving the code
for the implementation of each VPD page into a separate function.
This patch does not change any functionality.

Signed-off-by: Bart Van Assche <bvanassche@acm.org>



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5620 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-24 04:45:08 +00:00
Bart Van Assche
b0ce21767f nightly build: Add kernel version 3.15.1
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5619 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-20 05:56:36 +00:00
Vladislav Bolkhovitin
b6f2a47ee8 Change BUG_ON(1) into BUG()
With CONFIG_BUG=y both BUG() and BUG_ON(1) halt the system. However,
with CONFIG_BUG=n BUG() halts the system but BUG_ON(1) not. To avoid
such subtleties, change BUG_ON(1) into BUG().

See also patch Josh Triplett, "bug: Make BUG() always stop the machine",
7 April 2014 (commit ID a4b5d580e07875f9be29f62a57c67fbbdbb40ba2).

Signed-off-by: Bart Van Assche <bvanassche@acm.org>



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5618 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-20 04:10:40 +00:00
Vladislav Bolkhovitin
533d5546b0 scst: Avoid that sparse complains about unreachable code
Remove the code after BUG() statements to avoid that smatch
complains about unreachable code. Hide the spin_unlock() statements
before BUG() statements for static analysis tools to avoid that
sparse complains about locking imbalances.

Signed-off-by: Bart Van Assche <bvanassche@acm.org>



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5617 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-20 04:09:11 +00:00
Vladislav Bolkhovitin
23116c1598 scst: Exclude certain locking code from static analysis
Loops with locking statements and also lock and unlock
statements guarded by an if-statement trigger false positive
warnings when analyzing the SCST code with smatch and/or sparse.
Hence exclude such code from static analysis.

Signed-off-by: Bart Van Assche <bvanassche@acm.org>



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5616 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-20 04:05:11 +00:00
Vladislav Bolkhovitin
6b32f4ae81 scst, iscsi-scst: Fix RHEL 5 compilation warnings
Signed-off-by: Bart Van Assche <bvanassche@acm.org>



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5615 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-20 04:03:40 +00:00
Vladislav Bolkhovitin
c833137130 iscsi-scst: Suppress a compiler warning
Avoid that the following compiler warning is reported when compiling
iscsi-scst:

chap.c: In function 'chap_rand':
chap.c:348:5: warning: ignoring return value of 'read', declared with attribute warn_unused_result [-Wunused-result]
     (void)read(fd, &r, sizeof(r));
     ^

Signed-off-by: Bart Van Assche <bvanassche@acm.org>



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5614 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-20 04:02:00 +00:00
Vladislav Bolkhovitin
18e4fb0c83 scst: Convert a loop to keep smatch happy
Avoid that smatch reports the following warning:
scst_init_session() info: loop could be replaced with if statement.

Signed-off-by: Bart Van Assche <bvanassche@acm.org>



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5613 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-20 04:00:41 +00:00
Bart Van Assche
e902f79ecf kernel module installation: Skip "depmod" when building an RPM
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5612 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-19 12:48:25 +00:00
Bart Van Assche
1fdd3d9a8d nightly build: Add kernel 3.15 build infrastructure
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5611 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-19 07:09:53 +00:00
Vladislav Bolkhovitin
b5c649ef5c Update for 3.15 kernels
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5610 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-19 03:51:48 +00:00
Bart Van Assche
4a179f7037 nightly build: Update kernel versions
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5609 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-17 06:37:08 +00:00
Vladislav Bolkhovitin
12c4e0fe0a scst: Make access control group removal behavior configurable
SCST rejects removal of an access control group with one or more
sessions with error code -EBUSY. Make it easy to change this
behavior into forcibly closing sessions when an access control
group is removed.

Signed-off-by: Bart Van Assche <bvanassche@acm.org>



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5608 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-17 00:50:46 +00:00
Bart Van Assche
732ce5ca89 fcst: Handle frame send failures properly
Retry sending XFER_RDY, data and response frames if the network
driver reports that sending failed (-ENOMEM) instead of reporting
a kernel warning (WARN_ON(1)). If sending XFER_RDY or data frames
failed for another reason, report this to the initiator as a
write error (ASC = 03; ASCQ = 00 which stands for PERIPHERAL
DEVICE WRITE FAULT). If sending a response frame failed with
another error code than -ENOMEM, do not send a response.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5607 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-14 17:18:34 +00:00
Bart Van Assche
d937c0886d fcst: Move exch_done() calls into ft_cmd_done()
This patch ensures that exch_done() gets called if an fcst
callback returns SCST_TGT_RES_FATAL_ERROR.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5606 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-14 17:17:56 +00:00