All of lore.kernel.org
 help / color / mirror / Atom feed
* convert SCSI to atomic queue limits, part 1
@ 2024-03-24 23:54 Christoph Hellwig
  2024-03-24 23:54 ` [PATCH 01/23] block: don't reject too large max_user_setors in blk_validate_limits Christoph Hellwig
                   ` (22 more replies)
  0 siblings, 23 replies; 74+ messages in thread
From: Christoph Hellwig @ 2024-03-24 23:54 UTC (permalink / raw)
  To: Jens Axboe, Martin K. Petersen
  Cc: Damien Le Moal, Niklas Cassel, Takashi Sakamoto, Sathya Prakash,
	Sreekanth Reddy, Suganath Prabu Subramani, Juergen E. Fischer,
	Xiang Chen, HighPoint Linux Team, Tyrel Datwyler, Brian King,
	Lee Duncan, Chris Leech, Mike Christie, John Garry, Jason Yan,
	Kashyap Desai, Sumit Saxena, Shivasharan S, Chandrakanth patil,
	Jack Wang, Nilesh Javali, GR-QLogic-Storage-Upstream,
	Greg Kroah-Hartman, Alim Akhtar, Avri Altman, Bart Van Assche,
	Krzysztof Kozlowski, Alan Stern, linux-block, linux-ide,
	linux1394-devel, MPT-FusionLinux.pdl, linux-scsi, open-iscsi,
	megaraidlinux.pdl, mpi3mr-linuxdrv.pdl, linux-samsung-soc,
	linux-usb, usb-storage

Hi all,

this series converts the SCSI midlayer and LLDDs to use atomic queue limits
API.  It is pretty straight forward, except for the mpt3mr driver which
does really weird and probably already broken things by setting limits
from unlocked device iteration callsbacks.

The first patch is actually a bug fix and should probably go into 6.9-rc.
The other would probably best be in a shared branch between the block and
scsi code, as the ULD drivers will be a lot more extensive.  I'm actually
scratching my head on dealing with some of the updates that it does from
the I/O completion handler and ->open calls for already open devices.
Suggestions welcome..

Diffstat:
 block/blk-settings.c                        |  248 ----------------------------
 block/bsg-lib.c                             |    6 
 drivers/ata/ahci.h                          |    2 
 drivers/ata/libata-sata.c                   |   10 -
 drivers/ata/libata-scsi.c                   |   19 +-
 drivers/ata/libata.h                        |    3 
 drivers/ata/pata_macio.c                    |   11 -
 drivers/ata/sata_mv.c                       |    2 
 drivers/ata/sata_nv.c                       |   24 +-
 drivers/ata/sata_sil24.c                    |    2 
 drivers/firewire/sbp2.c                     |   13 -
 drivers/message/fusion/mptfc.c              |    1 
 drivers/message/fusion/mptsas.c             |    1 
 drivers/message/fusion/mptscsih.c           |    2 
 drivers/message/fusion/mptspi.c             |    1 
 drivers/s390/block/dasd_eckd.c              |    6 
 drivers/scsi/aha152x.c                      |    8 
 drivers/scsi/aic94xx/aic94xx_init.c         |    2 
 drivers/scsi/hisi_sas/hisi_sas.h            |    3 
 drivers/scsi/hisi_sas/hisi_sas_main.c       |    7 
 drivers/scsi/hisi_sas/hisi_sas_v1_hw.c      |    2 
 drivers/scsi/hisi_sas/hisi_sas_v2_hw.c      |    2 
 drivers/scsi/hisi_sas/hisi_sas_v3_hw.c      |    7 
 drivers/scsi/hosts.c                        |    6 
 drivers/scsi/hptiop.c                       |    8 
 drivers/scsi/ibmvscsi/ibmvfc.c              |    5 
 drivers/scsi/imm.c                          |   12 -
 drivers/scsi/ipr.c                          |   10 -
 drivers/scsi/isci/init.c                    |    2 
 drivers/scsi/iscsi_tcp.c                    |    2 
 drivers/scsi/libsas/sas_scsi_host.c         |    7 
 drivers/scsi/megaraid/megaraid_sas.h        |    2 
 drivers/scsi/megaraid/megaraid_sas_base.c   |   29 +--
 drivers/scsi/megaraid/megaraid_sas_fusion.c |    3 
 drivers/scsi/mpi3mr/mpi3mr.h                |    1 
 drivers/scsi/mpi3mr/mpi3mr_app.c            |   12 -
 drivers/scsi/mpi3mr/mpi3mr_os.c             |   76 +++-----
 drivers/scsi/mpt3sas/mpt3sas_scsih.c        |   18 --
 drivers/scsi/mvsas/mv_init.c                |    2 
 drivers/scsi/pm8001/pm8001_init.c           |    2 
 drivers/scsi/pmcraid.c                      |   11 -
 drivers/scsi/ppa.c                          |    8 
 drivers/scsi/qla2xxx/qla_os.c               |    6 
 drivers/scsi/scsi_lib.c                     |   40 +---
 drivers/scsi/scsi_scan.c                    |   79 ++++----
 drivers/scsi/scsi_transport_fc.c            |   15 +
 drivers/scsi/scsi_transport_iscsi.c         |    6 
 drivers/scsi/scsi_transport_sas.c           |    4 
 drivers/staging/rts5208/rtsx.c              |   24 +-
 drivers/ufs/core/ufs_bsg.c                  |    3 
 drivers/ufs/core/ufshcd.c                   |    3 
 drivers/ufs/host/ufs-exynos.c               |    8 
 drivers/usb/image/microtek.c                |    8 
 drivers/usb/storage/scsiglue.c              |   57 ++----
 drivers/usb/storage/uas.c                   |   29 +--
 drivers/usb/storage/usb.c                   |   10 +
 include/linux/blkdev.h                      |   13 -
 include/linux/bsg-lib.h                     |    3 
 include/linux/libata.h                      |   10 -
 include/linux/mmc/host.h                    |    4 
 include/scsi/libsas.h                       |    3 
 include/scsi/scsi_host.h                    |    9 +
 include/scsi/scsi_transport.h               |    2 
 include/scsi/scsi_transport_fc.h            |    1 
 include/ufs/ufshcd.h                        |    1 
 65 files changed, 335 insertions(+), 601 deletions(-)

^ permalink raw reply	[flat|nested] 74+ messages in thread
* convert SCSI to atomic queue limits, part 1 (v2)
@ 2024-04-02 13:06 Christoph Hellwig
  2024-04-02 13:06 ` [PATCH 18/23] sata_nv: switch to using ->device_configure Christoph Hellwig
  0 siblings, 1 reply; 74+ messages in thread
From: Christoph Hellwig @ 2024-04-02 13:06 UTC (permalink / raw)
  To: Jens Axboe, Martin K. Petersen
  Cc: Damien Le Moal, Niklas Cassel, Takashi Sakamoto, Sathya Prakash,
	Sreekanth Reddy, Suganath Prabu Subramani, Juergen E. Fischer,
	Xiang Chen, HighPoint Linux Team, Tyrel Datwyler, Brian King,
	Lee Duncan, Chris Leech, Mike Christie, John Garry, Jason Yan,
	Kashyap Desai, Sumit Saxena, Shivasharan S, Chandrakanth patil,
	Jack Wang, Nilesh Javali, GR-QLogic-Storage-Upstream,
	Greg Kroah-Hartman, Alim Akhtar, Avri Altman, Bart Van Assche,
	Krzysztof Kozlowski, Alan Stern, linux-block, linux-ide,
	linux1394-devel, MPT-FusionLinux.pdl, linux-scsi,
	megaraidlinux.pdl, mpi3mr-linuxdrv.pdl, linux-samsung-soc,
	linux-usb, usb-storage

Hi all,

this series converts the SCSI midlayer and LLDDs to use atomic queue limits
API.  It is pretty straight forward, except for the mpt3mr driver which
does really weird and probably already broken things by setting limits
from unlocked device iteration callbacks.

I will probably defer the (more complicated) ULD changes to the next
merge window as they would heavily conflict with Damien's zone write
plugging series.  With that the series could go in through the SCSI
tree if Jens' ACKs the core block layer bits.

Changes since v1:
 - print a different warning message for queue_limits_commit failure vs
   ->device_configure failure
 - cancel the queue limits update when ->device_configure fails
 - spelling fixes
 - improve comments

Diffstat:
 block/blk-settings.c                        |  245 ----------------------------
 block/bsg-lib.c                             |    6 
 drivers/ata/ahci.h                          |    2 
 drivers/ata/libata-sata.c                   |   11 -
 drivers/ata/libata-scsi.c                   |   19 +-
 drivers/ata/libata.h                        |    3 
 drivers/ata/pata_macio.c                    |   11 -
 drivers/ata/sata_mv.c                       |    2 
 drivers/ata/sata_nv.c                       |   24 +-
 drivers/ata/sata_sil24.c                    |    2 
 drivers/firewire/sbp2.c                     |   13 -
 drivers/message/fusion/mptfc.c              |    1 
 drivers/message/fusion/mptsas.c             |    1 
 drivers/message/fusion/mptscsih.c           |    2 
 drivers/message/fusion/mptspi.c             |    1 
 drivers/s390/block/dasd_eckd.c              |    6 
 drivers/scsi/aha152x.c                      |    8 
 drivers/scsi/aic94xx/aic94xx_init.c         |    2 
 drivers/scsi/hisi_sas/hisi_sas.h            |    3 
 drivers/scsi/hisi_sas/hisi_sas_main.c       |    7 
 drivers/scsi/hisi_sas/hisi_sas_v1_hw.c      |    2 
 drivers/scsi/hisi_sas/hisi_sas_v2_hw.c      |    2 
 drivers/scsi/hisi_sas/hisi_sas_v3_hw.c      |    7 
 drivers/scsi/hosts.c                        |    6 
 drivers/scsi/hptiop.c                       |    8 
 drivers/scsi/ibmvscsi/ibmvfc.c              |    5 
 drivers/scsi/imm.c                          |   12 -
 drivers/scsi/ipr.c                          |   10 -
 drivers/scsi/isci/init.c                    |    2 
 drivers/scsi/iscsi_tcp.c                    |    2 
 drivers/scsi/libsas/sas_scsi_host.c         |    7 
 drivers/scsi/megaraid/megaraid_sas.h        |    2 
 drivers/scsi/megaraid/megaraid_sas_base.c   |   29 +--
 drivers/scsi/megaraid/megaraid_sas_fusion.c |    3 
 drivers/scsi/mpi3mr/mpi3mr.h                |    1 
 drivers/scsi/mpi3mr/mpi3mr_app.c            |   12 -
 drivers/scsi/mpi3mr/mpi3mr_os.c             |   76 +++-----
 drivers/scsi/mpt3sas/mpt3sas_scsih.c        |   18 --
 drivers/scsi/mvsas/mv_init.c                |    2 
 drivers/scsi/pm8001/pm8001_init.c           |    2 
 drivers/scsi/pmcraid.c                      |   11 -
 drivers/scsi/ppa.c                          |    8 
 drivers/scsi/qla2xxx/qla_os.c               |    6 
 drivers/scsi/scsi_lib.c                     |   40 +---
 drivers/scsi/scsi_scan.c                    |   74 ++++----
 drivers/scsi/scsi_transport_fc.c            |   15 +
 drivers/scsi/scsi_transport_iscsi.c         |    6 
 drivers/scsi/scsi_transport_sas.c           |    4 
 drivers/staging/rts5208/rtsx.c              |   24 +-
 drivers/ufs/core/ufs_bsg.c                  |    3 
 drivers/ufs/core/ufshcd.c                   |    3 
 drivers/ufs/host/ufs-exynos.c               |    8 
 drivers/usb/image/microtek.c                |    8 
 drivers/usb/storage/scsiglue.c              |   57 ++----
 drivers/usb/storage/uas.c                   |   29 +--
 drivers/usb/storage/usb.c                   |   10 +
 include/linux/blkdev.h                      |   26 +-
 include/linux/bsg-lib.h                     |    3 
 include/linux/libata.h                      |   10 -
 include/linux/mmc/host.h                    |    4 
 include/scsi/libsas.h                       |    3 
 include/scsi/scsi_host.h                    |    9 +
 include/scsi/scsi_transport.h               |    2 
 include/scsi/scsi_transport_fc.h            |    1 
 include/ufs/ufshcd.h                        |    1 
 65 files changed, 347 insertions(+), 595 deletions(-)

^ permalink raw reply	[flat|nested] 74+ messages in thread
* convert SCSI to atomic queue limits, part 1 (v3)
@ 2024-04-09 14:37 Christoph Hellwig
  2024-04-09 14:37 ` [PATCH 18/23] sata_nv: switch to using ->device_configure Christoph Hellwig
  0 siblings, 1 reply; 74+ messages in thread
From: Christoph Hellwig @ 2024-04-09 14:37 UTC (permalink / raw)
  To: Jens Axboe, Martin K. Petersen
  Cc: Damien Le Moal, Niklas Cassel, Takashi Sakamoto, Sathya Prakash,
	Sreekanth Reddy, Suganath Prabu Subramani, Juergen E. Fischer,
	Xiang Chen, HighPoint Linux Team, Tyrel Datwyler, Brian King,
	Lee Duncan, Chris Leech, Mike Christie, John Garry, Jason Yan,
	Kashyap Desai, Sumit Saxena, Shivasharan S, Chandrakanth patil,
	Jack Wang, Nilesh Javali, GR-QLogic-Storage-Upstream,
	Greg Kroah-Hartman, Alim Akhtar, Avri Altman, Bart Van Assche,
	Krzysztof Kozlowski, Alan Stern, linux-block, linux-ide,
	linux1394-devel, MPT-FusionLinux.pdl, linux-scsi,
	megaraidlinux.pdl, mpi3mr-linuxdrv.pdl, linux-samsung-soc,
	linux-usb, usb-storage

Hi all,

this series converts the SCSI midlayer and LLDDs to use atomic queue limits
API.  It is pretty straight forward, except for the mpt3mr driver which
does really weird and probably already broken things by setting limits
from unlocked device iteration callbacks.

I will probably defer the (more complicated) ULD changes to the next
merge window as they would heavily conflict with Damien's zone write
plugging series.  With that the series could go in through the SCSI
tree if Jens' ACKs the core block layer bits.

Changes since v2:
 - rebased on top of the scsi-queue tree with libsas cleanups
 - fix another commit log typo

Changes since v1:
 - print a different warning message for queue_limits_commit failure vs
   ->device_configure failure
 - cancel the queue limits update when ->device_configure fails
 - spelling fixes
 - improve comments

Diffstat:
 block/blk-settings.c                        |  245 ----------------------------
 block/bsg-lib.c                             |    6 
 drivers/ata/ahci.h                          |    2 
 drivers/ata/libata-sata.c                   |   11 -
 drivers/ata/libata-scsi.c                   |   19 +-
 drivers/ata/libata.h                        |    3 
 drivers/ata/pata_macio.c                    |   11 -
 drivers/ata/sata_mv.c                       |    2 
 drivers/ata/sata_nv.c                       |   24 +-
 drivers/ata/sata_sil24.c                    |    2 
 drivers/firewire/sbp2.c                     |   13 -
 drivers/message/fusion/mptfc.c              |    1 
 drivers/message/fusion/mptsas.c             |    1 
 drivers/message/fusion/mptscsih.c           |    2 
 drivers/message/fusion/mptspi.c             |    1 
 drivers/s390/block/dasd_eckd.c              |    6 
 drivers/scsi/aha152x.c                      |    8 
 drivers/scsi/aic94xx/aic94xx_init.c         |    2 
 drivers/scsi/hisi_sas/hisi_sas.h            |    3 
 drivers/scsi/hisi_sas/hisi_sas_main.c       |    7 
 drivers/scsi/hisi_sas/hisi_sas_v1_hw.c      |    2 
 drivers/scsi/hisi_sas/hisi_sas_v2_hw.c      |    2 
 drivers/scsi/hisi_sas/hisi_sas_v3_hw.c      |    7 
 drivers/scsi/hosts.c                        |    6 
 drivers/scsi/hptiop.c                       |    8 
 drivers/scsi/ibmvscsi/ibmvfc.c              |    5 
 drivers/scsi/imm.c                          |   12 -
 drivers/scsi/ipr.c                          |   10 -
 drivers/scsi/isci/init.c                    |    2 
 drivers/scsi/iscsi_tcp.c                    |    2 
 drivers/scsi/libsas/sas_scsi_host.c         |    7 
 drivers/scsi/megaraid/megaraid_sas.h        |    2 
 drivers/scsi/megaraid/megaraid_sas_base.c   |   29 +--
 drivers/scsi/megaraid/megaraid_sas_fusion.c |    3 
 drivers/scsi/mpi3mr/mpi3mr.h                |    1 
 drivers/scsi/mpi3mr/mpi3mr_app.c            |   12 -
 drivers/scsi/mpi3mr/mpi3mr_os.c             |   76 +++-----
 drivers/scsi/mpt3sas/mpt3sas_scsih.c        |   18 --
 drivers/scsi/mvsas/mv_init.c                |    2 
 drivers/scsi/pm8001/pm8001_init.c           |    2 
 drivers/scsi/pmcraid.c                      |   11 -
 drivers/scsi/ppa.c                          |    8 
 drivers/scsi/qla2xxx/qla_os.c               |    6 
 drivers/scsi/scsi_lib.c                     |   40 +---
 drivers/scsi/scsi_scan.c                    |   74 ++++----
 drivers/scsi/scsi_transport_fc.c            |   15 +
 drivers/scsi/scsi_transport_iscsi.c         |    6 
 drivers/scsi/scsi_transport_sas.c           |    4 
 drivers/staging/rts5208/rtsx.c              |   24 +-
 drivers/ufs/core/ufs_bsg.c                  |    3 
 drivers/ufs/core/ufshcd.c                   |    3 
 drivers/ufs/host/ufs-exynos.c               |    8 
 drivers/usb/image/microtek.c                |    8 
 drivers/usb/storage/scsiglue.c              |   57 ++----
 drivers/usb/storage/uas.c                   |   29 +--
 drivers/usb/storage/usb.c                   |   10 +
 include/linux/blkdev.h                      |   26 +-
 include/linux/bsg-lib.h                     |    3 
 include/linux/libata.h                      |   10 -
 include/linux/mmc/host.h                    |    4 
 include/scsi/libsas.h                       |    3 
 include/scsi/scsi_host.h                    |    9 +
 include/scsi/scsi_transport.h               |    2 
 include/scsi/scsi_transport_fc.h            |    1 
 include/ufs/ufshcd.h                        |    1 
 65 files changed, 347 insertions(+), 595 deletions(-)

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

end of thread, other threads:[~2024-04-09 14:38 UTC | newest]

Thread overview: 74+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-03-24 23:54 convert SCSI to atomic queue limits, part 1 Christoph Hellwig
2024-03-24 23:54 ` [PATCH 01/23] block: don't reject too large max_user_setors in blk_validate_limits Christoph Hellwig
2024-03-25  7:14   ` Damien Le Moal
2024-03-25  9:28   ` John Garry
2024-03-24 23:54 ` [PATCH 02/23] bsg: pass queue_limits to bsg_setup_queue Christoph Hellwig
2024-03-25  7:16   ` Damien Le Moal
2024-03-25 18:53   ` Bart Van Assche
2024-03-27 14:35   ` John Garry
2024-03-24 23:54 ` [PATCH 03/23] mpi3mr: " Christoph Hellwig
2024-03-25  7:17   ` Damien Le Moal
2024-03-27 14:39   ` John Garry
2024-03-24 23:54 ` [PATCH 04/23] scsi: initialize scsi midlayer limits before allocating the queue Christoph Hellwig
2024-03-25  7:20   ` Damien Le Moal
2024-03-25 17:43   ` Bart Van Assche
2024-03-27 14:54   ` John Garry
2024-03-24 23:54 ` [PATCH 05/23] scsi_transport_fc: add a max_bsg_segments field to struct fc_function_template Christoph Hellwig
2024-03-25  7:23   ` Damien Le Moal
2024-03-24 23:54 ` [PATCH 06/23] scsi: add a no_highmem flag to struct Scsi_Host Christoph Hellwig
2024-03-25  7:26   ` Damien Le Moal
2024-03-26  6:09     ` Christoph Hellwig
2024-03-27 15:03   ` John Garry
2024-03-24 23:54 ` [PATCH 07/23] scsi: add a dma_alignment field to the host and host template Christoph Hellwig
2024-03-25  7:30   ` Damien Le Moal
2024-03-25 22:13   ` Bart Van Assche
2024-03-27 15:15   ` John Garry
2024-03-28  5:01     ` Christoph Hellwig
2024-03-24 23:54 ` [PATCH 08/23] ufs-exynos: move setting the the dma alignment to the init method Christoph Hellwig
2024-03-25  7:31   ` Damien Le Moal
2024-03-25 22:13   ` Bart Van Assche
2024-03-26 11:27   ` Alim Akhtar
2024-03-24 23:54 ` [PATCH 09/23] scsi: use the atomic queue limits API in scsi_add_lun Christoph Hellwig
2024-03-25  7:34   ` Damien Le Moal
2024-03-25 22:13   ` Bart Van Assche
2024-03-27 15:39   ` John Garry
2024-03-28  5:02     ` Christoph Hellwig
2024-03-24 23:54 ` [PATCH 10/23] scsi: add a device_configure method to the host template Christoph Hellwig
2024-03-25  7:38   ` Damien Le Moal
2024-03-26  6:13     ` Christoph Hellwig
2024-03-25 20:35   ` Bart Van Assche
2024-03-26  6:12     ` Christoph Hellwig
2024-03-24 23:54 ` [PATCH 11/23] megaraid_sas: switch to using ->device_configure Christoph Hellwig
2024-03-25  7:40   ` Damien Le Moal
2024-03-24 23:54 ` [PATCH 12/23] mpt3sas: " Christoph Hellwig
2024-03-25  7:41   ` Damien Le Moal
2024-03-24 23:54 ` [PATCH 13/23] sbp2: " Christoph Hellwig
2024-03-25  7:41   ` Damien Le Moal
2024-03-26  9:30   ` Takashi Sakamoto
2024-03-26 14:50     ` Christoph Hellwig
2024-03-24 23:54 ` [PATCH 14/23] hptiop: " Christoph Hellwig
2024-03-25  7:42   ` Damien Le Moal
2024-03-24 23:54 ` [PATCH 15/23] ipr: " Christoph Hellwig
2024-03-25  7:42   ` Damien Le Moal
2024-03-24 23:54 ` [PATCH 16/23] pmcraid: " Christoph Hellwig
2024-03-25  7:43   ` Damien Le Moal
2024-03-24 23:54 ` [PATCH 17/23] usb-storage: " Christoph Hellwig
2024-03-25  7:48   ` Damien Le Moal
2024-03-24 23:54 ` [PATCH 18/23] sata_nv: " Christoph Hellwig
2024-03-25  7:49   ` Damien Le Moal
2024-03-24 23:54 ` [PATCH 19/23] pata_macio: " Christoph Hellwig
2024-03-25  7:50   ` Damien Le Moal
2024-03-24 23:54 ` [PATCH 20/23] libata: " Christoph Hellwig
2024-03-25  7:52   ` Damien Le Moal
2024-03-28 10:01   ` Re : " John Garry
2024-03-24 23:54 ` [PATCH 21/23] mpi3mr: " Christoph Hellwig
2024-03-25  7:54   ` Damien Le Moal
2024-03-24 23:54 ` [PATCH 22/23] uas: switch to using ->device_configure to configure queue limits Christoph Hellwig
2024-03-25  7:55   ` Damien Le Moal
2024-03-24 23:54 ` [PATCH 23/23] block: remove now unused queue limits helpers Christoph Hellwig
2024-03-25  7:56   ` Damien Le Moal
2024-03-25 20:43   ` Bart Van Assche
2024-03-28 10:09   ` Re : " John Garry
2024-04-02 13:06 convert SCSI to atomic queue limits, part 1 (v2) Christoph Hellwig
2024-04-02 13:06 ` [PATCH 18/23] sata_nv: switch to using ->device_configure Christoph Hellwig
2024-04-03  7:13   ` Hannes Reinecke
2024-04-09 14:37 convert SCSI to atomic queue limits, part 1 (v3) Christoph Hellwig
2024-04-09 14:37 ` [PATCH 18/23] sata_nv: switch to using ->device_configure Christoph Hellwig

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.