mbox series

[v6,00/15] block/nvme: Various cleanups required to use multiple queues

Message ID 20200821195359.1285345-1-philmd@redhat.com
Headers show
Series block/nvme: Various cleanups required to use multiple queues | expand

Message

Philippe Mathieu-Daudé Aug. 21, 2020, 7:53 p.m. UTC
Hi Kevin,

This series is mostly code rearrangement (cleanups) to be
able to split the hardware code from the block driver code,
to be able to use multiple queues on the same hardware, or
multiple block drivers on the same hardware.

All this series is reviewed.

Since v5:
- audit rebase on "block/nvme: support nested aio_poll"
- addressed Stefano's review comments
- added Stefano's R-b tags

Since v4:
- added 'block/nvme: Use an array of EventNotifier' patch

Since v3:
- renamed QUEUE_INDEX_{ADMIN/IO} -> INDEX{ADMIN/IO}
- added stefanha tags

Since v2:
- addressed stefanha review comments
- added 4 trivial patches (to simplify the last one)
- register IRQ notifier for each queuepair (admin and io)

Since v1:
- rebased
- use SCALE_MS definition
- added Stefan's R-b
- addressed Stefan's review comments
  - use union { NvmeIdCtrl / NvmeIdNs }
  - move irq_notifier to NVMeQueuePair
  - removed patches depending on "a tracable hardware stateo
    object instead of BDRVNVMeState".

Phil.

Philippe Mathieu-Daudé (15):
  block/nvme: Replace magic value by SCALE_MS definition
  block/nvme: Avoid further processing if trace event not enabled
  block/nvme: Let nvme_create_queue_pair() fail gracefully
  block/nvme: Define INDEX macros to ease code review
  block/nvme: Improve error message when IO queue creation failed
  block/nvme: Use common error path in nvme_add_io_queue()
  block/nvme: Rename local variable
  block/nvme: Use union of NvmeIdCtrl / NvmeIdNs structures
  block/nvme: Replace qemu_try_blockalign0 by qemu_try_blockalign/memset
  block/nvme: Replace qemu_try_blockalign(bs) by
    qemu_try_memalign(pg_sz)
  block/nvme: Simplify nvme_init_queue() arguments
  block/nvme: Replace BDRV_POLL_WHILE by AIO_WAIT_WHILE
  block/nvme: Simplify nvme_create_queue_pair() arguments
  block/nvme: Extract nvme_poll_queue()
  block/nvme: Use an array of EventNotifier

 block/nvme.c | 211 ++++++++++++++++++++++++++++++---------------------
 1 file changed, 125 insertions(+), 86 deletions(-)

Comments

Philippe Mathieu-Daudé Sept. 1, 2020, 3:27 p.m. UTC | #1
On 8/21/20 9:53 PM, Philippe Mathieu-Daudé wrote:
> Hi Kevin,
> 
> This series is mostly code rearrangement (cleanups) to be
> able to split the hardware code from the block driver code,
> to be able to use multiple queues on the same hardware, or
> multiple block drivers on the same hardware.
> 
> All this series is reviewed.

ping? :)

> Philippe Mathieu-Daudé (15):
>   block/nvme: Replace magic value by SCALE_MS definition
>   block/nvme: Avoid further processing if trace event not enabled
>   block/nvme: Let nvme_create_queue_pair() fail gracefully
>   block/nvme: Define INDEX macros to ease code review
>   block/nvme: Improve error message when IO queue creation failed
>   block/nvme: Use common error path in nvme_add_io_queue()
>   block/nvme: Rename local variable
>   block/nvme: Use union of NvmeIdCtrl / NvmeIdNs structures
>   block/nvme: Replace qemu_try_blockalign0 by qemu_try_blockalign/memset
>   block/nvme: Replace qemu_try_blockalign(bs) by
>     qemu_try_memalign(pg_sz)
>   block/nvme: Simplify nvme_init_queue() arguments
>   block/nvme: Replace BDRV_POLL_WHILE by AIO_WAIT_WHILE
>   block/nvme: Simplify nvme_create_queue_pair() arguments
>   block/nvme: Extract nvme_poll_queue()
>   block/nvme: Use an array of EventNotifier
> 
>  block/nvme.c | 211 ++++++++++++++++++++++++++++++---------------------
>  1 file changed, 125 insertions(+), 86 deletions(-)
>
Kevin Wolf Sept. 1, 2020, 3:52 p.m. UTC | #2
Am 21.08.2020 um 21:53 hat Philippe Mathieu-Daudé geschrieben:
> Hi Kevin,
> 
> This series is mostly code rearrangement (cleanups) to be
> able to split the hardware code from the block driver code,
> to be able to use multiple queues on the same hardware, or
> multiple block drivers on the same hardware.
> 
> All this series is reviewed.

Thanks, applied to the block branch.

Kevin