Commit Graph

405 Commits

Author SHA1 Message Date
Bart Van Assche
bd520b5e23 Merge r5839 from the iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6263 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 16:27:18 +00:00
Bart Van Assche
c728d4e3af Merge r5870 from the iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6262 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 16:25:50 +00:00
Bart Van Assche
2bd336549a Finish merging the 3.0.x-iser branch into the 3.0.x branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6261 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 16:00:22 +00:00
Bart Van Assche
994908e601 Merge r6083 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6260 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:47:59 +00:00
Bart Van Assche
5b0edfd079 Merge r6082 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6259 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:47:42 +00:00
Bart Van Assche
8aa1081442 Merge r6014 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6258 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:47:28 +00:00
Bart Van Assche
26891b58bd Merge r6013 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6257 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:47:15 +00:00
Bart Van Assche
9ac2427ec5 Merge r6012 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6256 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:47:00 +00:00
Bart Van Assche
34ae1e829a Merge r6011 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6255 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:46:44 +00:00
Bart Van Assche
ab31727bcd Merge r6010 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6254 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:46:30 +00:00
Bart Van Assche
716ff53045 Merge r6009 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6253 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:46:15 +00:00
Bart Van Assche
a97d0be047 Merge r6008 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6252 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:46:00 +00:00
Bart Van Assche
e52b7a8a89 Merge r6006 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6250 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:45:16 +00:00
Bart Van Assche
4a6806a2af Merge r6005 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6249 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:44:57 +00:00
Bart Van Assche
ec67a69535 Merge r5902 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6248 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:44:32 +00:00
Bart Van Assche
69ea41df6d Merge r5877 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6247 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:44:05 +00:00
Bart Van Assche
3bcf9d7a02 Merge r5843 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6245 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:43:12 +00:00
Bart Van Assche
8b5061f5f8 Merge r5792 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6244 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:42:55 +00:00
Bart Van Assche
6fe3cb0eba Merge r5782 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6243 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:42:37 +00:00
Bart Van Assche
7cba4ba078 Merge r5742 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6242 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:42:06 +00:00
Bart Van Assche
a5e0e412c0 Finish merging r5663 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6241 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:40:55 +00:00
Bart Van Assche
1536ce4e3b Merge r5742 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6240 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:33:22 +00:00
Bart Van Assche
faae8613ce Merge r5663 from 3.0.x-iser branch
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6239 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-06-11 15:32:44 +00:00
Vladislav Bolkhovitin
e565cbce6e Merged revisions 5955,5959-5961,5965 via svnmerge from
svn+ssh://vlnb@svn.code.sf.net/p/scst/svn/trunk

........
  r5955 | bvassche | 2014-12-22 05:10:41 -0800 (Mon, 22 Dec 2014) | 1 line
  
  Update for kernel 3.18
........
  r5959 | bvassche | 2015-01-06 05:25:28 -0800 (Tue, 06 Jan 2015) | 1 line
  
  scst_calc_block_shift: Log block shift and sector size upon mismatch
........
  r5960 | bvassche | 2015-01-07 01:20:06 -0800 (Wed, 07 Jan 2015) | 4 lines
  
  scst_local: Fix unique per session sas address
  
  Signed-off-by: Sebastian Herbszt <herbszt@gmx.de>
........
  r5961 | bvassche | 2015-01-09 04:23:25 -0800 (Fri, 09 Jan 2015) | 4 lines
  
  scst_sysfs: return EINVAL on too big LUN
  
  Signed-off-by: Sebastian Herbszt <herbszt@gmx.de>
........
  r5965 | bvassche | 2015-01-13 00:55:46 -0800 (Tue, 13 Jan 2015) | 68 lines
  
  qla2x00t: Copy entire SCST sense buffer to q2x ctio
  
  There seems to be a bug in passing sense information to QLA HBAs, where 
  the last 2 bytes of the sense data (ASC, ASCQ) are not copied to the low 
  level sense buffer.
  We encountered this in ESX, which relies on these 2 bytes to parse the 
  MISCOMPARE sense code (0xE1, 0x1D, 0x00).
  Bellow is a simple test to recreate this issue, but during vMotion 
  operations (where VMs are moved from one host to another), this may 
  cause the operation to fail leaving the VM in an inconsistent state.
  
  The test I ran to verify that we are indeed missing the bytes is the 
  following:
  1. Create a SCST based device
  2. Expose the device to 2 ESX hosts
  3. Format the device as VMFS5, create a test directory
  4. From both hosts, I start writing to this directory (no VMs involved, 
  just write normal files)
  
  At this stage, both ESX hosts try to take access to the directory.
  The VMFS filesystem contains a per-directory lock which is managed by 
  COMPARE AND WRITE command.
  Each ESX will attempt to change the VMFS lock location from unlocked to 
  locked to create the new file.
  
  Obviously there are bound to be failures (which are equivalent to 
  programming locking conflicts), these are reported by the MISCOMPARE 
  sense code.
  Upon these MISCOMPARE errors, the host will re-try taking the lock until 
  it succeeds, and will then proceed to perform the write operation on the 
  directory.
  
  Due to the bug in copying the sense buffer from the SCST core to the QLA 
  ctio, instead of the full sense code, only the key (0xE) is sent, and 
  ESX does not know how to handle it resulting in IO error.
  
  Here are the errors as they appear on the command line:
  /vmfs/volumes/54a297c4-ca5af1cc-7f94-002219d20f28/ats_test # 
  ./open_close_test-esx2.sh
  ./open_close_test-esx2.sh: line 8: can't create 
  ats_fileoptest-esx2_1.txt: Input/output error
  ./open_close_test-esx2.sh: line 8: can't create 
  ats_fileoptest-esx2_21.txt: Input/output error
  ./open_close_test-esx2.sh: line 8: can't create 
  ats_fileoptest-esx2_110.txt: Input/output error
  ./open_close_test-esx2.sh: line 8: can't create 
  ats_fileoptest-esx2_111.txt: Input/output error
  
  In the /var/log/vmkernel.log, we can see that the sense information is 
  missing (0xE, 0x0, 0x0) instead of (0xE, 0x1D, 0x0).
  2014-12-30T12:13:20.714Z cpu6:33519)ScsiDeviceIO: 2338: 
  Cmd(0x412e84f957c0) 0x89, CmdSN 0x234d from world 519051 to dev 
  "eui.0024f400d5020007" failed H:0x0 D:0x2 P:0x0 Valid sense data: 0xe 0x0 0x0.
  2014-12-30T12:13:20.766Z cpu6:33519)ScsiDeviceIO: 2338: 
  Cmd(0x412e84f91d00) 0x89, CmdSN 0x2350 from world 519051 to dev 
  "eui.0024f400d5020007" failed H:0x0 D:0x2 P:0x0 Valid sense data: 0xe 0x0 0x0.
  2014-12-30T12:13:20.766Z cpu6:33519)ScsiDeviceIO: 2338: 
  Cmd(0x412e80449fc0) 0x89, CmdSN 0x234f from world 519051 to dev 
  "eui.0024f400d5020007" failed H:0x0 D:0x2 P:0x0 Valid sense data: 0xe 0x0 0x0.
  
  This patch fixes this issue, the test will run without a problem with the
  fix (no IO errors, all the files are properly written to the directory).
  
  Signed-off-by: Shahar Salzman <shahar.salzman@kaminario.com>
  Reviewed-by: Eran Mann <eran.mann@kaminario.com>
  [bvanassche: simplified implementation]
  Signed-off-by: Bart Van Assche <bvanassche@acm.org>
........


git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@6110 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2015-02-21 04:10:37 +00:00
Bart Van Assche
808301be78 iscsi-scst/kernel/patches/rhel/put_page_callback-2.6.32-504.patch: Add (merge r5904 from trunk)
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@5915 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-12-05 10:01:49 +00:00
Bart Van Assche
c9100494b4 Update for kernel 3.17 (merge r5882 from trunk)
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@5906 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-12-03 17:12:20 +00:00
Vladislav Bolkhovitin
f58278a211 Merged revisions 5856 via svnmerge from
svn+ssh://vlnb@svn.code.sf.net/p/scst/svn/trunk

........
  r5856 | vlnb | 2014-11-14 17:55:27 -0800 (Fri, 14 Nov 2014) | 3 lines
  
  Report RX data digest failures by default
........


git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@5858 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-11-15 05:38:28 +00:00
Bart Van Assche
14187b9810 Add support for the RHEL 7 kernel (merge r5710:5711 from trunk)
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@5774 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-09-04 13:29:18 +00:00
Bart Van Assche
2c9cfa303c iscsi-scst: Micro-optimize cmnd_prepare_recv_pdu() (merge r5735 from trunk)
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@5771 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-09-04 13:06:38 +00:00
Bart Van Assche
4513e2441b iscsi-scst: Build fix for IPV6=n (merge r5732 from trunk)
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@5770 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-09-04 13:02:42 +00:00
Bart Van Assche
03c07d835c Update for kernel 3.16 (merge r5717 from trunk)
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@5766 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-09-03 14:27:09 +00:00
Vladislav Bolkhovitin
9256821943 Merged revisions 5721 via svnmerge from
svn+ssh://vlnb@svn.code.sf.net/p/scst/svn/trunk

........
  r5721 | vlnb | 2014-08-20 22:17:47 -0700 (Wed, 20 Aug 2014) | 5 lines
  
  Fix incorrect address computation during receive PDUs preparations
  
  Found and fix suggested by Кирилл Тюшев <kirill.tyushev8@gmail.com>
........


git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@5723 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-08-21 05:21:55 +00:00
Bart Van Assche
3f77595dbd Change BUG_ON(1) into BUG() (merge r5618 from trunk)
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@5695 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-20 06:52:12 +00:00
Bart Van Assche
cb4fa8ed0d scst: Make lockdep_assert_held() easier to use (merge r5573 from trunk)
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@5693 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-20 06:46:28 +00:00
Bart Van Assche
91c8d27db8 iscsi-scst: Handle data buffers with non-zero offset correctly (merge r5683 from trunk)
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@5687 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-07-20 05:59:31 +00:00
Bart Van Assche
42137a23c2 scst: Switch from the cpu_*() to the cpumask_*() API (merge r5596 from trunk)
git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@5646 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-29 06:10:22 +00:00
Vladislav Bolkhovitin
e585dbc244 Merged revisions 5610 via svnmerge from
svn+ssh://vlnb@svn.code.sf.net/p/scst/svn/trunk

........
  r5610 | vlnb | 2014-06-18 20:51:48 -0700 (Wed, 18 Jun 2014) | 3 lines
  
  Update for 3.15 kernels
........


git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@5623 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-25 04:00:14 +00:00
Vladislav Bolkhovitin
f7bd8e034b Merged revisions 5543,5545 via svnmerge from
svn+ssh://vlnb@svn.code.sf.net/p/scst/svn/trunk

........
  r5543 | bvassche | 2014-05-23 00:33:53 -0700 (Fri, 23 May 2014) | 1 line
  
  RHEL 7 build fixes
........
  r5545 | bvassche | 2014-05-23 01:36:36 -0700 (Fri, 23 May 2014) | 1 line
  
  scripts/rebuild-rhel-kernel-rpm: Add RHEL 7 RC support
........


git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.0.x@5565 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-06-04 03:12:05 +00:00
Vladislav Bolkhovitin
416958ee4b iscsi-scst: One major number per thread pool
Assign one major number per thread pool instead of as many major
numbers as there are threads in a thread pool. Do not increment
'major' if thread pool allocation fails. Micro-optimize
iscsi_threads_pool_get() by eliminating the assignment to 'fn'
and the write via snprintf() into name[].

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



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5520 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-05-15 01:39:12 +00:00
Vladislav Bolkhovitin
8d4a2f0a49 Cleanups and logging improvements
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5503 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-05-06 23:22:32 +00:00
Bart Van Assche
cbc9df8306 iscsi-scst/kernel/patches/put_page_callback-3.2.57.patch: Add
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5450 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-04-20 06:24:23 +00:00
Bart Van Assche
135be0f19d iscsi-scst: Fix a checkpatch warning
Fix the following checkpatch 3.14 warning:

Unnecessary parentheses - maybe == should be = ?


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5435 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-04-18 05:56:35 +00:00
Vladislav Bolkhovitin
bbdf791c65 Update to kernels 3.14
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5432 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-04-18 00:32:51 +00:00
Vladislav Bolkhovitin
8599ec4452 Reimplement dropping of TM requests in a more reliable manner
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5395 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-03-26 23:51:36 +00:00
Vladislav Bolkhovitin
0c66b8aaf7 iscsi-scst: Introduce ARRAY_SIZE()
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@5386 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-03-26 03:21:25 +00:00
Bart Van Assche
cbb8071e73 put_page_callback-3.10.30.patch: Add
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5310 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-02-25 10:57:27 +00:00
Bart Van Assche
493f498b7b put_page_callback-3.12.11.patch: Add
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5309 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-02-25 10:55:36 +00:00
Vladislav Bolkhovitin
9ab22a69fd put_page_callback patch for 3.13.3+ kernels
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5296 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-02-20 05:54:49 +00:00
Vladislav Bolkhovitin
b4ba1b24c7 iscsi-scst: fix offset calculation
Fixed a subtle bug in iSCSI-SCST with incorrectly calculated offsets
for non-page aligned transfers. Originally discovered, investigated and
fix suggested by Кирилл Тюшев, then Shahar Salzman tested and proved it.
See http://sourceforge.net/mailarchive/message.php?msg_id=31924078



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5281 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-02-13 04:02:56 +00:00
Vladislav Bolkhovitin
e6fd59bda4 Update for 3.13 kernels
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5250 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2014-01-30 02:32:44 +00:00