1. 01 3月, 2012 7 次提交
    • D
      [SCSI] libsas: set attached device type and target protocols for local phys · 899fcf40
      Dan Williams 提交于
      Before:
      $ cat /sys/class/sas_phy/phy-6\:3/device_type
      none
      $ cat /sys/class/sas_phy/phy-6\:3/target_port_protocols
      none
      
      After:
      $ cat /sys/class/sas_phy/phy-6\:3/device_type
      end device
      $ cat /sys/class/sas_phy/phy-6\:3/target_port_protocols
      sata
      
      Also downgrade the phy_list_lock to _irq instead of _irqsave since
      libsas will never call sas_get_port_device with interrupts disbled.
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      Signed-off-by: NJames Bottomley <JBottomley@Parallels.com>
      899fcf40
    • D
      [SCSI] libsas: async ata scanning · 9508a66f
      Dan Williams 提交于
      libsas ata error handling is already async but this does not help the
      scan case.  Move initial link recovery out from under host->scan_mutex,
      and delay synchronization with eh until after all port probe/recovery
      work has been queued.
      
      Device ordering is maintained with scan order by still calling
      sas_rphy_add() in order of domain discovery.
      
      Since we now scan the domain list when invoking libata-eh we need to be
      careful to check for fully initialized ata ports.
      Acked-by: NJack Wang <jack_wang@usish.com>
      Acked-by: NJeff Garzik <jgarzik@redhat.com>
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      Signed-off-by: NJames Bottomley <JBottomley@Parallels.com>
      9508a66f
    • D
      [SCSI] libsas: let libata recover links that fail to transmit initial sig-fis · 354cf829
      Dan Williams 提交于
      libsas fails to discover all sata devices in the domain.  If a device fails
      negotiation and does not transmit a signature fis the link needs recovery.
      libata already understands how to manage slow to come up links, so treat these
      conditions as ata device attach events for the purposes of creating an
      ata_port.  This allows libata to manage retrying link bring up.
      
      Rediscovery is modified to be careful about checking changes in dev_type.  It
      looks like libsas leaks old devices if the sas address changes, but that's a
      fix for another patch.
      Acked-by: NJack Wang <jack_wang@usish.com>
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      Signed-off-by: NJames Bottomley <JBottomley@Parallels.com>
      354cf829
    • D
      [SCSI] libsas: fix sas_unregister_ports vs sas_drain_work · 5d7f6d10
      Dan Williams 提交于
      We need to hold drain_mutex across the unregistration as port down events
      queue device removal as chained events, so we need to make sure no other
      drainers are active.
      
      [ 1118.673968] WARNING: at kernel/workqueue.c:996 __queue_work+0x11a/0x326()
      [ 1118.681982] Hardware name: S2600CP
      [ 1118.686193] Modules linked in: isci(-) libsas scsi_transport_sas nls_utf8
      ipv6 uinput sg iTCO_wdt iTCO_vendor_support i2c_i801 i2c_core ioatdma dca
      sd_mod sr_mod cdrom ahci libahci libata [last unloaded: scsi_transport_sas]
      [ 1118.709893] Pid: 6831, comm: rmmod Not tainted 3.2.0-isci+ #1
      [ 1118.716727] Call Trace:
      [ 1118.719867]  [<ffffffff8103e9f5>] warn_slowpath_common+0x85/0x9d
      [ 1118.727000]  [<ffffffff8103ea27>] warn_slowpath_null+0x1a/0x1c
      [ 1118.733942]  [<ffffffff81056d44>] __queue_work+0x11a/0x326
      [ 1118.740481]  [<ffffffff81056f99>] queue_work_on+0x1b/0x22
      [ 1118.746925]  [<ffffffff81057106>] queue_work+0x37/0x3e
      [ 1118.753105]  [<ffffffffa0120e05>] ? sas_discover_event+0x55/0x82 [libsas]
      [ 1118.761094]  [<ffffffff813217c3>] scsi_queue_work+0x42/0x44
      [ 1118.767717]  [<ffffffffa0120e19>] sas_discover_event+0x69/0x82 [libsas]
      [ 1118.775509]  [<ffffffffa0120f5b>] sas_unregister_dev+0xc3/0xcc [libsas]
      [ 1118.783319]  [<ffffffffa0120fae>] sas_unregister_domain_devices+0x4a/0xc8 [libsas]
      [ 1118.792731]  [<ffffffffa0120071>] sas_deform_port+0x60/0x1a6 [libsas]
      [ 1118.800339]  [<ffffffffa01201ea>] sas_unregister_ports+0x33/0x44 [libsas]
      [ 1118.808342]  [<ffffffffa011f7e5>] sas_unregister_ha+0x41/0x6b [libsas]
      [ 1118.816055]  [<ffffffffa0134055>] isci_unregister+0x22/0x4d [isci]
      [ 1118.823384]  [<ffffffffa0143040>] isci_pci_remove+0x2e/0x60 [isci]
      Reported-by: NJacek Danecki <jacek.danecki@intel.com>
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      Signed-off-by: NJames Bottomley <JBottomley@Parallels.com>
      5d7f6d10
    • D
      [SCSI] libsas: route local link resets through ata-eh · ab526633
      Dan Williams 提交于
      Similar to the conversion of the transport-class reset we want bsg
      initiated resets to be managed by libata.
      Reported-by: NJacek Danecki <jacek.danecki@intel.com>
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      Signed-off-by: NJames Bottomley <JBottomley@Parallels.com>
      ab526633
    • D
      [SCSI] libsas: fix sas_find_local_phy(), take phy references · f41a0c44
      Dan Williams 提交于
      In the direct-attached case this routine returns the phy on which this
      device was first discovered.  Which is broken if we want to support
      wide-targets, as this phy reference can become stale even though the
      port is still active.
      
      In the expander-attached case this routine tries to lookup the phy by
      scanning the attached sas addresses of the parent expander, and BUG_ONs
      if it can't find it.  However since eh and the libsas workqueue run
      independently we can still be attempting device recovery via eh after
      libsas has recorded the device as detached.  This is even easier to hit
      now that eh is blocked while device domain rediscovery takes place, and
      that libata is fed more timed out commands increasing the chances that
      it will try to recover the ata device.
      
      Arrange for dev->phy to always point to a last known good phy, it may be
      stale after the port is torn down, but it will catch up for wide port
      reconfigurations, and never be NULL.
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      Signed-off-by: NJames Bottomley <JBottomley@Parallels.com>
      f41a0c44
    • D
      [SCSI] libsas: poll for ata device readiness after reset · 36a39947
      Dan Williams 提交于
      Use ata_wait_after_reset() to poll for link recovery after a reset.
      This combined with sas_ha->eh_mutex prevents expander rediscovery from
      probing phys in an intermediate state.  Local discovery does not have a
      mechanism to filter link status changes during this timeout, so it
      remains the responsibility of lldds to prevent premature port teardown.
      Although once all lldd's support ->lldd_ata_check_ready() that could be
      used as a gate to local port teardown.
      
      The signature fis is re-transmitted when the link comes back so we
      should be revalidating the ata device class, but that is left to a future
      patch.
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      Signed-off-by: NJames Bottomley <JBottomley@Parallels.com>
      36a39947
  2. 20 2月, 2012 9 次提交
  3. 27 5月, 2011 1 次提交
  4. 25 1月, 2011 1 次提交
  5. 09 10月, 2008 1 次提交
  6. 12 1月, 2008 2 次提交
  7. 19 7月, 2007 1 次提交
  8. 14 1月, 2007 1 次提交
  9. 22 11月, 2006 1 次提交
  10. 08 9月, 2006 2 次提交
  11. 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