kernel-fxtec-pro1x/drivers/scsi/pm8001
Dan Williams b1124cd3ec [SCSI] libsas: introduce sas_drain_work()
When an lldd invokes ->notify_port_event() it can trigger a chain of libsas
events to:

  1/ form the port and find the direct attached device

  2/ if the attached device is an expander perform domain discovery

A call to flush_workqueue() will only flush the initial port formation work.
Currently libsas users need to call scsi_flush_work() up to the max depth of
chain (which will grow from 2 to 3 when ata discovery is moved to its own
discovery event).  Instead of open coding multiple calls switch to use
drain_workqueue() to flush sas work.

drain_workqueue() does not handle new work submitted during the drain so
libsas needs a bit of infrastructure to hold off unchained work submissions
while a drain is in flight.  A lldd ->notify() event is considered 'unchained'
while a sas_discover_event() is 'chained'.  As Tejun notes:

  "For now, I think it would be best to add private wrapper in libsas to
   support deferring unchained work items while draining."

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
2012-02-19 13:48:51 -06:00
..
Makefile
pm8001_chips.h
pm8001_ctl.c include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h 2010-03-30 22:02:32 +09:00
pm8001_ctl.h [SCSI] pm8001: enable read HBA SAS address from VPD 2009-12-10 10:09:23 -06:00
pm8001_defs.h
pm8001_hwi.c [SCSI] pm8001: deficient responses to IO_XFER_ERROR_BREAK and IO_XFER_OPEN_RETRY_TIMEOUT 2012-02-19 08:08:52 -06:00
pm8001_hwi.h Fix common misspellings 2011-03-31 11:26:23 -03:00
pm8001_init.c [SCSI] libsas: kill sas_slave_destroy 2012-02-19 13:36:36 -06:00
pm8001_sas.c [SCSI] libsas: introduce sas_drain_work() 2012-02-19 13:48:51 -06:00
pm8001_sas.h [SCSI] pm8001: deficient responses to IO_XFER_ERROR_BREAK and IO_XFER_OPEN_RETRY_TIMEOUT 2012-02-19 08:08:52 -06:00