12 Apr, 2016

2 commits

  • Running the command "git grep -nHw scsi_is_fc_vport" shows that this
    function is only called from inside scsi_transport_fc.c. Hence unexport
    this function.

    Signed-off-by: Bart Van Assche
    Cc: Hannes Reinecke
    Cc: James Smart
    Reviewed-by: Hannes Reinicke
    Signed-off-by: Martin K. Petersen

    Bart Van Assche
     
  • On larger installations it is useful to disable automatic LUN scanning,
    and only add the required LUNs via udev rules. This can speed up bootup
    dramatically.

    This patch introduces a new scan module parameter value 'manual', which
    works like 'none', but can be overridden by setting the 'rescan' value
    from scsi_scan_target to 'SCSI_SCAN_MANUAL'. And it updates all
    relevant callers to set the 'rescan' value to 'SCSI_SCAN_MANUAL' if
    invoked via the 'scan' option in sysfs.

    Signed-off-by: Hannes Reinecke
    Reviewed-by: Ewan D. Milne
    Tested-by: Laurence Oberman
    Signed-off-by: Martin K. Petersen

    Hannes Reinecke
     

01 Dec, 2015

1 commit

  • Use scsi_host_{get,put}() instead of open-coding these functions.
    Compile-tested only.

    [mkp: Dropped CC:stable and fixed James Smart's email address]

    Signed-off-by: Bart Van Assche
    Reviewed-by: Christoph Hellwig
    Reviewed-by: Johannes Thumshirn
    Cc: Christoph Hellwig
    Cc: Hannes Reinecke
    Cc: James Smart
    Signed-off-by: Martin K. Petersen

    Bart Van Assche
     

10 Apr, 2015

1 commit


26 Jul, 2014

1 commit


18 Jul, 2014

2 commits

  • Now that the ibmvstgt driver as the only user of scsi_tgt is gone, the
    scsi_tgt kernel module, the CONFIG_SCSI_TGT, CONFIG_SCSI_SRP_TGT_ATTRS and
    CONFIG_SCSI_FC_TGT_ATTRS kbuild variable, the scsi_host_template
    transfer_response method are no longer needed.

    [hch: minor updates to the current tree, changelog update]

    Signed-off-by: Bart Van Assche
    Signed-off-by: Christoph Hellwig
    Reviewed-by: Paolo Bonzini
    Reviewed-by: Hannes Reinecke

    Bart Van Assche
     
  • The SCSI standard defines 64-bit values for LUNs, and large arrays
    employing large or hierarchical LUN numbers become more and more
    common.

    So update the linux SCSI stack to use 64-bit LUN numbers.

    Signed-off-by: Hannes Reinecke
    Reviewed-by: Christoph Hellwig
    Reviewed-by: Ewan Milne
    Signed-off-by: Christoph Hellwig

    Hannes Reinecke
     

25 Jun, 2014

1 commit

  • debugfs caught this:
    WARNING: at lib/debugobjects.c:260 debug_print_object+0x83/0xa0()
    ODEBUG: free active (active state 0) object type: work_struct
    hint: fc_scsi_scan_rport+0x0/0xd0 [scsi_transport_fc]
    CPU: 1 PID: 184 Comm: kworker/1:1 Tainted: G W
    -------------- 3.10.0-123.el7.x86_64.debug #1
    Hardware name: HP ProLiant DL120 G7, BIOS J01 07/01/2013
    Workqueue: fc_wq_5 fc_rport_final_delete [scsi_transport_fc]
    Call Trace:
    [] dump_stack+0x19/0x1b
    [] warn_slowpath_common+0x61/0x80
    [] warn_slowpath_fmt+0x5c/0x80
    [] debug_print_object+0x83/0xa0
    [] ? fc_parse_wwn+0x100/0x100

    [] debug_check_no_obj_freed+0x22b/0x270
    [] ? fc_rport_dev_release+0x1e/0x30
    [] kfree+0xd9/0x2d0
    [] fc_rport_dev_release+0x1e/0x30
    [] device_release+0x32/0xa0
    [] kobject_release+0x7e/0x1b0
    [] kobject_put+0x28/0x60
    [] put_device+0x17/0x20
    [] fc_rport_final_delete+0x165/0x210
    [] process_one_work+0x220/0x710
    [] ? process_one_work+0x1b4/0x710
    [] worker_thread+0x11b/0x3a0
    [] ? process_one_work+0x710/0x710
    [] kthread+0xed/0x100
    [] ? insert_kthread_work+0x80/0x80
    [] ret_from_fork+0x7c/0xb0
    [] ? insert_kthread_work+0x80/0x80

    Seems to be because the scan_work work_struct might be active when the housing
    fc_rport struct gets freed. Ensure that we cancel it prior to freeing the rport

    Signed-off-by: Neil Horman
    Reviewed-by: Vasu Dev
    Reviewed-by: Hannes Reinecke
    Signed-off-by: Christoph Hellwig

    Neil Horman
     

16 Mar, 2014

1 commit


04 Jul, 2013

1 commit

  • For the workqueue creation interfaces that do not expect format strings,
    make sure they cannot accidently be parsed that way. Additionally, clean
    up calls made with a single parameter that would be handled as a format
    string. Many callers are passing potentially dynamic string content, so
    use "%s" in those cases to avoid any potential accidents.

    Signed-off-by: Kees Cook
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Kees Cook
     

29 Mar, 2013

1 commit


02 Aug, 2012

1 commit

  • Pull core block IO bits from Jens Axboe:
    "The most complicated part if this is the request allocation rework by
    Tejun, which has been queued up for a long time and has been in
    for-next ditto as well.

    There are a few commits from yesterday and today, mostly trivial and
    obvious fixes. So I'm pretty confident that it is sound. It's also
    smaller than usual."

    * 'for-3.6/core' of git://git.kernel.dk/linux-block:
    block: remove dead func declaration
    block: add partition resize function to blkpg ioctl
    block: uninitialized ioc->nr_tasks triggers WARN_ON
    block: do not artificially constrain max_sectors for stacking drivers
    blkcg: implement per-blkg request allocation
    block: prepare for multiple request_lists
    block: add q->nr_rqs[] and move q->rq.elvpriv to q->nr_rqs_elvpriv
    blkcg: inline bio_blkcg() and friends
    block: allocate io_context upfront
    block: refactor get_request[_wait]()
    block: drop custom queue draining used by scsi_transport_{iscsi|fc}
    mempool: add @gfp_mask to mempool_create_node()
    blkcg: make root blkcg allocation use %GFP_KERNEL
    blkcg: __blkg_lookup_create() doesn't need radix preload

    Linus Torvalds
     

20 Jul, 2012

2 commits

  • This has scsi_internal_device_unblock/scsi_target_unblock take
    the new state to set the devices as an argument instead of
    always setting to running. The patch also converts users of these
    functions.

    This allows the FC and iSCSI class to transition devices from blocked
    to transport-offline, so that when fast_io_fail/replacement_timeout
    has fired we do not set the devices back to running. Instead, we
    set them to SDEV_TRANSPORT_OFFLINE.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     
  • The libfc provides more flexibility and with that
    we can monitor some more FC specific stats for
    FC exches or FCP error cases, this patch add
    such new FC stats.

    The patch adds *only* FC specific new stats to
    existing fc_host attribute container.

    Added stats names are self explanatory as
    existing FC stats already has, however anyway
    still added commentary along their definition
    to describe them.

    Signed-off-by: Vasu Dev
    Acked-by : Robert Love
    Tested-by: Ross Brattain
    Signed-off-by: James Bottomley

    Vasu Dev
     

25 Jun, 2012

1 commit

  • iscsi_remove_host() uses bsg_remove_queue() which implements custom
    queue draining. fc_bsg_remove() open-codes mostly identical logic.

    The draining logic isn't correct in that blk_stop_queue() doesn't
    prevent new requests from being queued - it just stops processing, so
    nothing prevents new requests to be queued after the logic determines
    that the queue is drained.

    blk_cleanup_queue() now implements proper queue draining and these
    custom draining logics aren't necessary. Drop them and use
    bsg_unregister_queue() + blk_cleanup_queue() instead.

    Signed-off-by: Tejun Heo
    Reviewed-by: Mike Christie
    Acked-by: Vivek Goyal
    Cc: James Bottomley
    Cc: James Smart
    Signed-off-by: Jens Axboe

    Tejun Heo
     

10 May, 2012

1 commit

  • When a rport is added back or the role is changed the fc class
    will queue a scan and then call scsi_target_unblock. The problem
    with this is if the devices are in the SDEV_OFFLINE state and
    the scan is run before the scsi_target_unblock, then the scan
    will see LUN0 as offline and the scan will fail. This patch moves
    the unblock call to before the scan, so we know the device state
    will be set correctly when the scan is run.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     

19 Feb, 2012

1 commit

  • This adds FC-GS Fabric Device Management Interface
    (FDMI) related attributes to fc_host_attr structure.

    This is in preparation for allowing FDMI attributes
    to be registered via libfc.

    Signed-off-by: Neerav Parikh
    Tested-by: Ross Brattain
    Acked-by: Robert Love
    Signed-off-by: James Bottomley

    Neerav Parikh
     

16 Jan, 2012

1 commit

  • This patch fixes a bug where devloss is not called on fc_host teardown.
    The issue is seen if the LLDD uses rport_rolechg to add the target role
    to an rport.

    When an rport goes away, the LLDD will call fc_remote_port_delete, which
    will start the devloss timer. If the timer expires, the transport will
    call the devloss callback and set the FC_RPORT_DEVLOSS_CALLBK_DONE flag.
    However, the rport structure is not deleted, it is retained to store the
    SCSI id mappings for the rport in case it comes back. In the scenario
    where it does come back, and the driver calls fc_remote_port_add, but does
    not indicate the "target" role for the rport - the create will clear the
    structure, but forgets to clear FC_RPORT_DEVLOSS_CALLBK_DONE flag (which
    is cleared if it's added with the target role). The secondary call, of
    fc_remote_port_rolechg to add the target role also does not clear the flag.
    Thus, the next time the rport goes away, the resulting devloss timer
    expiration will not call the driver callback as the flag is still set.

    This patch adds the FC_RPORT_DEVLOSS_CALLBK_DONE flags to the list of
    those that are cleared upon reuse of the rport structure.

    Signed-off-by: Alex Iannicelli
    Signed-off-by: James Smart
    Signed-off-by: James Bottomley

    James Smart
     

21 May, 2011

1 commit

  • * git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6: (110 commits)
    [SCSI] qla2xxx: Refactor call to qla2xxx_read_sfp for thermal temperature.
    [SCSI] qla2xxx: Unify the read/write sfp mailbox command routines.
    [SCSI] qla2xxx: Clear complete initialization control block.
    [SCSI] qla2xxx: Allow an override of the registered maximum LUN.
    [SCSI] qla2xxx: Add host number in reset and quiescent message logs.
    [SCSI] qla2xxx: Correctly read sfp single byte mailbox register.
    [SCSI] qla2xxx: Add qla82xx_rom_unlock() function.
    [SCSI] qla2xxx: Log if qla82xx firmware fails to load from flash.
    [SCSI] qla2xxx: Use passed in host to initialize local scsi_qla_host in queuecommand function
    [SCSI] qla2xxx: Correct buffer start in edc sysfs debug print.
    [SCSI] qla2xxx: Update firmware version after flash update for ISP82xx.
    [SCSI] qla2xxx: Fix hang during driver unload when vport is active.
    [SCSI] qla2xxx: Properly set the dsd_list_len for dsd_chaining in cmd type 6.
    [SCSI] qla2xxx: Fix virtual port failing to login after chip reset.
    [SCSI] qla2xxx: Fix vport delete hang when logins are outstanding.
    [SCSI] hpsa: Change memset using sizeof(ptr) to sizeof(*ptr)
    [SCSI] ipr: Rate limit DMA mapping errors
    [SCSI] hpsa: add P2000 to list of shared SAS devices
    [SCSI] hpsa: do not attempt PCI power management reset method if we know it won't work.
    [SCSI] hpsa: remove superfluous sleeps around reset code
    ...

    Linus Torvalds
     

02 May, 2011

1 commit

  • Creating and destroying fcoe interface in a tight loop leads to a system
    deadlock with the following call traces:

    Call Trace:
    [] schedule_timeout+0x1fd/0x2c0
    [] ? wait_for_common+0x4f/0x190
    [] ? wait_for_common+0x4f/0x190
    [] wait_for_common+0xe7/0x190
    [] ? default_wake_function+0x0/0x20
    [] ? trace_hardirqs_on+0xd/0x10
    [] wait_for_completion+0x1d/0x20
    [] flush_workqueue+0x290/0x5f0
    [] ? flush_workqueue+0x0/0x5f0
    [] destroy_workqueue+0x38/0x340
    [] fc_remove_host+0x1b9/0x1f0 [scsi_transport_fc]
    [] bnx2fc_if_destroy+0xc5/0x1f0 [bnx2fc]
    [] bnx2fc_destroy+0x7a/0x100 [bnx2fc]
    [] fcoe_transport_destroy+0x9b/0x1b0 [libfcoe]
    [] param_attr_store+0x52/0x80
    [] module_attr_store+0x26/0x30
    [] sysfs_write_file+0xe6/0x170
    [] vfs_write+0xd0/0x1a0
    [] sys_write+0x54/0xa0
    [] system_call_fastpath+0x16/0x1b
    Call Trace:
    [] async_synchronize_cookie_domain+0x75/0x120
    [] ? autoremove_wake_function+0x0/0x40
    [] async_synchronize_cookie+0x15/0x20
    [] async_synchronize_full+0x1c/0x40
    [] sd_remove+0x36/0xc0 [sd_mod]
    [] __device_release_driver+0x75/0xe0
    [] device_release_driver+0x2f/0x50
    [] bus_remove_device+0xbe/0x120
    [] device_del+0x12f/0x1e0
    [] __scsi_remove_device+0xbd/0xc0
    [] scsi_remove_device+0x35/0x50
    [] __scsi_remove_target+0xe7/0x110
    [] ? __remove_child+0x0/0x30
    [] __remove_child+0x23/0x30
    [] device_for_each_child+0x4c/0x80
    [] scsi_remove_target+0x33/0x60
    [] fc_starget_delete+0x26/0x30 [scsi_transport_fc]
    [] fc_rport_final_delete+0xaa/0x200 [scsi_transport_fc]
    [] process_one_work+0x1aa/0x540
    [] ? process_one_work+0x13b/0x540
    [] ? fc_rport_final_delete+0x0/0x200 [scsi_transport_fc]
    [] worker_thread+0x179/0x410
    [] ? worker_thread+0x0/0x410
    [] kthread+0xb6/0xc0
    [] ? finish_task_switch+0x4b/0xe0
    [] kernel_thread_helper+0x4/0x10
    [] ? restore_args+0x0/0x30
    [] ? kthread+0x0/0xc0
    [] ? kernel_thread_helper+0x0/0x10

    fc_remove_host() waits for flushing the workqueue, but it is stuck at flushing
    the first work. The first work doesnt complete, because it is waiting for async
    layer to complete the IOs. The async layer cannot complete the IO as the
    terminate_rport_io for the second work was not called, which will be called
    only when the first work completes. Hence the deadlock. To resolve this
    deadlock, the workqueue allocation has been modified from
    create_singlethread_workqueue() to alloc_workqueue().

    In addition, fc_terminate_rport_io() should be called before the
    scsi_flush_work() to avoid the similar deadlock as above.

    scsi fc alloc queue. move terminate rport io before flush

    Signed-off-by: Nithin Nayak Sujir
    Signed-off-by: Bhanu Prakash Gollapudi
    Signed-off-by: James Bottomley

    Nithin Nayak Sujir
     

19 Apr, 2011

1 commit

  • We are currently using this flag to check whether it's safe
    to call into ->request_fn(). If it is set, we punt to kblockd.
    But we get a lot of false positives and excessive punts to
    kblockd, which hurts performance.

    The only real abuser of this infrastructure is SCSI. So export
    the async queue run and convert SCSI over to use that. There's
    room for improvement in that SCSI need not always use the async
    call, but this fixes our performance issue and they can fix that
    up in due time.

    Signed-off-by: Jens Axboe

    Jens Axboe
     

18 Apr, 2011

1 commit

  • Instead of overloading __blk_run_queue to force an offload to kblockd
    add a new blk_run_queue_async helper to do it explicitly. I've kept
    the blk_queue_stopped check for now, but I suspect it's not needed
    as the check we do when the workqueue items runs should be enough.

    Signed-off-by: Christoph Hellwig
    Signed-off-by: Jens Axboe

    Christoph Hellwig
     

31 Mar, 2011

1 commit


10 Mar, 2011

2 commits


02 Mar, 2011

1 commit

  • __blk_run_queue() automatically either calls q->request_fn() directly
    or schedules kblockd depending on whether the function is recursed.
    blk-flush implementation needs to be able to explicitly choose
    kblockd. Add @force_kblockd.

    All the current users are converted to specify %false for the
    parameter and this patch doesn't introduce any behavior change.

    stable: This is prerequisite for fixing ide oops caused by the new
    blk-flush implementation.

    Signed-off-by: Tejun Heo
    Cc: Jan Beulich
    Cc: James Bottomley
    Cc: stable@kernel.org
    Signed-off-by: Jens Axboe

    Tejun Heo
     

08 Oct, 2010

1 commit

  • This adds a fc host dev loss sysfs file. Instead of
    calling into the driver using the get_host_def_dev_loss_tmo
    callback, we allow drivers to init the dev loss like is done
    for other fc host params, and then the fc class will handle
    updating the value if the user writes to the new sysfs file.

    Signed-off-by: Mike Christie
    Signed-off-by: James Bottomley

    Mike Christie
     

10 Sep, 2010

1 commit

  • When an rport is "blocked" and a bsg request is received, the bsg request gets
    placed on the queue but the queue stalls. If the fc object is then deleted - the
    bsg queue never restarts and keeps the reference on the object, and stops the
    overall teardown.

    This patch restarts the bsg queue on teardown and drains any pending requests,
    allowing the teardown to succeed.

    Signed-off-by: Carl Lajeunesse
    Signed-off-by: James Smart
    Signed-off-by: James Bottomley

    James Smart
     

06 Sep, 2010

1 commit


11 Aug, 2010

1 commit


17 Jun, 2010

1 commit


11 Apr, 2010

2 commits

  • If the scsi eh is running and then a FC LLD calls
    fc_remote_port_delete, the SCSI commands sent from the eh will fail.
    To prevent this, a FC LLD can call fc_block_scsi_eh from the eh
    callback, blocking the eh thread until the dev_loss_tmo fires or the
    remote port is available again.

    If (e.g. for a multipathing setup) the dev_loss_tmo is set to a very
    large value, thus preventing the scsi device removal , the scsi eh can
    block for a long time. For multipathing, the fast_io_fail_tmo is then
    set to a low value to detect path problems sooner.

    This patch introduces a new return code FAST_IO_FAIL. The function
    fc_block_scsi_eh now returns FAST_IO_FAIL when the fast_io_fail_tmo
    fires. This indicates that the LLD terminated all pending I/O requests
    and there are no more pending SCSI commands for the scsi eh to wait
    for. This return code can be passed back to the scsi eh to stop the
    escalation and finish the recovery process for this device.

    Signed-off-by: Christof Schmitt
    Signed-off-by: James Bottomley

    Christof Schmitt
     
  • The rport structure defines dev_loss_tmo as u32, which is
    later multiplied with HZ to get the actual timeout value.
    This might overflow for large dev_loss_tmo values. So we
    should be better using u64 as intermediate variables here
    to protect against overflow.

    Signed-off-by: Hannes Reinecke
    Acked-by: James Smart
    Signed-off-by: James Bottomley

    Hannes Reinecke
     

06 Apr, 2010

1 commit

  • * git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6:
    [SCSI] qla1280: retain firmware for error recovery
    [SCSI] attirbute_container: Initialize sysfs attributes with sysfs_attr_init
    [SCSI] advansys: fix regression with request_firmware change
    [SCSI] qla2xxx: Updated version number to 8.03.02-k2.
    [SCSI] qla2xxx: Prevent sending mbx commands from sysfs during isp reset.
    [SCSI] qla2xxx: Disable MSI on qla24xx chips other than QLA2432.
    [SCSI] qla2xxx: Check to make sure multique and CPU affinity support is not enabled at the same time.
    [SCSI] qla2xxx: Correct vp_idx checking during PORT_UPDATE processing.
    [SCSI] qla2xxx: Honour "Extended BB credits" bit for CNAs.
    [SCSI] scsi_transport_fc: Make sure commands are completed when rport is offline
    [SCSI] libiscsi: Fix recovery slowdown regression

    Linus Torvalds
     

30 Mar, 2010

1 commit

  • …it slab.h inclusion from percpu.h

    percpu.h is included by sched.h and module.h and thus ends up being
    included when building most .c files. percpu.h includes slab.h which
    in turn includes gfp.h making everything defined by the two files
    universally available and complicating inclusion dependencies.

    percpu.h -> slab.h dependency is about to be removed. Prepare for
    this change by updating users of gfp and slab facilities include those
    headers directly instead of assuming availability. As this conversion
    needs to touch large number of source files, the following script is
    used as the basis of conversion.

    http://userweb.kernel.org/~tj/misc/slabh-sweep.py

    The script does the followings.

    * Scan files for gfp and slab usages and update includes such that
    only the necessary includes are there. ie. if only gfp is used,
    gfp.h, if slab is used, slab.h.

    * When the script inserts a new include, it looks at the include
    blocks and try to put the new include such that its order conforms
    to its surrounding. It's put in the include block which contains
    core kernel includes, in the same order that the rest are ordered -
    alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
    doesn't seem to be any matching order.

    * If the script can't find a place to put a new include (mostly
    because the file doesn't have fitting include block), it prints out
    an error message indicating which .h file needs to be added to the
    file.

    The conversion was done in the following steps.

    1. The initial automatic conversion of all .c files updated slightly
    over 4000 files, deleting around 700 includes and adding ~480 gfp.h
    and ~3000 slab.h inclusions. The script emitted errors for ~400
    files.

    2. Each error was manually checked. Some didn't need the inclusion,
    some needed manual addition while adding it to implementation .h or
    embedding .c file was more appropriate for others. This step added
    inclusions to around 150 files.

    3. The script was run again and the output was compared to the edits
    from #2 to make sure no file was left behind.

    4. Several build tests were done and a couple of problems were fixed.
    e.g. lib/decompress_*.c used malloc/free() wrappers around slab
    APIs requiring slab.h to be added manually.

    5. The script was run on all .h files but without automatically
    editing them as sprinkling gfp.h and slab.h inclusions around .h
    files could easily lead to inclusion dependency hell. Most gfp.h
    inclusion directives were ignored as stuff from gfp.h was usually
    wildly available and often used in preprocessor macros. Each
    slab.h inclusion directive was examined and added manually as
    necessary.

    6. percpu.h was updated not to include slab.h.

    7. Build test were done on the following configurations and failures
    were fixed. CONFIG_GCOV_KERNEL was turned off for all tests (as my
    distributed build env didn't work with gcov compiles) and a few
    more options had to be turned off depending on archs to make things
    build (like ipr on powerpc/64 which failed due to missing writeq).

    * x86 and x86_64 UP and SMP allmodconfig and a custom test config.
    * powerpc and powerpc64 SMP allmodconfig
    * sparc and sparc64 SMP allmodconfig
    * ia64 SMP allmodconfig
    * s390 SMP allmodconfig
    * alpha SMP allmodconfig
    * um on x86_64 SMP allmodconfig

    8. percpu.h modifications were reverted so that it could be applied as
    a separate patch and serve as bisection point.

    Given the fact that I had only a couple of failures from tests on step
    6, I'm fairly confident about the coverage of this conversion patch.
    If there is a breakage, it's likely to be something in one of the arch
    headers which should be easily discoverable easily on most builds of
    the specific arch.

    Signed-off-by: Tejun Heo <tj@kernel.org>
    Guess-its-ok-by: Christoph Lameter <cl@linux-foundation.org>
    Cc: Ingo Molnar <mingo@redhat.com>
    Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>

    Tejun Heo
     

28 Mar, 2010

1 commit


09 Mar, 2010

1 commit

  • The issue occur while deleting 60 virtual ports through the sys
    interface /sys/class/fc_vports/vport-X/vport_delete. It happen while in
    a mistake each request sent twice for the same vport. This interface is
    asynchronous, entering the delete request into a work queue, allowing
    more than one request to enter to the delete work queue. The result is a
    NULL pointer. The first request already delete the vport, while the
    second request got a pointer to the vport before the device destroyed.
    Re-create vport later cause system freeze.

    Solution: Check vport flags before entering the request to the work queue.

    [jejb: fixed intlong problem on spinlock flags variable]
    Signed-off-by: Gal Rosen
    Acked-by: James Smart
    Cc: Stable Tree
    Signed-off-by: James Bottomley

    Gal Rosen
     

19 Jan, 2010

1 commit

  • Currently dev_loss_tmo is capped by SCSI_DEVICE_BLOCK_MAX_TIMEOUT.
    This causes problem with multipathing when the 'no_path_retry' setting
    exceeds the dev_loss_tmo setting, as then the system might run into
    a deadlock when all paths have been removed temporarily for longer
    than dev_loss_tmo.
    The principal reasons for the capping has been that we should
    not allow a remote port to remain in status 'blocked' indefinitely,
    so the capping is there to ensure that the port status is being reset
    eventually.
    However, the fast_io_fail_tmo will also move the remote port out of
    the 'blocked' state, so for any HBA driver implementing both the
    capping should really be on the fast_io_fail_tmo, and not on the
    dev_loss_tmo.
    This patch implements just that, ie the fast_io_fail_tmo is capped
    to SCSI_DEVICE_BLOCK_TIMEOUT and the capping is removed from
    dev_loss_tmo when fast_io_fail_tmo is set.
    This allows us to synchronize the dev_loss_tmo setting to the
    'no_path_retry' setting from multipathing thus avoiding the deadlock.

    Signed-off-by: Hannes Reinecke
    Acked-by: James Smart
    Signed-off-by: James Bottomley

    Hannes Reinecke
     

18 Jan, 2010

1 commit

  • The hardware used with zfcp cannot abort a currently pending CT or ELS
    request. Therefore we need the option to postpone the timeout
    triggered request abort within the fc layer, since there is nothing
    zfcp can do to stop the request at this point.

    Cc: James Smart
    Signed-off-by: Swen Schillig
    Signed-off-by: Christof Schmitt
    Signed-off-by: James Bottomley

    Swen Schillig
     

10 Dec, 2009

1 commit