Vladislav Bolkhovitin 34cca9e432 Blocked revisions 7095,7097-7100,7102-7103,7105,7112-7114,7119-7124,7126-7133,7138,7140,7142,7144-7151,7155-7157,7159-7161,7164-7167,7172,7174,7180-7184,7186-7189,7191-7192,7194-7202,7204-7207 via svnmerge
........
  r7095 | bvassche | 2017-02-23 18:07:29 -0800 (Thu, 23 Feb 2017) | 2 lines
  
  scst_copy_mgr: Convert comments about locking into runtime checks
........
  r7097 | bvassche | 2017-02-23 23:07:41 -0800 (Thu, 23 Feb 2017) | 37 lines
  
  scst: Fix locking annotations
  
  Avoid that the following warnings are triggered:
  
  WARNING: CPU: 5 PID: 32343 at scst/src/scst_copy_mgr.c:2741 scst_cm_on_add_acg+0x12d/0x180 [scst]
  Call Trace:
   [<ffffffff812a4d23>] dump_stack+0x86/0xc3
   [<ffffffff8106412b>] __warn+0xcb/0xf0
   [<ffffffff8106421d>] warn_slowpath_null+0x1d/0x20
   [<ffffffffa04f9b0d>] scst_cm_on_add_acg+0x12d/0x180 [scst]
   [<ffffffffa04b8084>] scst_alloc_add_acg+0xc4/0x280 [scst]
   [<ffffffffa0486b30>] scst_register_target+0x190/0x3a0 [scst]
   [<ffffffffa054f2de>] scst_cm_init+0xb8/0xdda [scst]
   [<ffffffffa054eab9>] init_scst+0xa06/0xc3f [scst]
   [<ffffffff8100043d>] do_one_initcall+0x3d/0x160
   [<ffffffff81154ae0>] do_init_module+0x5f/0x1f1
   [<ffffffff810efa69>] load_module+0x2719/0x2a50
   [<ffffffff810effcc>] SYSC_finit_module+0xbc/0xf0
   [<ffffffff810f001e>] SyS_finit_module+0xe/0x10
   [<ffffffff8152fe40>] entry_SYSCALL_64_fastpath+0x23/0xc1
  
  WARNING: CPU: 2 PID: 12885 at scst/src/scst_copy_mgr.c:2826 scst_cm_check_access_acg+0x180/0x1e0 [scst]
  Call Trace:
   [<ffffffff812a4d23>] dump_stack+0x86/0xc3
   [<ffffffff8106412b>] __warn+0xcb/0xf0
   [<ffffffff8106421d>] warn_slowpath_null+0x1d/0x20
   [<ffffffffa0502b00>] scst_cm_check_access_acg+0x180/0x1e0 [scst]
   [<ffffffffa0502cba>] scst_cm_check_access+0x15a/0x280 [scst]
   [<ffffffffa05030cb>] scst_cm_parse_id_tgt_descr+0x2eb/0x590 [scst]
   [<ffffffffa050a1d8>] scst_cm_parse_descriptors+0x308/0xa60 [scst]
   [<ffffffffa04d4440>] scst_parse_descriptors+0x60/0x130 [scst]
   [<ffffffffa04a3c05>] scst_tgt_pre_exec+0x375/0x4a0 [scst]
   [<ffffffffa04ac2a9>] scst_process_active_cmd+0x439/0x740 [scst]
   [<ffffffffa04adbb2>] scst_cmd_thread+0x202/0x6a0 [scst]
   [<ffffffff810883cf>] kthread+0xef/0x110
   [<ffffffff8153008f>] ret_from_fork+0x1f/0x40
........
  r7098 | bvassche | 2017-02-24 17:54:58 -0800 (Fri, 24 Feb 2017) | 18 lines
  
  scst_copy_mgr: Avoid that scst_cm_on_add_lun() triggers a kernel warning
  
  Avoid that the following warning is triggered:
  
  WARNING: CPU: 1 PID: 1282 at scst/src/scst_copy_mgr.c:2784 scst_cm_on_add_lun+0x141/0x1b0 [scst]
  Call Trace:
   dump_stack+0x86/0xc3
   __warn+0xc1/0xe0
   warn_slowpath_null+0x18/0x20
   scst_cm_on_add_lun+0x141/0x1b0 [scst]
   scst_acg_add_lun+0x27f/0x370 [scst]
   __scst_process_luns_mgmt_store+0x589/0x5f0 [scst]
   scst_luns_mgmt_store_work_fn+0x22/0x30 [scst]
   scst_process_sysfs_works+0x7b/0x1c0 [scst]
   sysfs_work_thread_fn+0x11b/0x280 [scst]
   kthread+0x102/0x140
   ret_from_fork+0x31/0x40
........
  r7099 | bvassche | 2017-02-24 17:56:30 -0800 (Fri, 24 Feb 2017) | 21 lines
  
  scst_copy_mgr: Avoid that scst_cm_check_access_acg() triggers a kernel warning
  
  Avoid that the following kernel warning is triggered:
  
  WARNING: CPU: 2 PID: 1761 at scst/src/scst_copy_mgr.c:2835 
  Call Trace:
   dump_stack+0x86/0xc3
   __warn+0xc1/0xe0
   warn_slowpath_null+0x18/0x20
   scst_cm_check_access_acg+0x1c2/0x1d0 [scst]
   scst_cm_check_access+0x155/0x280 [scst]
   scst_cm_parse_id_tgt_descr+0x2e6/0x590 [scst]
   scst_cm_parse_descriptors+0x303/0xa60 [scst]
   scst_parse_descriptors+0x5b/0x130 [scst]
   scst_tgt_pre_exec+0x370/0x4a0 [scst]
   scst_process_active_cmd+0x455/0x770 [scst]
   scst_cmd_thread+0x1fb/0x690 [scst]
   kthread+0x102/0x140
   ret_from_fork+0x31/0x40
........
  r7100 | bvassche | 2017-02-27 14:36:33 -0800 (Mon, 27 Feb 2017) | 4 lines
  
  scst_copy_mgr: Warn if LUN lookup fails
  
  It really is a bug if LUN lookup fails. 
........
  r7102 | bvassche | 2017-03-01 16:09:14 -0800 (Wed, 01 Mar 2017) | 5 lines
  
  scst: Coding style updates related to whitespace
  
  This patch changes whitespace only and nothing else.
........
  r7103 | bvassche | 2017-03-01 16:10:24 -0800 (Wed, 01 Mar 2017) | 5 lines
  
  scst: Coding style update related to the use of the keyword 'unsigned'
  
  Use 'unsigned int' instead of 'unsigned' and 'unsigned long long'
  instead of 'long long unsigned'.
........
  r7105 | bvassche | 2017-03-07 20:43:23 -0800 (Tue, 07 Mar 2017) | 1 line
  
  scst_lib.c: Fix indentation
........
  r7112 | vlnb | 2017-04-13 16:15:17 -0700 (Thu, 13 Apr 2017) | 9 lines
  
  iscsi: fix misleading error logging in config.c
  
  This fixes four similar instances of a very misleading and confusing logging
  statement, which would print a "Wrong value" that had already been corrected by
  the check function.
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7113 | vlnb | 2017-04-13 16:16:57 -0700 (Thu, 13 Apr 2017) | 7 lines
  
  iscsi: logging improvements for iscsi_scstd.c
  
  Logging improvements for iscsi_scstd.c print more information about failures.
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7114 | vlnb | 2017-04-13 16:19:05 -0700 (Thu, 13 Apr 2017) | 5 lines
  
  scst_vdisk: logging to distinguish different cases of EINVAL
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7119 | vlnb | 2017-04-13 16:43:55 -0700 (Thu, 13 Apr 2017) | 8 lines
  
  scst: remove superfluous assignment in scst_dg_add()
  
  The "res" is unconditionally set by the call to scst_dg_sysfs_add(),
  so setting it to ENOMEM above that is superfluous.
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7120 | vlnb | 2017-04-13 16:45:15 -0700 (Thu, 13 Apr 2017) | 9 lines
  
  scst_vdisk: remove parentheses from DEF_DIF_FILENAME_TMPL
  
  DEF_DIF_FILENAME_TMPL should not have the parentheses; I used it in some
  context where that became apparent.
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7121 | vlnb | 2017-04-13 16:53:35 -0700 (Thu, 13 Apr 2017) | 10 lines
  
  scst_vdisk: move declarations inside #ifdef
  
  Move some #ifdefs to also cover declarations used only inside the #ifdef.
  This is to avoid compiler warnings about unused variables.
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7122 | vlnb | 2017-04-13 16:58:32 -0700 (Thu, 13 Apr 2017) | 9 lines
  
  Fix a few compiler messages issued when some extra warnings are enabled:
      casting const to non-const
      uninitialized structure members
      non-static local function
      missing enumerated switch-value cases
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7123 | vlnb | 2017-04-13 18:03:25 -0700 (Thu, 13 Apr 2017) | 8 lines
  
  Fix a few minor "extra" compiler warnings (mostly "const" issues)
  
  Add "XXX" comments in a few places about potential problems seen in SCST code,
  for future investigation and possible repair.
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7124 | vlnb | 2017-04-13 18:16:10 -0700 (Thu, 13 Apr 2017) | 5 lines
  
  iscsi-scst: clean up the conftest subdirectory too
  
  Reported-by: David Butterfield <dab21774@gmail.com>
........
  r7126 | vlnb | 2017-04-13 18:19:06 -0700 (Thu, 13 Apr 2017) | 5 lines
  
  backport ACCESS_ONCE() before 2.6.26
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7127 | bvassche | 2017-04-13 21:21:38 -0700 (Thu, 13 Apr 2017) | 4 lines
  
  ib_srpt: Optimize Makefile
  
  Cache conftest results and enable parallel invocation of conftests.
........
  r7128 | bvassche | 2017-04-13 21:29:38 -0700 (Thu, 13 Apr 2017) | 4 lines
  
  iscsi-scst/Makefile: Optimize Makefile
  
  Cache conftest results and enable parallel invocation of conftests.
........
  r7129 | bvassche | 2017-04-14 13:46:50 -0700 (Fri, 14 Apr 2017) | 1 line
  
  ib_srpt: Fix two configuration tests
........
  r7130 | bvassche | 2017-04-14 13:47:26 -0700 (Fri, 14 Apr 2017) | 1 line
  
  isert-scst: Fix two configuration tests
........
  r7131 | bvassche | 2017-04-14 14:38:56 -0700 (Fri, 14 Apr 2017) | 6 lines
  
  iscsi-scst/Makefile: Fix detection of whether InfiniBand is enabled
  
  Inspecting modules.symbols is fine after a kernel has been installed but
  not if a kernel tree has not been installed. If a kernel tree has not
  been installed, check the .config file.
........
  r7132 | bvassche | 2017-04-14 21:10:31 -0700 (Fri, 14 Apr 2017) | 1 line
  
  iscsi-scst/Makefile: Add support for make -i
........
  r7133 | bvassche | 2017-04-14 21:10:44 -0700 (Fri, 14 Apr 2017) | 1 line
  
  srpt/Makefile: Add support for make -i
........
  r7138 | vlnb | 2017-04-20 17:57:10 -0700 (Thu, 20 Apr 2017) | 11 lines
  
  iscsi-scst: change local names of ioctl() and open() to not conflict
  
  Change local names of ioctl() and open() to not conflict with C library names.
  This isn't really a bug in a strictly kernel-resident build, but the change
  avoids symbol conflicts with libc when building for usermode.
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
  
  with some changes
........
  r7140 | vlnb | 2017-04-20 18:04:16 -0700 (Thu, 20 Apr 2017) | 9 lines
  
  iscsi-scstd: daemon handle EOF (rc == 0) from nl_fd
  
  Daemon now handles receipt of EOF (rc == 0) from nl_fd.  Probably this never
  happens in a real kernel build, but it does during shutdown in a usermode build
  and it seems like it is "generically correct" in either case.
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7142 | vlnb | 2017-04-20 18:17:53 -0700 (Thu, 20 Apr 2017) | 10 lines
  
  iscsi-scst: reset conn->rx_task in scsi_cmnd_start() for EXTRACHECKS
  
  In scsi_cmnd_start() conn->rx_task is intended to be set only during the
  call to _stage1_done, but there was no code to reset it.  It doesn't
  actually matter in execution, but it was a little confusing to wonder
  and try to understand why it wasn't reset.
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7144 | vlnb | 2017-04-20 18:36:34 -0700 (Thu, 20 Apr 2017) | 16 lines
  
  iscsi_scst: conn_lookup() skips any conn already closing
  
  This change helped a secondary problem I had under valgrind (due to some other
  bug) with initiators timing out and reconnecting their sessions faster than the
  threads were getting cleaned up (for one thing, valgrind only ever runs one
  thread at a time).
  
  It seems logical that the code in conn_lookup() would want to skip any
  connection that's already known closing in this case, for the same reason it
  searches the list in reverse.  And the dropping connections don't have to drop
  in order, so searching in reverse doesn't seem sufficient to avoid finding a
  wrong (stale, closing) connection structure.
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7145 | vlnb | 2017-04-21 20:04:34 -0700 (Fri, 21 Apr 2017) | 3 lines
  
  Web updates
........
  r7146 | vlnb | 2017-04-21 20:19:52 -0700 (Fri, 21 Apr 2017) | 3 lines
  
  Copyright updates
........
  r7147 | vlnb | 2017-04-21 20:21:07 -0700 (Fri, 21 Apr 2017) | 3 lines
  
  Web updates
........
  r7148 | vlnb | 2017-04-21 20:33:13 -0700 (Fri, 21 Apr 2017) | 3 lines
  
  Web updates
........
  r7149 | vlnb | 2017-04-21 20:50:03 -0700 (Fri, 21 Apr 2017) | 3 lines
  
  Web updates
........
  r7150 | vlnb | 2017-04-21 20:58:24 -0700 (Fri, 21 Apr 2017) | 3 lines
  
  Web updates
........
  r7151 | vlnb | 2017-04-21 21:15:21 -0700 (Fri, 21 Apr 2017) | 3 lines
  
  ql2x00t: howto update
........
  r7155 | vlnb | 2017-04-28 18:00:59 -0700 (Fri, 28 Apr 2017) | 8 lines
  
  scst: add mutex_lock/unlock around scst_alloc_add_acg()
  
  The CONFIG_SCST_PROC build was calling scst_alloc_add_acg() without holding the
  scst_mutex.
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7156 | bvassche | 2017-05-01 13:22:56 -0700 (Mon, 01 May 2017) | 1 line
  
  scst_debug: Remove a duplicated #include directive
........
  r7157 | bvassche | 2017-05-01 13:26:08 -0700 (Mon, 01 May 2017) | 3 lines
  
  Surround #include <linux/version.h> with #ifndef INSIDE_KERNEL_TREE / #endif
........
  r7159 | bvassche | 2017-05-01 22:18:05 -0700 (Mon, 01 May 2017) | 1 line
  
  scst_sysfs: Fix spelling in a source code comment
........
  r7160 | bvassche | 2017-05-01 22:28:29 -0700 (Mon, 01 May 2017) | 1 line
  
  qla2x00t: Convert the non-standard %Lx into %llx
........
  r7161 | bvassche | 2017-05-02 07:10:22 -0700 (Tue, 02 May 2017) | 1 line
  
  scripts: Update kernel download location
........
  r7164 | bvassche | 2017-05-02 11:32:56 -0700 (Tue, 02 May 2017) | 1 line
  
  scripts/generate-kernel-patch: Stop applying the put_page_callback and exec_req_fifo patches
........
  r7165 | bvassche | 2017-05-02 15:32:06 -0700 (Tue, 02 May 2017) | 4 lines
  
  Fix spelling of "Ardis Technologies"
  
  Reference: http://www.ddpsan.com/support-sales/about-us.
........
  r7166 | bvassche | 2017-05-03 19:36:37 -0700 (Wed, 03 May 2017) | 1 line
  
  scstadmin: Fix a few bugs in the regression test code
........
  r7167 | bvassche | 2017-05-03 19:45:35 -0700 (Wed, 03 May 2017) | 1 line
  
  scst_lib: Convert a comment into a runtime check
........
  r7172 | vlnb | 2017-05-10 20:57:04 -0700 (Wed, 10 May 2017) | 8 lines
  
  scst: scst_finish_cmd() not try to left-shift lba of -1
  
  Change scst_finish_cmd() so that it does not attempt to left-shift lba when it
  is -1 (the error value).  Left-shifting of a negative value is undefined in C.
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7174 | vlnb | 2017-05-12 20:30:07 -0700 (Fri, 12 May 2017) | 6 lines
  
  scst: add module parameter to control the copy manager auto assignment
  
  Reported-By: Guru Prasad <gp22online@gmail.com>
  Suggested-By: Sebastian Herbszt <herbszt@gmx.de>
........
  r7180 | bvassche | 2017-05-13 20:49:39 -0700 (Sat, 13 May 2017) | 5 lines
  
  scst_vdisk: Avoid shifting left by a negative number of bits
  
  scst_calc_block_shift() can return a negative number. Hence avoid
  1 << scst_calc_block_shift().  Detected by Coverity.
........
  r7181 | mlx-storage | 2017-05-14 06:45:02 -0700 (Sun, 14 May 2017) | 6 lines
  
  isert-scst: fix isert connection teardown flow
  
  Synchronizing the rdma_disconnect() with the post drain wr
  as other ULPs like iSER do.
  
  Signed-off-by: Israel Rukshin <israelr@mellanox.com>
........
  r7182 | bvassche | 2017-05-14 07:55:00 -0700 (Sun, 14 May 2017) | 1 line
  
  ib_srpt: Fix a logging statement
........
  r7183 | bvassche | 2017-05-14 11:49:04 -0700 (Sun, 14 May 2017) | 4 lines
  
  isert-scst: Enable type checking for isert portal pointers
  
  This patch does not change any functionality.
........
  r7184 | bvassche | 2017-05-14 11:53:01 -0700 (Sun, 14 May 2017) | 14 lines
  
  isert-scst: Avoid that shutdown sporadically hangs
  
  Waiting for other threads to release an object using code like
  "while (object->refcnt > 0) msleep(100)" without holding a reference
  on 'object' is wrong because the memory object points at may be freed
  before or while this loop is in progress. Hence introduce a global
  portal object count and wait on that count instead of waiting for
  the per-portal reference count to reach zero.
  
  The use-after-free was introduced in r6952 ("isert: faster release
  of isert_scst module").
  
  See also https://sourceforge.net/p/scst/tickets/2/.
........
  r7186 | bvassche | 2017-05-15 19:04:47 -0700 (Mon, 15 May 2017) | 1 line
  
  isert-scst: Fix a race condition that was introduced accidentally in r7184
........
  r7187 | vlnb | 2017-05-18 19:37:49 -0700 (Thu, 18 May 2017) | 8 lines
  
  scst: implement BLOCKIO devices "active" attribute
  
  Intended to be able to load  on passive side as described in
  https://sourceforge.net/p/scst/mailman/message/35549446/
  
  Suggested-by: Кирилл Тюшев <kirill.tyushev8@gmail.com>
........
  r7188 | vlnb | 2017-05-18 19:58:23 -0700 (Thu, 18 May 2017) | 21 lines
  
  qla2x00t: Disable Out-of-order processing by default
  
  From: Quinn Tran <quinn.tran@cavium.com>
  
  Out of order(OOO) processing requires initiator, switch
  and target to support OOO. In today¹s environment, none
  of the switches support OOO. OOO requires extra buffer
  space which affect performance. By turning ON this feature
  in QLogic's FW, it delays error recovery because droped
  frame is treated as out of order frame. We¹re turning OFF
  this option of speed up error recovery.
  
  Reviewed-by: Christoph Hellwig <hch@lst.de>
  Signed-off-by: Quinn Tran <quinn.tran@cavium.com>
  Signed-off-by: Himanshu Madhani <himanshu.madhani@cavium.com>
  
  Merge of mainline commit 300af14bdb28157090f0c6f89d244fda940082da
  
  EXPERIMENTAL!
........
  r7189 | vlnb | 2017-05-19 19:04:16 -0700 (Fri, 19 May 2017) | 9 lines
  
  scst: compute max_transfer args as long, not int
  
  Compute max_transfer args as long, not int, to avoid overflow when
  max_sg_cnt=32768 and PAGE_SHIFT=16 (64K PAGE_SIZE).  Note it is not
  only the min() call, but also the << PAGE_SHIFT needs to be long.
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7191 | vlnb | 2017-05-19 20:19:54 -0700 (Fri, 19 May 2017) | 6 lines
  
  scst: restore locking documentation comments
  
  Better to follow the common rule and always have locking expectations
  documented in addition to runtime checks. Partial revert of r7095.
........
  r7192 | vlnb | 2017-05-19 20:29:41 -0700 (Fri, 19 May 2017) | 5 lines
  
  scst: minor cleanup
  
  Let's keep it simple without unused functionality
........
  r7194 | vlnb | 2017-05-22 20:50:43 -0700 (Mon, 22 May 2017) | 91 lines
  
  scst: prevent possible memory reclaim deadlock
  
  Reported by lockdep:
  
  [  415.813281] =================================
  [  415.817626] [ INFO: inconsistent lock state ]
  [  415.821974] 4.10.12-scst-dbg #4 Tainted: G           O
  [  415.827360] ---------------------------------
  [  415.831705] inconsistent {RECLAIM_FS-ON-W} -> {IN-RECLAIM_FS-W} usage.
  [  415.838217] kswapd0/558 [HC0[0]:SC0[0]:HE1:SE1] takes:
  [  415.843342]  (sgv_pools_mutex){+.+.?.}, at: [<ffffffffa036d300>] __sgv_shrink+0x90/0x1d0 [scst]
  [  415.852075] {RECLAIM_FS-ON-W} state was registered at:
  [  415.857208]   mark_held_locks+0x6c/0x90
  [  415.861034]   lockdep_trace_alloc+0x8a/0xd0
  [  415.865210]   kmem_cache_alloc_node+0x32/0x2f0
  [  415.869670]   sgv_pool_create_node+0x186/0x2e0 [scst]
  [  415.874735]   sgv_pool_create+0x12/0x20 [scst]
  [  415.879194]   scst_sgv_pools_init+0xb9/0x3c0 [scst]
  [  415.884065]   __dev_user_set_opt+0x152/0x5f0 [scst_user]
  [  415.889367]   do_one_initcall+0x59/0x190
  [  415.893280]   do_init_module+0x6a/0x230
  [  415.897106]   load_module+0x591/0x830
  [  415.900758]   SYSC_init_module+0xd3/0x120
  [  415.904758]   SyS_init_module+0xe/0x10
  [  415.908501]   entry_SYSCALL_64_fastpath+0x18/0xad
  [  415.913193] irq event stamp: 3831137
  [  415.916763] hardirqs last  enabled at (3831137): [<ffffffff8106ff37>] __local_bh_enable_ip+0x67/0xd0
  [  415.925878] hardirqs last disabled at (3831135): [<ffffffff8106fefe>] __local_bh_enable_ip+0x2e/0xd0
  [  415.935018] softirqs last  enabled at (3831136): [<ffffffffa036c72d>] __sgv_can_be_shrunk+0x9d/0x180 [scst]
  [  415.944764] softirqs last disabled at (3831134): [<ffffffffa036c6e3>] __sgv_can_be_shrunk+0x53/0x180 [scst]
  [  415.954481]
  [  415.954481] other info that might help us debug this:
  [  415.960994]  Possible unsafe locking scenario:
  [  415.960994]
  [  415.966899]        CPU0
  [  415.969336]        ----
  [  415.971774]   lock(sgv_pools_mutex);
  [  415.975339]   <Interrupt>
  [  415.977950]     lock(sgv_pools_mutex);
  [  415.981691]
  [  415.981691]  *** DEADLOCK ***
  [  415.981691]
  [  415.987599] 1 lock held by kswapd0/558:
  [  415.991424]  #0:  (shrinker_rwsem){++++..}, at: [<ffffffff811ace5c>] T.1898+0x4c/0x100
  [  415.999329]
  [  415.999329] stack backtrace:
  [  416.003677] CPU: 2 PID: 558 Comm: kswapd0 Tainted: G           O    4.10.12-scst-dbg #4
  [  416.011663] Hardware name: Dell Inc. PowerEdge R710/00NH4P, BIOS 2.2.10 11/09/2010
  [  416.019216] Call Trace:
  [  416.021661]  dump_stack+0x6b/0xa0
  [  416.024968]  print_usage_bug+0x182/0x190
  [  416.028881]  ? print_circular_bug+0x110/0x110
  [  416.033226]  mark_lock_irq+0xee/0x290
  [  416.036879]  mark_lock+0x113/0x1a0
  [  416.040271]  mark_irqflags+0xb0/0x180
  [  416.043924]  __lock_acquire+0x245/0x610
  [  416.047750]  ? __lock_release+0x408/0x470
  [  416.051750]  lock_acquire+0xce/0x2b0
  [  416.055343]  ? __sgv_shrink+0x90/0x1d0 [scst]
  [  416.059689]  ? mutex_lock_nested+0x47/0x750
  [  416.063863]  mutex_lock_nested+0x82/0x750
  [  416.067888]  ? __sgv_shrink+0x90/0x1d0 [scst]
  [  416.072236]  ? put_lock_stats+0xe/0x30
  [  416.075975]  ? __lock_release+0x408/0x470
  [  416.080001]  ? __sgv_shrink+0x90/0x1d0 [scst]
  [  416.084349]  ? debug_smp_processor_id+0x17/0x20
  [  416.088868]  ? put_lock_stats+0xe/0x30
  [  416.092633]  ? __sgv_can_be_shrunk+0x9d/0x180 [scst]
  [  416.097588]  ? mark_held_locks+0x6c/0x90
  [  416.101500]  ? __local_bh_enable_ip+0x67/0xd0
  [  416.105873]  __sgv_shrink+0x90/0x1d0 [scst]
  [  416.110047]  ? __local_bh_enable_ip+0x67/0xd0
  [  416.114420]  sgv_scan_shrink+0x5d/0x120 [scst]
  [  416.118853]  do_shrink_slab+0x19b/0x5f0
  [  416.122678]  ? T.1898+0x4c/0x100
  [  416.125899]  ? down_read_trylock+0x60/0x80
  [  416.129985]  T.1898+0xb4/0x100
  [  416.133031]  shrink_node+0x62/0xa0
  [  416.136424]  balance_pgdat+0x1c8/0x2c0
  [  416.140164]  kswapd+0xa0/0x2b0
  [  416.143211]  ? preempt_count_sub+0x9f/0xe0
  [  416.147409]  ? schedule+0x4e/0xc0
  [  416.150715]  ? balance_pgdat+0x2c0/0x2c0
  [  416.154627]  kthread+0x111/0x150
  [  416.157849]  ? call_usermodehelper_exec_work+0xa0/0xa0
  [  416.162974]  ? __kthread_init_worker+0x80/0x80
  [  416.167407]  ? call_usermodehelper_exec_work+0xa0/0xa0
  [  416.172534]  ? call_usermodehelper_exec_work+0xa0/0xa0
  [  416.177660]  ret_from_fork+0x2e/0x40
........
  r7195 | vlnb | 2017-05-24 19:11:06 -0700 (Wed, 24 May 2017) | 8 lines
  
  iscsi-scst: cleanup
  
  There's no need to end-align the padding. Plus, it's not optimal to
  access front misaligned memory
  
  Reported-by: David Butterfield <dab21774@gmail.com>
........
  r7196 | vlnb | 2017-05-25 19:45:47 -0700 (Thu, 25 May 2017) | 5 lines
  
  scst_vdisk: add "active" attridute to the list of BLOCKIO add device attributes
  
  This is forgotten piece to r7187
........
  r7197 | vlnb | 2017-05-30 21:01:00 -0700 (Tue, 30 May 2017) | 3 lines
  
  scst: a better version of possible memory reclaim deadlock fix r7194
........
  r7198 | vlnb | 2017-05-31 20:46:06 -0700 (Wed, 31 May 2017) | 5 lines
  
  scst: cleanup of dead code
  
  Reported-By: David Butterfield <dab21774@gmail.com>
........
  r7199 | vlnb | 2017-05-31 20:49:26 -0700 (Wed, 31 May 2017) | 5 lines
  
  scst: scst_free_acg() not dereference NULL acg->tgt for proc interface
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7200 | vlnb | 2017-05-31 20:53:08 -0700 (Wed, 31 May 2017) | 11 lines
  
  iscsi-scst: fix a couple of bad-function-cast warnings
  
  This is a "marginal" warning, but there are only six of them in the SCST code
  and this fixes two of those.
  
  session.c:105:4: warning: cast from function call of type void * to non-matching type _Bool [-Wbad-function-cast]
  target.c:668:14: warning: cast from function call of type void * to non-matching type _Bool [-Wbad-function-cast]
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7201 | vlnb | 2017-05-31 21:04:45 -0700 (Wed, 31 May 2017) | 13 lines
  
  scst: remove a few unnecessary shadow declarations
  
  Remove a few "shadow" declarations that appear unnecessary and probably
  unintended.  (These are cases where a declaration in an inner scope hides
  another declaration of the same name in an outer scope.)
  
  Not all shadow declarations are superfluous -- so this particular compiler
  warning is one that cannot be simply heeded while half asleep.  But these
  particular ones I removed appear to be superfluous.
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7202 | vlnb | 2017-05-31 21:08:02 -0700 (Wed, 31 May 2017) | 8 lines
  
  usr: fix -Wmissing-prototypes warnings
  
  Fix all twelve [-Wmissing-prototypes] warnings by adding "static" to their
  declarations.
  
  Signed-off-by: David Butterfield <dab21774@gmail.com>
........
  r7204 | vlnb | 2017-06-02 21:02:22 -0700 (Fri, 02 Jun 2017) | 5 lines
  
  Fix dereference beyond last sg element
  
  Reported-By: David Butterfield <dab21774@gmail.com>
........
  r7205 | vlnb | 2017-06-05 21:20:09 -0700 (Mon, 05 Jun 2017) | 10 lines
  
  scst_vdisk: 'numa_node_id' signed attribute value fix
  
  The "numa_node_id" attribute reside in the scst_vdisk_dev struct as
  signed integer and may well be negative values (eg, -1), so move fetching
  it above the unsigned attributes and use kstrtoll() to retrieve the
  values.
  
  Signed-off-by: Marc A. Smith <marc.smith@parodyne.com>
........
  r7206 | vlnb | 2017-06-06 18:13:58 -0700 (Tue, 06 Jun 2017) | 3 lines
  
  scst: update ALUA documentation (Active/Non-Optimized)
........
  r7207 | vlnb | 2017-06-06 18:23:59 -0700 (Tue, 06 Jun 2017) | 3 lines
  
  scst: minor cleanup for previous commit
........


git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/3.2.x@7210 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-07-14 00:36:17 +00:00
2016-08-03 02:24:57 +00:00
2011-04-19 22:56:07 +00:00
2016-12-16 03:03:09 +00:00

Overview
========

This is the SCST development repository. It contains not a single
project SCST as one can think, but a number of them, which are divided
as the following:

1. SCST core in scst/ subdirectory

2. Administration utility for SCST core scstadmin in scstadmin/

3. Target drivers in own subdirectories qla2x00t/, iscsi-scst/, etc.

4. User space programs in usr/ subdirectory, like fileio_tgt.

5. Some various docs in doc/ subdirectory.

Those subprojects are in most cases independent from each other,
although some of them depend from the SCST core. They put in the single
repository only to simplify their development, they are released
independently.

Thus, use "make all" only if you really need to build everything.
Otherwise build only what you need, like for iSCSI-SCST:

make scst scst_install iscsi iscsi_install

For more information about each subproject see their README files.


QLogic target driver
====================

QLogic target driver qla2x00t is the old driver, forked from qla2xxx
several years ago. It is very stable, well tested and actively used in
many production setups. The ultimate goal is to have the mainstream
(git) QLogic target driver to be the main and the only QLogic target
driver, but, unfortunately, this driver not yet reached level of quality
and maturity of qla2x00t. We with QLogic are working toward it.

You can find the latest version of the git driver in git://git.qlogic.com/scst-qla2xxx.git.
It is maintained by QLogic, hence located in the QLogic's git.

To integrate it into the SCST build tree you need:

1. Clone the QLogic git tree somewhere in your system.

2. Create in the SCST root, i.e. this directory, a subdirectory with name
qla2x00t_git

3. Optional for the in-tree build: symlink drivers/scsi/qla2xxx
subdirectory in the cloned git tree to the qla2x00t_git subdirectory

Thats all. Now common and QLA specific root Makefile targets "magically"
start working with the new driver.

For detail instructions how to setup QLA target build environment see
its README or HOWTO. Run either "make all" to build the SCST core and
all target drivers with in-tree QLogic drivers, or the following command
with standalone QLogic drivers:

BUILD_2X_MODULE=y CONFIG_SCSI_QLA_FC=y CONFIG_SCSI_QLA2XXX_TARGET=y make all

In presence of qla2x00t_git subdirectory you can still build the
qla2x00t using qla_old* root Makefile targets.

Vladislav Bolkhovitin <vst@vlnb.net>, http://scst.sourceforge.net
Description
No description provided
Readme 33 MiB
Languages
C 90.1%
Perl 4.2%
Shell 1.8%
HTML 1.7%
Makefile 1.2%
Other 0.9%