19 Oct, 2014

1 commit

  • Pull core block layer changes from Jens Axboe:
    "This is the core block IO pull request for 3.18. Apart from the new
    and improved flush machinery for blk-mq, this is all mostly bug fixes
    and cleanups.

    - blk-mq timeout updates and fixes from Christoph.

    - Removal of REQ_END, also from Christoph. We pass it through the
    ->queue_rq() hook for blk-mq instead, freeing up one of the request
    bits. The space was overly tight on 32-bit, so Martin also killed
    REQ_KERNEL since it's no longer used.

    - blk integrity updates and fixes from Martin and Gu Zheng.

    - Update to the flush machinery for blk-mq from Ming Lei. Now we
    have a per hardware context flush request, which both cleans up the
    code should scale better for flush intensive workloads on blk-mq.

    - Improve the error printing, from Rob Elliott.

    - Backing device improvements and cleanups from Tejun.

    - Fixup of a misplaced rq_complete() tracepoint from Hannes.

    - Make blk_get_request() return error pointers, fixing up issues
    where we NULL deref when a device goes bad or missing. From Joe
    Lawrence.

    - Prep work for drastically reducing the memory consumption of dm
    devices from Junichi Nomura. This allows creating clone bio sets
    without preallocating a lot of memory.

    - Fix a blk-mq hang on certain combinations of queue depths and
    hardware queues from me.

    - Limit memory consumption for blk-mq devices for crash dump
    scenarios and drivers that use crazy high depths (certain SCSI
    shared tag setups). We now just use a single queue and limited
    depth for that"

    * 'for-3.18/core' of git://git.kernel.dk/linux-block: (58 commits)
    block: Remove REQ_KERNEL
    blk-mq: allocate cpumask on the home node
    bio-integrity: remove the needless fail handle of bip_slab creating
    block: include func name in __get_request prints
    block: make blk_update_request print prefix match ratelimited prefix
    blk-merge: don't compute bi_phys_segments from bi_vcnt for cloned bio
    block: fix alignment_offset math that assumes io_min is a power-of-2
    blk-mq: Make bt_clear_tag() easier to read
    blk-mq: fix potential hang if rolling wakeup depth is too high
    block: add bioset_create_nobvec()
    block: use bio_clone_fast() in blk_rq_prep_clone()
    block: misplaced rq_complete tracepoint
    sd: Honor block layer integrity handling flags
    block: Replace strnicmp with strncasecmp
    block: Add T10 Protection Information functions
    block: Don't merge requests if integrity flags differ
    block: Integrity checksum flag
    block: Relocate bio integrity flags
    block: Add a disk flag to block integrity profile
    block: Add prefix to block integrity profile flags
    ...

    Linus Torvalds
     

08 Oct, 2014

1 commit


01 Oct, 2014

2 commits

  • Some devices may respond with wrong type for well-known logical units.
    This patch forces well-known type for devices which doesn't report it
    correct.

    Signed-off-by: Subhash Jadavani
    Signed-off-by: Sujit Reddy Thumma
    Signed-off-by: Dolev Raviv
    Signed-off-by: Christoph Hellwig

    Subhash Jadavani
     
  • A set of flags introduced in the block layer enable better control over
    how protection information is handled. These flags are useful for both
    error injection and data recovery purposes. Checking can be enabled and
    disabled for controller and disk, and the guard tag format is now a
    per-I/O property.

    Update sd_protect_op to communicate the relevant information to the
    low-level device driver via a set of flags in scsi_cmnd.

    Signed-off-by: Martin K. Petersen
    Reviewed-by: Sagi Grimberg
    Acked-by: Christoph Hellwig
    Signed-off-by: Jens Axboe

    Martin K. Petersen
     

30 Sep, 2014

1 commit


23 Sep, 2014

1 commit

  • Don't do a kmalloc from timer to handle timeouts, chances are we could be
    under heavy load or similar and thus just miss out on the timeouts.
    Fortunately it is very easy to just iterate over all in use tags, and doing
    this properly actually cleans up the blk_mq_busy_iter API as well, and
    prepares us for the next patch by passing a reserved argument to the
    iterator.

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

    Christoph Hellwig
     

16 Sep, 2014

3 commits

  • The SCSI specification requires that the second Command Data Byte
    should contain the LUN value in its high-order bits if the recipient
    device reports SCSI level 2 or below. Nevertheless, some USB
    mass-storage devices use those bits for other purposes in
    vendor-specific commands. Currently Linux has no way to send such
    commands, because the SCSI stack always overwrites the LUN bits.

    Testing shows that Windows 7 and XP do not store the LUN bits in the
    CDB when sending commands to a USB device. This doesn't matter if the
    device uses the Bulk-Only or UAS transports (which virtually all
    modern USB mass-storage devices do), as these have a separate
    mechanism for sending the LUN value.

    Therefore this patch introduces a flag in the Scsi_Host structure to
    inform the SCSI midlayer that a transport does not require the LUN
    bits to be stored in the CDB, and it makes usb-storage set this flag
    for all devices using the Bulk-Only transport. (UAS is handled by a
    separate driver, but it doesn't really matter because no SCSI-2 or
    lower device is at all likely to use UAS.)

    The patch also cleans up the code responsible for storing the LUN
    value by adding a bitflag to the scsi_device structure. The test for
    whether to stick the LUN value in the CDB can be made when the device
    is probed, and stored for future use rather than being made over and
    over in the fast path.

    Signed-off-by: Alan Stern
    Reported-by: Tiziano Bacocco
    Acked-by: Martin K. Petersen
    Acked-by: James Bottomley
    Signed-off-by: Christoph Hellwig

    Alan Stern
     
  • Add a use_cmd_list flag in struct Scsi_Host to request keeping track of
    all outstanding commands per device.

    Default behaviour is not to keep track of cmd_list per sdev, as this may
    introduce lock contention. (overhead is more on multi-node NUMA.), and
    only enable it on the two drivers that need it.

    Signed-off-by: Kashyap Desai
    Reviewed-by: Martin K. Petersen
    Reviewed-by: Bart Van Assche
    Signed-off-by: Christoph Hellwig

    Kashyap.Desai@avagotech.com
     
  • Please try the fix below, looks like the commit broke TCQ for all drivers
    using block-level tagging.

    Signed-off-by: Christoph Hellwig

    Christoph Hellwig
     

16 Aug, 2014

1 commit

  • Pull more SCSI changes from James Bottomley:
    "This is a small set of updates which missed the first pull. It's more
    msix updates, some iscsi and qla4xxx fixes, we also have some string
    null termination fixes a return value fix and a couple of pm8001
    firmware fixes.

    Just a note, we do have a couple of bug fixes coming under separate
    cover, but they don't have to be part of the merge window"

    * tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi:
    iscsi class: Fix freeing of skb in get host error path
    scsi: fix u14-34f printk format warnings
    pm8001: fix pm8001_store_update_fw
    pm8001: Fix erratic calculation in update_flash
    pm8001: Update MAINTAINERS list
    libiscsi: return new error code when nop times out
    iscsi class: fix get_host_stats return code when not supported
    iscsi class: fix get_host_stats error handling
    qla4xxx: fix get_host_stats error propagation
    qla4xxx: check the return value of dma_alloc_coherent()
    scsi: qla4xxx: ql4_mbx.c: Cleaning up missing null-terminate in conjunction with strncpy
    scsi: qla4xxx: ql4_os.c: Cleaning up missing null-terminate in conjunction with strncpy
    qla4xxx: Use pci_enable_msix_exact() instead of pci_enable_msix()
    pm8001: Use pci_enable_msix_exact() instead of pci_enable_msix()

    Linus Torvalds
     

14 Aug, 2014

1 commit

  • Pull block driver changes from Jens Axboe:
    "Nothing out of the ordinary here, this pull request contains:

    - A big round of fixes for bcache from Kent Overstreet, Slava Pestov,
    and Surbhi Palande. No new features, just a lot of fixes.

    - The usual round of drbd updates from Andreas Gruenbacher, Lars
    Ellenberg, and Philipp Reisner.

    - virtio_blk was converted to blk-mq back in 3.13, but now Ming Lei
    has taken it one step further and added support for actually using
    more than one queue.

    - Addition of an explicit SG_FLAG_Q_AT_HEAD for block/bsg, to
    compliment the the default behavior of adding to the tail of the
    queue. From Douglas Gilbert"

    * 'for-3.17/drivers' of git://git.kernel.dk/linux-block: (86 commits)
    bcache: Drop unneeded blk_sync_queue() calls
    bcache: add mutex lock for bch_is_open
    bcache: Correct printing of btree_gc_max_duration_ms
    bcache: try to set b->parent properly
    bcache: fix memory corruption in init error path
    bcache: fix crash with incomplete cache set
    bcache: Fix more early shutdown bugs
    bcache: fix use-after-free in btree_gc_coalesce()
    bcache: Fix an infinite loop in journal replay
    bcache: fix crash in bcache_btree_node_alloc_fail tracepoint
    bcache: bcache_write tracepoint was crashing
    bcache: fix typo in bch_bkey_equal_header
    bcache: Allocate bounce buffers with GFP_NOWAIT
    bcache: Make sure to pass GFP_WAIT to mempool_alloc()
    bcache: fix uninterruptible sleep in writeback thread
    bcache: wait for buckets when allocating new btree root
    bcache: fix crash on shutdown in passthrough mode
    bcache: fix lockdep warnings on shutdown
    bcache allocator: send discards with correct size
    bcache: Fix to remove the rcu_sched stalls.
    ...

    Linus Torvalds
     

09 Aug, 2014

1 commit

  • Rather than have architectures #define ARCH_HAS_SG_CHAIN in an
    architecture specific scatterlist.h, make it a proper Kconfig option and
    use that instead. At same time, remove the header files are are now
    mostly useless and just include asm-generic/scatterlist.h.

    [sfr@canb.auug.org.au: powerpc files now need asm/dma.h]
    Signed-off-by: Laura Abbott
    Acked-by: Thomas Gleixner [x86]
    Acked-by: Benjamin Herrenschmidt [powerpc]
    Acked-by: Heiko Carstens
    Cc: Russell King
    Cc: Tony Luck
    Cc: Fenghua Yu
    Cc: Paul Mackerras
    Cc: Ingo Molnar
    Cc: "H. Peter Anvin"
    Cc: "James E.J. Bottomley"
    Cc: Martin Schwidefsky
    Signed-off-by: Stephen Rothwell
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Laura Abbott
     

07 Aug, 2014

1 commit


01 Aug, 2014

1 commit

  • When a iscsi nop as ping timedout we were failing with the
    common connection error code, ISCSI_ERR_CONN_FAILED. This
    patch adds a new error code for this problem so can properly
    track/distinguish in userspace.

    Signed-off-by: Mike Christie
    Acked-by: Vikas Chaudhary
    Reviewed-by: Hannes Reinecke
    Signed-off-by: Christoph Hellwig

    Mike Christie
     

30 Jul, 2014

2 commits


26 Jul, 2014

6 commits

  • These speeds are to support the next generation of FCoE port speeds.

    Signed-off-by: Dick Kennedy
    Reviewed-by: Ewan D. Milne
    Signed-off-by: Christoph Hellwig

    Dick Kennedy
     
  • Despite supporting modern SCSI features some storage devices continue to
    claim conformance to an older version of the SPC spec. This is done for
    compatibility with legacy operating systems.

    Linux by default will not attempt to read VPD pages on devices that
    claim SPC-2 or older. Introduce a blacklist flag that can be used to
    trigger VPD page inquiries on devices that are known to support them.

    Reported-by: KY Srinivasan
    Tested-by: KY Srinivasan
    Reviewed-by: KY Srinivasan
    Signed-off-by: Martin K. Petersen
    CC:
    Signed-off-by: Christoph Hellwig

    Martin K. Petersen
     
  • We currently set the field in common code based on the device type,
    but then only use it in the cdrom driver which also overrides the
    value previously set in the generic code.

    Just leave this entirely to the CDROM driver to make everyones life
    simpler.

    Signed-off-by: Christoph Hellwig
    Reviewed-by: Hannes Reinecke
    Reviewed-by: Martin K. Petersen

    Christoph Hellwig
     
  • Make sure we have a symbolic name for the ZBC type available,
    so that e.g. patch for a SATA to translate ZAC commands can
    make use of it.

    Signed-off-by: Christoph Hellwig
    Reviewed-by: Hannes Reinecke
    Reviewed-by: Martin K. Petersen

    Christoph Hellwig
     
  • This patch adds support for an alternate I/O path in the scsi midlayer
    which uses the blk-mq infrastructure instead of the legacy request code.

    Use of blk-mq is fully transparent to drivers, although for now a host
    template field is provided to opt out of blk-mq usage in case any unforseen
    incompatibilities arise.

    In general replacing the legacy request code with blk-mq is a simple and
    mostly mechanical transformation. The biggest exception is the new code
    that deals with the fact the I/O submissions in blk-mq must happen from
    process context, which slightly complicates the I/O completion handler.
    The second biggest differences is that blk-mq is build around the concept
    of preallocated requests that also include driver specific data, which
    in SCSI context means the scsi_cmnd structure. This completely avoids
    dynamic memory allocations for the fast path through I/O submission.

    Due the preallocated requests the MQ code path exclusively uses the
    host-wide shared tag allocator instead of a per-LUN one. This only
    affects drivers actually using the block layer provided tag allocator
    instead of their own. Unlike the old path blk-mq always provides a tag,
    although drivers don't have to use it.

    For now the blk-mq path is disable by defauly and must be enabled using
    the "use_blk_mq" module parameter. Once the remaining work in the block
    layer to make blk-mq more suitable for slow devices is complete I hope
    to make it the default and eventually even remove the old code path.

    Based on the earlier scsi-mq prototype by Nicholas Bellinger.

    Thanks to Bart Van Assche and Robert Elliot for testing, benchmarking and
    various sugestions and code contributions.

    Signed-off-by: Christoph Hellwig
    Reviewed-by: Martin K. Petersen
    Reviewed-by: Hannes Reinecke
    Reviewed-by: Webb Scales
    Acked-by: Jens Axboe
    Tested-by: Bart Van Assche
    Tested-by: Robert Elliott

    Christoph Hellwig
     
  • Seems like these counters are missing any sort of synchronization for
    updates, as a over 10 year old comment from me noted. Fix this by
    using atomic counters, and while we're at it also make sure they are
    in the same cacheline as the _busy counters and not needlessly stored
    to in every I/O completion.

    With the new model the _busy counters can temporarily go negative,
    so all the readers are updated to check for > 0 values. Longer
    term every successful I/O completion will reset the counters to zero,
    so the temporarily negative values will not cause any harm.

    Signed-off-by: Christoph Hellwig
    Reviewed-by: Martin K. Petersen
    Reviewed-by: Webb Scales
    Acked-by: Jens Axboe
    Tested-by: Bart Van Assche
    Tested-by: Robert Elliott

    Christoph Hellwig
     

25 Jul, 2014

3 commits

  • Avoid taking the queue_lock to check the per-device queue limit. Instead
    we do an atomic_inc_return early on to grab our slot in the queue,
    and if necessary decrement it after finishing all checks.

    Unlike the host and target busy counters this doesn't allow us to avoid the
    queue_lock in the request_fn due to the way the interface works, but it'll
    allow us to prepare for using the blk-mq code, which doesn't use the
    queue_lock at all, and it at least avoids a queue_lock round trip in
    scsi_device_unbusy, which is still important given how busy the queue_lock
    is.

    Signed-off-by: Christoph Hellwig
    Reviewed-by: Hannes Reinecke
    Reviewed-by: Webb Scales
    Acked-by: Jens Axboe
    Tested-by: Bart Van Assche
    Tested-by: Robert Elliott

    Christoph Hellwig
     
  • Avoid taking the host-wide host_lock to check the per-host queue limit.
    Instead we do an atomic_inc_return early on to grab our slot in the queue,
    and if necessary decrement it after finishing all checks.

    Signed-off-by: Christoph Hellwig
    Reviewed-by: Martin K. Petersen
    Reviewed-by: Hannes Reinecke
    Reviewed-by: Webb Scales
    Acked-by: Jens Axboe
    Tested-by: Bart Van Assche
    Tested-by: Robert Elliott

    Christoph Hellwig
     
  • Avoid taking the host-wide host_lock to check the per-target queue limit.
    Instead we do an atomic_inc_return early on to grab our slot in the queue,
    and if necessary decrement it after finishing all checks.

    Signed-off-by: Christoph Hellwig
    Reviewed-by: Martin K. Petersen
    Reviewed-by: Hannes Reinecke
    Reviewed-by: Webb Scales
    Acked-by: Jens Axboe
    Tested-by: Bart Van Assche
    Tested-by: Robert Elliott

    Christoph Hellwig
     

18 Jul, 2014

11 commits

  • Signed-off-by: Christoph Hellwig
    Reviewed-by: Martin K. Petersen
    Reviewed-by: Hannes Reinecke

    Christoph Hellwig
     
  • We should call the device handler prep_fn for all TYPE_FS requests,
    not just simple read/write calls that are handled by the disk driver.

    Restructure the common I/O code to call the prep_fn handler and zero
    out the CDB, and just leave the call to scsi_init_io to the ULDs.

    Signed-off-by: Christoph Hellwig
    Reviewed-by: Martin K. Petersen
    Reviewed-by: Hannes Reinecke

    Christoph Hellwig
     
  • Signed-off-by: Christoph Hellwig
    Reviewed-by: Paolo Bonzini
    Reviewed-by: Hannes Reinecke

    Christoph Hellwig
     
  • 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
     
  • Remove the libsrp module which was only used by the now removed ibmvstgt
    driver.

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

    Christoph Hellwig
     
  • Now that we're using 64-bit LUNs internally we need to increase
    the size of max_luns to 64 bits, too.

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

    Hannes Reinecke
     
  • 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
     
  • Sequential scan for more than 256 LUNs is very fragile as
    LUNs might not be numbered sequentially after that point.

    SAM revisions later than SCSI-3 impose a structure on
    LUNs larger than 256, making LUN numbers between 256
    and 16384 illegal.
    SCSI-3, however allows for plain 64-bit numbers with
    no internal structure.

    So restrict sequential LUN scan to 256 LUNs and add a
    new blacklist flag 'BLIST_SCSI3LUN' to scan up to
    max_lun devices.

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

    Hannes Reinecke
     
  • When the SG_IO ioctl was copied into the block layer and
    later into the bsg driver, subtle differences emerged.

    One difference is the way injected commands are queued through
    the block layer (i.e. this is not SCSI device queueing nor SATA
    NCQ). Summarizing:
    - SG_IO in the block layer: blk_exec*(at_head=false)
    - sg SG_IO: at_head=true
    - bsg SG_IO: at_head=true

    Some time ago Boaz Harrosh introduced a sg v4 flag called
    BSG_FLAG_Q_AT_TAIL to override the bsg driver default.
    This patch does the equivalent for the sg driver.

    ChangeLog:
    Introduce SG_FLAG_Q_AT_TAIL flag to cause commands
    to be injected into the block layer with
    at_head=false.

    Signed-off-by: Douglas Gilbert
    Reviewed-by: Mike Christie
    Reviewed-by: Ewan D. Milne
    Signed-off-by: Christoph Hellwig

    Douglas Gilbert
     
  • - remove the 16 byte CDB (SCSI command) length limit from the sg driver
    by handling longer CDBs the same way as the bsg driver. Remove comment
    from sg.h public interface about the cmd_len field being limited to 16
    bytes.
    - remove some dead code caused by this change
    - cleanup comment block at the top of sg.h, fix urls

    Signed-off-by: Douglas Gilbert
    Reviewed-by: Mike Christie
    Reviewed-by: Hannes Reinecke
    Signed-off-by: Christoph Hellwig

    Douglas Gilbert
     
  • max_sectors in struct Scsi_Host specifies maximum number of sectors
    allowed in a single SCSI command. The data type of max_sectors is
    unsigned short, so the maximum transfer length per SCSI command is
    limited to less than 256MB in 4096-bytes sector size. (0xffff * 4096)

    This commit increases the SCSI mid level's limitation for max_sectors
    upto the block layer's limitation for max_hw_sectors by extending the
    data type of max_sectors in struct Scsi_Host and scsi_host_template,
    so that SCSI lower level drivers can specify more than 0xffff.

    Signed-off-by: Akinobu Mita
    Reviewed-by: Martin K. Petersen
    Signed-off-by: Christoph Hellwig

    Akinobu Mita
     

07 Jul, 2014

1 commit

  • Pull SCSI fixes from James Bottomley:
    "This is a set of 13 fixes, a MAINTAINERS update and a sparse update.
    The fixes are mostly correct value initialisations, avoiding NULL
    derefs and some uninitialised pointer avoidance.

    All the patches have been incubated in -next for a few days. The
    final patch (use the scsi data buffer length to extract transfer size)
    has been rebased to add a cc to stable, but only the commit message
    has changed"

    * tag 'scsi-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi:
    [SCSI] use the scsi data buffer length to extract transfer size
    virtio-scsi: fix various bad behavior on aborted requests
    virtio-scsi: avoid cancelling uninitialized work items
    ibmvscsi: Add memory barriers for send / receive
    ibmvscsi: Abort init sequence during error recovery
    qla2xxx: Fix sparse warning in qla_target.c.
    bnx2fc: Improve stats update mechanism
    bnx2fc: do not scan uninitialized lists in case of error.
    fc: ensure scan_work isn't active when freeing fc_rport
    pm8001: Fix potential null pointer dereference and memory leak.
    MAINTAINERS: Update LSILOGIC MPT FUSION DRIVERS (FC/SAS/SPI) maintainers Email IDs
    be2iscsi: remove potential junk pointer free
    be2iscsi: add an missing goto in error path
    scsi_error: set DID_TIME_OUT correctly
    scsi_error: fix invalid setting of host byte

    Linus Torvalds
     

04 Jul, 2014

1 commit

  • Commit 8846bab180fa introduced a helper that can be used to query the
    wire transfer size for a SCSI command taking protection information into
    account.

    However, some commands do not have a 1:1 mapping between the block range
    they work on and the payload size (discard, write same). After the
    scatterlist has been set up these requests use __data_len to store the
    number of bytes to report completion on. This means that callers of
    scsi_transfer_length() would get the wrong byte count for these types of
    requests.

    To overcome this we make scsi_transfer_length() use the scatterlist
    length in the scsi_data_buffer as basis for the wire transfer
    calculation instead of __data_len.

    Reported-by: Christoph Hellwig
    Debugged-by: Mike Christie
    Signed-off-by: Martin K. Petersen
    Signed-off-by: Christoph Hellwig
    Reviewed-by: Sagi Grimberg
    Fixes: d77e65350f2d82dfa0557707d505711f5a43c8fd
    Cc: stable@vger.kernel.org
    Signed-off-by: James Bottomley

    Martin K. Petersen
     

02 Jul, 2014

1 commit

  • After the SG_IO ioctl was copied into the block layer and
    later into the bsg driver, subtle differences emerged.

    One difference is the way injected commands are queued through
    the block layer (i.e. this is not SCSI device queueing nor SATA
    NCQ). Summarizing:
    - SG_IO on block layer device: blk_exec*(at_head=false)
    - sg device SG_IO: at_head=true
    - bsg device SG_IO: at_head=true

    Some time ago Boaz Harrosh introduced a sg v4 flag called
    BSG_FLAG_Q_AT_TAIL to override the bsg driver default. A
    recent patch titled: "sg: add SG_FLAG_Q_AT_TAIL flag"
    allowed the sg driver default to be overridden. This patch
    allows a SG_IO ioctl sent to a block layer device to have
    its default overridden.

    ChangeLog:
    - introduce SG_FLAG_Q_AT_HEAD flag in sg.h to cause
    commands that are injected via a block layer
    device SG_IO ioctl to set at_head=true
    - make comments clearer about queueing in sg.h since the
    header is used both by the sg device and block layer
    device implementations of the SG_IO ioctl.
    - introduce BSG_FLAG_Q_AT_HEAD in bsg.h for compatibility
    (it does nothing) and update comments.

    Signed-off-by: Douglas Gilbert
    Reviewed-by: Christoph Hellwig
    Reviewed-by: Mike Christie
    Signed-off-by: Jens Axboe

    Douglas Gilbert
     

01 Jul, 2014

1 commit

  • Some buggy JMicron USB-ATA bridges don't know how to translate the FUA
    bit in READs or WRITEs. This patch adds an entry in unusual_devs.h
    and a blacklist flag to tell the sd driver not to use FUA.

    Signed-off-by: Alan Stern
    Reported-by: Michael Büsch
    Tested-by: Michael Büsch
    Acked-by: James Bottomley
    CC: Matthew Dharm
    CC:
    Signed-off-by: Greg Kroah-Hartman

    Alan Stern