1. 18 2月, 2012 1 次提交
    • K
      [SCSI] ipr: fix eeh recovery for 64-bit adapters · a92fa25c
      Kleber Sacilotto de Souza 提交于
      In some scenarios, an EEH error can take a long time to be detected, since the
      driver issues an MMIO read only after a device reset command times out and we
      try to reset the adapter. This patch adds some code in ipr_cancel_op() to read
      a hardware register so we detect the error earlier in case the op is being
      aborted because of a timeout caused by a frozen adapter slot.
      
      Another problem in such scenarios is that in __ipr_eh_host_reset() we change the
      dump state flag from WAIT_FOR_DUMP to GET_DUMP, and the flag is later changed
      from GET_DUMP to READ_DUMP in ipr_reset_restore_cfg_space(). However, if when
      __ipr_eh_host_reset() is called by the SCSI error handling the function
      ipr_reset_restore_cfg_space() has already been called by the PCI EEH code, we
      end up with the flag in an inconsistent state. This patch also prevents this
      problem.
      Signed-off-by: NKleber Sacilotto de Souza <klebers@linux.vnet.ibm.com>
      Acked-by: NBrian King <brking@linux.vnet.ibm.com>
      Signed-off-by: NJames Bottomley <JBottomley@Parallels.com>
      a92fa25c
  2. 07 1月, 2012 1 次提交
    • J
      PCI: Rework config space blocking services · fb51ccbf
      Jan Kiszka 提交于
      pci_block_user_cfg_access was designed for the use case that a single
      context, the IPR driver, temporarily delays user space accesses to the
      config space via sysfs. This assumption became invalid by the time
      pci_dev_reset was added as locking instance. Today, if you run two loops
      in parallel that reset the same device via sysfs, you end up with a
      kernel BUG as pci_block_user_cfg_access detect the broken assumption.
      
      This reworks the pci_block_user_cfg_access to a sleeping service
      pci_cfg_access_lock and an atomic-compatible variant called
      pci_cfg_access_trylock. The former not only blocks user space access as
      before but also waits if access was already locked. The latter service
      just returns false in this case, allowing the caller to resolve the
      conflict instead of raising a BUG.
      
      Adaptions of the ipr driver were originally written by Brian King.
      Acked-by: NBrian King <brking@linux.vnet.ibm.com>
      Acked-by: NMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: NJan Kiszka <jan.kiszka@siemens.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      fb51ccbf
  3. 31 10月, 2011 1 次提交
  4. 20 10月, 2011 1 次提交
    • B
      [SCSI] ipr: Fix BUG on adapter dump timeout · 4c647e90
      Brian King 提交于
      If an adapter dump times out, the ipr driver will abort the
      dump and proceed to reset and recover the adapter. When an
      adapter dump completes, the work thread which is reading the
      adapter dump will initiate an adapter reset to recover the
      adapter. However, when the adapter dump gets aborted, the
      work thread should not initiate an adapter reset, since an
      adapter reset is already in progress. This fixes a case of
      calling pci_block_user_cfg_access overlapped, which results
      in a BUG.
      Signed-off-by: NBrian King <brking@linux.vnet.ibm.com>
      Signed-off-by: NJames Bottomley <JBottomley@Parallels.com>
      4c647e90
  5. 16 10月, 2011 1 次提交
  6. 22 9月, 2011 1 次提交
    • B
      [SCSI] ipr: Stop reading adapter dump prematurely · 41e9a696
      Brian King 提交于
      When the ipr driver decides to dump the adapter, it changes the
      sdt_state to GET_DUMP, then prepares the adapter so that the dump
      can be read. However, if the ipr worker thread wakes up for some
      reason before the driver has put the adapter in a state where it
      can succesfully dump the adapter, the driver will start dumping
      the adapter too early, which can potentially trigger a BUG check
      in the pci config blocking API. Fix this by adding a new
      sdt_state to differentiate between the ipr driver wanting to dump
      the adapter in the near future and wanting to dump the adapter now.
      Signed-off-by: NBrian King <brking@linux.vnet.ibm.com>
      Signed-off-by: NJames Bottomley <JBottomley@Parallels.com>
      41e9a696
  7. 27 8月, 2011 1 次提交
  8. 27 7月, 2011 1 次提交
  9. 25 5月, 2011 1 次提交
  10. 17 5月, 2011 1 次提交
  11. 02 5月, 2011 1 次提交
  12. 01 5月, 2011 3 次提交
  13. 02 3月, 2011 4 次提交
  14. 19 2月, 2011 1 次提交
  15. 13 2月, 2011 1 次提交
    • T
      [SCSI] remove flush_scheduled_work() usages · a684b8da
      Tejun Heo 提交于
      Simple conversions to drop flush_scheduled_work() usages in
      drivers/scsi.  More involved ones will be done in separate patches.
      
      * NCR5380, megaraid_sas: cancel_delayed_work() +
        flush_scheduled_work() -> cancel_delayed_work_sync().
      
      * mpt2sas_scsih: drop unnecessary flush_scheduled_work().
      
      * arcmsr_hba, ipr, pmcraid: flush the used work explicitly instead of
        using flush_scheduled_work().
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Signed-off-by: NJames Bottomley <James.Bottomley@suse.de>
      a684b8da
  16. 06 1月, 2011 1 次提交
  17. 24 12月, 2010 1 次提交
  18. 22 12月, 2010 2 次提交
  19. 17 11月, 2010 1 次提交
    • J
      SCSI host lock push-down · f281233d
      Jeff Garzik 提交于
      Move the mid-layer's ->queuecommand() invocation from being locked
      with the host lock to being unlocked to facilitate speeding up the
      critical path for drivers who don't need this lock taken anyway.
      
      The patch below presents a simple SCSI host lock push-down as an
      equivalent transformation.  No locking or other behavior should change
      with this patch.  All existing bugs and locking orders are preserved.
      
      Additionally, add one parameter to queuecommand,
      	struct Scsi_Host *
      and remove one parameter from queuecommand,
      	void (*done)(struct scsi_cmnd *)
      
      Scsi_Host* is a convenient pointer that most host drivers need anyway,
      and 'done' is redundant to struct scsi_cmnd->scsi_done.
      
      Minimal code disturbance was attempted with this change.  Most drivers
      needed only two one-line modifications for their host lock push-down.
      Signed-off-by: NJeff Garzik <jgarzik@redhat.com>
      Acked-by: NJames Bottomley <James.Bottomley@suse.de>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      f281233d
  20. 26 10月, 2010 1 次提交
  21. 08 10月, 2010 1 次提交
  22. 10 9月, 2010 1 次提交
  23. 06 9月, 2010 1 次提交
  24. 28 7月, 2010 6 次提交
  25. 22 7月, 2010 1 次提交
  26. 25 5月, 2010 4 次提交