1. 03 9月, 2006 5 次提交
    • M
      [SCSI] iscsi_tcp: fix padding, data digests, and IO at weird offsets · 62f38300
      Mike Christie 提交于
      iscsi_tcp calculates padding by using the expected transfer length. This
      has the problem where if we have immediate data = no and initial R2T =
      yes, and the transfer length ended up needing padding then we send:
      
      1. header
      2. padding which should have gone after data
      3. data
      
      Besides this bug, we also assume the target will always ask for nice
      transfer lengths and the first burst length will always be a nice value.
      As far as I can tell form the RFC this is not a requirement. It would be
      silly to do this, but if someone did it we will end doing bad things.
      
      Finally the last bug in that bit of code is in our handling of the
      recalculation of data digests when we do not send a whole iscsi_buf in
      one try. The bug here is that we call crypto_digest_final on a
      iscsi_sendpage error, then when we send the rest of the iscsi_buf, we
      doiscsi_data_digest_init and this causes the previous data digest to be
      lost.
      
      And to make matters worse, some of these bugs are replicated over and
      over and over again for immediate data, solicited data and unsolicited
      data. So the attached patch made over the iscsi git tree (see
      kernel.org/git for details) which I updated today to include the patches
      I said I merged, consolidates the sending of data, padding and digests
      and calculation of data digests and fixes the above bugs.
      Signed-off-by: NMike Christie <michaelc@cs.wisc.edu>
      Signed-off-by: NJames Bottomley <James.Bottomley@SteelEye.com>
      62f38300
    • M
      [SCSI] attempt to complete r2t with data len greater than max burst · 98a9416a
      Mike Christie 提交于
      A couple targets like string bean and MDS, send r2ts with
      a data len greater than the max burst we agreed to. We
      were being strict in our enforcing of the iscsi rfc in that
      code path, but there is no driver limitation that prevents
      us from fullfilling the request. To allow those targets
      to work we will ignore the max_burst length and send as
      much data as the target asks for assuming it has consciously
      decided to override its max burst length.
      Signed-off-by: NMike Christie <michaelc@cs.wisc.edu>
      Signed-off-by: NJames Bottomley <James.Bottomley@SteelEye.com>
      98a9416a
    • M
      [SCSI] add refcouting around ctask usage in main IO patch · 60ecebf5
      Mike Christie 提交于
      It is possible that a ctask could be completing and getting
      cleaned up at the same time, we are finishing up the last
      data transfer. This could then result in the data transfer
      code using stale or invalid values. This patch adds a refcount
      to the ctask. When the count goes to zero then we know the
      transmit thread and recv thread or softirq are not touching
      it and we can safely release it.
      
      The eh should not need to grab a reference because it only cleans
      up a task if it has both the xmit mutex and recv lock (or recv
      side suspended).
      Signed-off-by: NMike Christie <michaelc@cs.wisc.edu>
      Signed-off-by: NJames Bottomley <James.Bottomley@SteelEye.com>
      60ecebf5
    • M
      [SCSI] libiscsi, iscsi_tcp, iscsi_iser: check that burst lengths are valid. · ffd0436e
      Mike Christie 提交于
      iSCSI RFC states that the first burst length must be smaller than the
      max burst length. We currently assume targets will be good, but that may
      not be the case, so this patch adds a check.
      
      This patch also moves the unsol data out offset to the lib so the LLDs
      do not have to track it.
      Signed-off-by: NMike Christie <michaelc@cs.wisc.edu>
      Signed-off-by: NJames Bottomley <James.Bottomley@SteelEye.com>
      ffd0436e
    • A
      [SCSI] SCSI: sanitize INQUIRY strings · e5b3cd42
      Alan Stern 提交于
      Sanitize the Vendor, Product, and Revision strings contained in an
      INQUIRY result by setting all non-graphic or non-ASCII characters to ' '.
      Since the standard disallows such characters, this will affect
      only non-compliant devices.
      
      To help maintain backward compatibility, NUL characters are treated
      specially.  They are taken as string terminators; they and all the
      following characters are set to ' '.  If some valid characters get
      erased as a result... well, we weren't seeing them before so we haven't
      lost anything.
      
      The primary purpose of this change is to allow blacklist entries to
      match devices with illegal Vendor or Product strings.
      
      In addition, the patch updates a couple of function prototypes, giving
      inq_result its correct type (unsigned char *).
      Signed-off-by: NAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: NJames Bottomley <James.Bottomley@SteelEye.com>
      e5b3cd42
  2. 02 9月, 2006 1 次提交
  3. 31 8月, 2006 3 次提交
  4. 30 8月, 2006 2 次提交
  5. 29 8月, 2006 1 次提交
    • J
      [SCSI] aic94xx: new driver · 2908d778
      James Bottomley 提交于
      This is the end point of the separate aic94xx driver based on the
      original driver and transport class from Luben Tuikov
      <ltuikov@yahoo.com>
      
      The log of the separate development is:
      
      Alexis Bruemmer:
        o aic94xx: fix hotplug/unplug for expanderless systems
        o aic94xx: disable split completion timer/setting by default
        o aic94xx: wide port off expander support
        o aic94xx: remove various inline functions
        o aic94xx: use bitops
        o aic94xx: remove queue comment
        o aic94xx: remove sas_common.c
        o aic94xx: sas remove depot's
        o aic94xx: use available list_for_each_entry_safe_reverse()
        o aic94xx: sas header file merge
      
      James Bottomley:
        o aic94xx: fix TF_TMF_NO_CTX processing
        o aic94xx: convert to request_firmware interface
        o aic94xx: fix hotplug/unplug
        o aic94xx: add link error counts to the expander phys
        o aic94xx: add transport class phy reset capability
        o aic94xx: remove local_attached flag
        o Remove README
        o Fixup Makefile variable for libsas rename
        o Rename sas->libsas
        o aic94xx: correct return code for sas_discover_event
        o aic94xx: use parent backlink port
        o aic94xx: remove channel abstraction
        o aic94xx: fix routing algorithms
        o aic94xx: add backlink port
        o aic94xx: fix cascaded expander properties
        o aic94xx: fix sleep under lock
        o aic94xx: fix panic on module removal in complex topology
        o aic94xx: make use of the new sas_port
        o rename sas_port to asd_sas_port
        o Fix for eh_strategy_handler move
        o aic94xx: move entirely over to correct transport class formulation
        o remove last vestages of sas_rphy_alloc()
        o update for eh_timed_out move
        o Preliminary expander support for aic94xx
        o sas: remove event thread
        o minor warning cleanups
        o remove last vestiges of id mapping arrays
        o Further updates
        o Convert aic94xx over entirely to the transport class end device and
        o update aic94xx/sas to use the new sas transport class end device
        o [PATCH] aic94xx: attaching to the sas transport class
        o Add missing completion removal from prior patch
        o [PATCH] aic94xx: attaching to the sas transport class
        o Build fixes from akpm
      
      Jeff Garzik:
        o [scsi aic94xx] Remove ->owner from PCI info table
      
      Luben Tuikov:
        o initial aic94xx driver
      
      Mike Anderson:
        o aic94xx: fix panic on module insertion
        o aic94xx: stub out SATA_DEV case
        o aic94xx: compile warning cleanups
        o aic94xx: sas_alloc_task
        o aic94xx: ref count update
        o aic94xx nexus loss time value
        o [PATCH] aic94xx: driver assertion in non-x86 BIOS env
      
      Randy Dunlap:
        o libsas: externs not needed
      
      Robert Tarte:
        o aic94xx: sequence patch - fixes SATA support
      Signed-off-by: NJames Bottomley <James.Bottomley@SteelEye.com>
      2908d778
  6. 28 8月, 2006 28 次提交