Mark Buechler
ffd2803eca
- When reading and old configuration file, if no targets
...
are enabled, add groups/initiators for all known targets.
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1851 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-21 15:28:21 +00:00
Bart Van Assche
3b5d4ea5fa
Fixed a copy/paste error.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1850 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-21 15:21:06 +00:00
Bart Van Assche
b5c0a25514
Module removal and session unregistration with ongoing I/O should now finally work reliably.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1849 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-21 14:22:34 +00:00
Bart Van Assche
5ded0b7660
Changes:
...
- Implemented a workaround for a race between ib_destroy_cq() and the IB
completion handlers. This race could trigger a kernel crash or kernel lockup
when unloading the ib_srpt module while I/O was ongoing or by performing
a relogin from an SRP initiator while I/O was ongoing.
- Moved the code for handling IB completions in single-threaded mode to
separate functions.
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1848 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-21 10:52:36 +00:00
Bart Van Assche
2c663262b1
Fixed a single-letter typo in a source code comment.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1847 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-21 10:49:58 +00:00
Bart Van Assche
0e6414624e
Follow-up for r1845.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1846 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-20 19:44:39 +00:00
Bart Van Assche
a9668c9f07
Micro-optimized srpt_handle_rdma_comp().
...
Assigned names to the three threading modes.
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1845 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-20 18:40:29 +00:00
Vladislav Bolkhovitin
891c7d5b03
Fix BUG while enabling target mode remote port disappear:
...
In case if ELS LOGO command received on the target port,
the firmware can notify the driver about it in 3 different ways,
which handled differently by the driver (it doesn't clear when it use each way):
1. Immediate notify of login-affecting ELS command received (status code 0x46).
The target driver terminate all commands received for the specified initiator
(N_Port handle).
2. Asynchroneus event of port update.
The target driver only print message, and in remark it's written that
/* .mark_all_devices_lost() is handled by the initiator driver */
3. Immediate notify of port logged out (status code 0x29).
The target driver terminate all commands received for the specified initiator
(N_Port handle), and also mark all devices as lost.
In 1 and 2 everthing is OK. In 3 the target driver mark all devices as lost,
but never retrigger rescanning.
There are 2 solutions:
1. Not marking the devices as lost base on written in the async event case, and
also base on the spec which says to only terminate all commands.
2. Mark all devices as lost and retrigger rescanning.
1 was implemented; delete all calls to mark_all_devices_lost() in qla2x00t.c, and
unexport symbol of this function in qla_os.c
Signed-off-by: Gal Rosen <galr@storwize.com >
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1844 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-20 17:51:19 +00:00
Vladislav Bolkhovitin
9562e5679b
More unexisting LUNs handling fixes
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1843 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-19 17:48:14 +00:00
Bart Van Assche
7cca01ae41
Added one more test.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1842 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-18 17:43:44 +00:00
Bart Van Assche
2d3b5d3387
Partially reverted r1416 in order to fix a data corruption issue that occurred
...
with highly parallel workloads.
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1841 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-18 17:39:43 +00:00
Bart Van Assche
5d78905aaf
Whitespace-only changes: converted spaces to tabs.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1840 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-17 20:17:45 +00:00
Bart Van Assche
3b69f969f1
Under heavily multithreaded I/O (twenty or more concurrent writers), data corruption could occur. This issue was introduced in r1506 and has now been fixed.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1839 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-17 19:50:45 +00:00
Bart Van Assche
78cb9e9458
Changed meaning of thread kernel module parameter: while 0 still stands for IRQ context, 1 does now stand for single-threaded processing and 2 for processing SCSI command via multiple kernel threads.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1838 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-17 19:21:22 +00:00
Vladislav Bolkhovitin
492e33a312
- Move nl_open() after kernel_open() to avoid issues when second start could skrew netlink states for the first instance
...
- Avoid compiler warn_unused_result warning
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1837 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-17 16:44:22 +00:00
Vladislav Bolkhovitin
a91af4e5d0
Cleanup inspired by IET r369
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1836 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-17 16:27:06 +00:00
Vladislav Bolkhovitin
1e7ca7a0b7
Merge of IET r341: New md5/sha1 code in ietd didn't handle the byte swap properly
...
for the digest counters on big endian systems.
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1835 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-17 16:02:30 +00:00
Vladislav Bolkhovitin
43cfabc3cc
Partial merge of IET r358 and 367: a bunch of iSNS fixes.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1834 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-17 15:57:49 +00:00
Vladislav Bolkhovitin
28dd4e5150
Patch from Bart Van Assche <bvanassche@acm.org> fixing endianness warning reported by sparse.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1833 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-17 13:53:41 +00:00
Vladislav Bolkhovitin
e79a15cc16
Some more minor sysfs fixes
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1832 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-16 20:33:10 +00:00
Vladislav Bolkhovitin
89a8ab94a1
Set the key attribute for filename for vcdrom devices
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1831 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-16 19:18:31 +00:00
Bart Van Assche
427dadcb74
Enabled endianness checks.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1830 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-16 18:53:25 +00:00
Vladislav Bolkhovitin
305a35dae6
Fix possible crash for INQUIRYs on not existing LUNs
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1829 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-16 18:47:12 +00:00
Vladislav Bolkhovitin
2f667fe80f
Part of the patch from Bart Van Assche <bvanassche@acm.org> fixing/suppressing iscsi-scst related endianness warnings reported by sparse with some changes
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1828 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-15 17:45:41 +00:00
Vladislav Bolkhovitin
8f8ea536e0
- Logging cleanup
...
- Added debug facility to catch possible data corruption case.
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1827 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-15 12:45:31 +00:00
Bart Van Assche
402306e3e0
Relaxed send-queue-full error handling.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1826 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-14 18:37:42 +00:00
Bart Van Assche
7a0a6fb86e
Made srpt_srq_size configurable as a kernel module parameter.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1825 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-14 18:28:09 +00:00
Bart Van Assche
fe81f9766c
Changed two PRINT_INFO() messages that reported that the send queue was full into PRINT_ERROR() messages, and renamed a few variables.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1824 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-14 17:22:52 +00:00
Vladislav Bolkhovitin
82dca1c438
Web updates
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1823 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-14 14:16:36 +00:00
Vladislav Bolkhovitin
48d762e5cb
Fix handling of host templates with NULL names
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1822 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-14 13:31:39 +00:00
Vladislav Bolkhovitin
571df65257
Fixing broken perf build
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1821 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-14 12:57:39 +00:00
Mark Buechler
bd48c8f119
- Check for non-existent devices and warn/remove them from read config.
...
- Error out if a target doesn't exist to prevent removing potentially
good running config.
- Be sure to remove luns and initiators before the group they're in.
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1820 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-13 19:12:44 +00:00
Bart Van Assche
e7c082ac23
Implemented several source code refinements that do not affect functionality.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1819 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-13 18:36:08 +00:00
Mark Buechler
4e9f58c279
- Fixed driver/target attribute setting as well as dynamic attribute
...
adding and deleting. I must have been low on meds the first time
I wrote those.
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1818 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-13 18:27:36 +00:00
Mark Buechler
9e11c29d06
- Fix handling of /dev paths.
...
- Check for device paths which have a '/' in checkConfiuration().
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1817 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-13 15:15:11 +00:00
Vladislav Bolkhovitin
6527947abb
Fix "‘wrap’ may be used uninitialized" warning
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1816 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-13 12:24:13 +00:00
Vladislav Bolkhovitin
8437061902
Don't allow to create devices with '/' in names
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1815 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-13 12:11:52 +00:00
Vladislav Bolkhovitin
e8f6cfd143
Remove wrong "Unexpected block size" messages
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1814 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-13 11:50:27 +00:00
Vladislav Bolkhovitin
d3847b031e
Make SG IO count limitation messages less annoying
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1813 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-13 11:48:49 +00:00
Bart Van Assche
47a5c6072c
Fixed a bug in the command abortion code. E.g. the following kernel message could be generated when unloading ib_srpt while I/O was ongoing:
...
------------[ cut here ]------------
WARNING: at /home/bart/software/scst/srpt/src/ib_srpt.c:1063 srpt_reset_ioctx+0x15b/0x170 [ib_srpt]()
Hardware name: P5Q DELUXE
Modules linked in: [ ... ]
Pid: 20709, comm: disk011_4 Tainted: G W 2.6.34-scst #1
Call Trace:
[<ffffffff81048dbb>] warn_slowpath_common+0x7b/0xc0
[<ffffffff81048e14>] warn_slowpath_null+0x14/0x20
[<ffffffffa050772b>] srpt_reset_ioctx+0x15b/0x170 [ib_srpt]
[<ffffffff81048dcf>] ? warn_slowpath_common+0x8f/0xc0
[<ffffffffa0507773>] srpt_on_free_cmd+0x33/0x60 [ib_srpt]
[<ffffffffa0480a0b>] scst_free_cmd+0xab/0x460 [scst]
[<ffffffffa046dd38>] scst_finish_cmd+0x178/0x300 [scst]
[<ffffffffa0470ed4>] scst_process_active_cmd+0x134/0x640 [scst]
[<ffffffffa0471dac>] scst_process_redirect_cmd+0x2bc/0x3f0 [scst]
[<ffffffffa047247a>] scst_tgt_cmd_done+0x6a/0x100 [scst]
[<ffffffffa0508dec>] srpt_xmit_response+0x11c/0x210 [ib_srpt]
[<ffffffffa046b53c>] scst_xmit_response+0x13c/0x560 [scst]
[<ffffffffa0470efb>] scst_process_active_cmd+0x15b/0x640 [scst]
[<ffffffffa047149d>] scst_do_job_active+0xbd/0x180 [scst]
[<ffffffffa0471806>] scst_cmd_thread+0x1c6/0x4b0 [scst]
[<ffffffff8103e960>] ? default_wake_function+0x0/0x20
[<ffffffffa0471640>] ? scst_cmd_thread+0x0/0x4b0 [scst]
[<ffffffff810683e6>] kthread+0x96/0xa0
[<ffffffff81003d94>] kernel_thread_helper+0x4/0x10
[<ffffffff8103dcb1>] ? finish_task_switch+0x51/0xb0
[<ffffffff81344dac>] ? _raw_spin_unlock_irq+0x1c/0x40
[<ffffffff813458ad>] ? restore_args+0x0/0x30
[<ffffffff81068350>] ? kthread+0x0/0xa0
[<ffffffff81003d90>] ? kernel_thread_helper+0x0/0x10
---[ end trace 84b1e00ea2ac6651 ]---
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1812 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-10 18:27:59 +00:00
Bart Van Assche
008841b622
Minor optimization: merged a srpt_get_cmd_state() and srpt_set_cmd_state() call.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1811 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-10 07:17:30 +00:00
Vladislav Bolkhovitin
75411305f1
Partial commit of patch from Bart Van Assche <bvanassche@acm.org> which suppresses the sparse warnings triggered by scst_pres.c.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1810 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-09 19:48:55 +00:00
Vladislav Bolkhovitin
3c411a5ba7
Fix for bug reported by Mark Buechler <mark.buechler@gmail.com> when wrong wildcard attribute can be deleted
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1809 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-09 19:05:55 +00:00
Bart Van Assche
66ccc6d619
Reverted r1806 and fixed a race condition that could cause data corruption.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1808 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-09 18:12:24 +00:00
Bart Van Assche
45bbbbba5f
Improved I/O stress test.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1807 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-09 18:04:23 +00:00
Bart Van Assche
cdd65273e9
Applied a temporary fix for data corruption that could occur when multiple initiators were accessing data on a multicore target system.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1806 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-08 18:29:52 +00:00
Mark Buechler
10339ef259
- Fixed empty CREATE_ATTRIBUTES.
...
- Added version requirement to SCST::SCST.
- Added support for deleting of dynamic attributes.
- Fixed support for changing non-dynamic attributes.
- Fixed (sorta) vcdrom handler.
Still possibly broken:
- Adding/deleting dynamic attributes is a bit broken in my
SCST tree for some reason. I suspect this may be fixed
in a later svn commit.
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1805 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-07 18:12:40 +00:00
Bart Van Assche
8297ce5c41
Updated kernel versions.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1804 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-06 10:41:33 +00:00
Bart Van Assche
cf6fb97164
Made sure that the source file scst_pres.c is compiled too.
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1803 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-05 16:17:36 +00:00
Bart Van Assche
2e07133917
Converted a WARN_ON() statement into PRINT_INFO().
...
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1802 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2010-07-04 20:11:47 +00:00