linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/15] Add runtime PM support for libsas
@ 2021-11-17  2:44 chenxiang
  2021-11-17  2:44 ` [PATCH 01/15] libsas: Don't always drain event workqueue for HA resume chenxiang
                   ` (16 more replies)
  0 siblings, 17 replies; 43+ messages in thread
From: chenxiang @ 2021-11-17  2:44 UTC (permalink / raw)
  To: jejb, martin.petersen; +Cc: linux-scsi, linuxarm, john.garry, Xiang Chen

From: Xiang Chen <chenxiang66@hisilicon.com>

Right now hisi_sas driver has already supported runtime PM, and it works
well on base functions. But for some exception situations, there are some
issues related to libsas layer:
- Remove a directly attached disk when sas host is suspended, a hang will
occur in the resume process, patch 1~2 solve the issue;
- Insert a new disk (for expander) during suspended, and the disk is not
revalidated when resuming sas host, patch 4~7 solve the issue;
- SMP IOs from libsas may be sending when sas host is suspended, so resume
sas host when sending SMP IOs in patch 9;
- New phyup may occur during the process of resuming controller, then work
of DISCE_DISCOVER_DOMAIN of a new phy and work PORTE_BYTES_DMAED of suspended
phy are blocked by each other, so defer works of new phys during suspend
in patch 10~12;
- Work PORTE_BROADCAST_RCVD and PORTE_BYTES_DMAED are in the same 
workqueue, but it is possible that they are blocked by each other, 
so keep sas host active until finished some work in patch 14.

And patch 3 which is related to scsi/block PM is from Alan Stern 
(https://lore.kernel.org/linux-scsi/20210714161027.GC380727@rowland.harvard.edu/)

Alan Stern (1):
  scsi/block PM: Always set request queue runtime active in
    blk_post_runtime_resume()

John Garry (2):
  libsas: Don't always drain event workqueue for HA resume
  Revert "scsi: hisi_sas: Filter out new PHY up events during suspend"

Xiang Chen (12):
  scsi: libsas: Add spin_lock/unlock() to protect asd_sas_port->phy_list
  scsi: hisi_sas: Fix some issues related to asd_sas_port->phy_list
  scsi: mvsas: Add spin_lock/unlock() to protect asd_sas_port->phy_list
  scsi: libsas: Send event PORTE_BROADCAST_RCVD for valid ports
  scsi: hisi_sas: Add more prink for runtime suspend/resume
  scsi: libsas: Resume sas host before sending SMP IOs
  scsi: libsas: Add a flag SAS_HA_RESUMING of sas_ha
  scsi: libsas: Refactor out sas_queue_deferred_work()
  scsi: libsas: Defer works of new phys during suspend
  scsi: hisi_sas: Keep controller active between ISR of phyup and the
    event being processed
  scsi: libsas: Keep sas host active until finished some work
  scsi: hisi_sas: Use autosuspend for SAS controller

 block/blk-pm.c                         | 22 +++-----
 drivers/scsi/hisi_sas/hisi_sas.h       |  1 +
 drivers/scsi/hisi_sas/hisi_sas_main.c  | 39 +++++++++----
 drivers/scsi/hisi_sas/hisi_sas_v3_hw.c | 25 +++++++--
 drivers/scsi/libsas/sas_event.c        | 77 +++++++++++++++++++++-----
 drivers/scsi/libsas/sas_expander.c     |  3 +
 drivers/scsi/libsas/sas_init.c         | 49 +++++++++++++++-
 drivers/scsi/libsas/sas_internal.h     |  2 +
 drivers/scsi/mvsas/mv_sas.c            |  5 ++
 drivers/scsi/scsi_pm.c                 |  2 +-
 include/linux/blk-pm.h                 |  2 +-
 include/scsi/libsas.h                  |  2 +
 12 files changed, 181 insertions(+), 48 deletions(-)

-- 
2.33.0


^ permalink raw reply	[flat|nested] 43+ messages in thread

end of thread, other threads:[~2021-12-15  8:00 UTC | newest]

Thread overview: 43+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-17  2:44 [PATCH 00/15] Add runtime PM support for libsas chenxiang
2021-11-17  2:44 ` [PATCH 01/15] libsas: Don't always drain event workqueue for HA resume chenxiang
2021-11-17  4:14   ` Bart Van Assche
2021-11-17  5:06     ` Bart Van Assche
2021-11-17  2:44 ` [PATCH 02/15] Revert "scsi: hisi_sas: Filter out new PHY up events during suspend" chenxiang
2021-12-13 10:31   ` John Garry
2021-12-15  7:20     ` chenxiang (M)
2021-11-17  2:44 ` [PATCH 03/15] scsi/block PM: Always set request queue runtime active in blk_post_runtime_resume() chenxiang
2021-11-17  4:58   ` Bart Van Assche
2021-11-17  2:44 ` [PATCH 04/15] scsi: libsas: Add spin_lock/unlock() to protect asd_sas_port->phy_list chenxiang
2021-11-17  2:44 ` [PATCH 05/15] scsi: hisi_sas: Fix some issues related to asd_sas_port->phy_list chenxiang
2021-11-17  2:44 ` [PATCH 06/15] scsi: mvsas: Add spin_lock/unlock() to protect asd_sas_port->phy_list chenxiang
2021-11-17  2:45 ` [PATCH 07/15] scsi: libsas: Send event PORTE_BROADCAST_RCVD for valid ports chenxiang
2021-12-13 11:02   ` John Garry
2021-12-15  7:25     ` chenxiang (M)
2021-11-17  2:45 ` [PATCH 08/15] scsi: hisi_sas: Add more prink for runtime suspend/resume chenxiang
2021-12-13 10:34   ` John Garry
2021-12-15  7:26     ` chenxiang (M)
2021-12-13 10:35   ` John Garry
2021-12-15  7:26     ` chenxiang (M)
2021-11-17  2:45 ` [PATCH 09/15] scsi: libsas: Resume sas host before sending SMP IOs chenxiang
2021-12-13 11:12   ` John Garry
2021-12-15  8:00     ` chenxiang (M)
2021-11-17  2:45 ` [PATCH 10/15] scsi: libsas: Add a flag SAS_HA_RESUMING of sas_ha chenxiang
2021-12-13 11:17   ` John Garry
2021-12-15  7:34     ` chenxiang (M)
2021-11-17  2:45 ` [PATCH 11/15] scsi: libsas: Refactor out sas_queue_deferred_work() chenxiang
2021-12-13 11:20   ` John Garry
2021-12-15  7:59     ` chenxiang (M)
2021-11-17  2:45 ` [PATCH 12/15] scsi: libsas: Defer works of new phys during suspend chenxiang
2021-11-17  2:45 ` [PATCH 13/15] scsi: hisi_sas: Keep controller active between ISR of phyup and the event being processed chenxiang
2021-12-13 10:44   ` John Garry
2021-12-15  7:57     ` chenxiang (M)
2021-11-17  2:45 ` [PATCH 14/15] scsi: libsas: Keep sas host active until finished some work chenxiang
2021-12-14 12:34   ` John Garry
2021-12-15  7:46     ` chenxiang (M)
2021-11-17  2:45 ` [PATCH 15/15] scsi: hisi_sas: Use autosuspend for SAS controller chenxiang
2021-12-13 10:50   ` John Garry
2021-12-15  7:52     ` chenxiang (M)
2021-11-19  4:04 ` [PATCH 00/15] Add runtime PM support for libsas Martin K. Petersen
2021-11-23  6:01   ` chenxiang (M)
2021-12-14 11:52 ` John Garry
2021-12-15  7:56   ` chenxiang (M)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).