1. 27 May, 2011 2 commits
    • Dan Williams's avatar
      [SCSI] libsas: check dev->gone before submitting sata i/o · 3673f4bf
      Dan Williams authored
      Head off doomed-to-fail i/o in sas_queuecommand before sending it down
      the ata path.
      
      Before:
      sd 7:0:0:0: [sdd] Synchronizing SCSI cache
      ata8: no sense translation for status: 0x00
      ata8: translated ATA stat/err 0x00/00 to SCSI SK/ASC/ASCQ 0xb/00/00
      ata8.00: device reported invalid CHS sector 0
      ata8: status=0x00 { }
      ata8: no sense translation for status: 0x00
      ata8: translated ATA stat/err 0x00/00 to SCSI SK/ASC/ASCQ 0xb/00/00
      ata8.00: device reported invalid CHS sector 0
      ata8: status=0x00 { }
      ata8: no sense translation for status: 0x00
      ata8: translated ATA stat/err 0x00/00 to SCSI SK/ASC/ASCQ 0xb/00/00
      ata8.00: device reported invalid CHS sector 0
      ata8: status=0x00 { }
      sd 7:0:0:0: [sdd]  Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
      sd 7:0:0:0: [sdd]  Sense Key : Aborted Command [current] [descriptor]
      sd 7:0:0:0: [sdd]  Add. Sense: No additional sense information
      sd 7:0:0:0: [sdd] Stopping disk
      
      After:
      sd 9:0:0:0: [sdd] Synchronizing SCSI cache
      sd 9:0:0:0: [sdd]  Result: hostbyte=DID_BAD_TARGET driverbyte=DRIVER_OK
      sd 9:0:0:0: [sdd] Stopping disk
      sd 9:0:0:0: [sdd] START_STOP FAILED
      sd 9:0:0:0: [sdd]  Result: hostbyte=DID_BAD_TARGET driverbyte=DRIVER_OK
      
      This is a cosmetic change as sata i/o can still leak to a gone device,
      but this addresses the nominal hotplug case when releasing the target.
      Acked-by: default avatarJack Wang <jack_wang@usish.com>
      Signed-off-by: default avatarDan Williams <dan.j.williams@intel.com>
      Signed-off-by: default avatarJames Bottomley <jbottomley@parallels.com>
      3673f4bf
    • Dan Williams's avatar
      [SCSI] libsas: fix/amend device gone notification in sas_deform_port() · 90f1e10d
      Dan Williams authored
      Commit 56dd2c06 "libsas: Don't issue commands to devices that have been
      hot-removed" edited Darrick's original patch to remove setting 'gone' in
      the sas_deform_port() path because that prevented scsi sync cache
      commands from being issued when the driver was unloaded.  However, this
      allows true device gone notifications (as signaled port phy events) to
      trigger sync cache commands to devices that are known to be unreachable.
      
      Teach libsas which sas_deform_port() invocations are likely device gone
      events.
      Signed-off-by: default avatarDan Williams <dan.j.williams@intel.com>
      Signed-off-by: default avatarJames Bottomley <jbottomley@parallels.com>
      90f1e10d
  2. 26 May, 2011 1 commit
  3. 24 May, 2011 37 commits