From: "Elliott, Robert (Servers)" <elliott@hpe.com>
To: 'Suwan Kim' <suwan.kim027@gmail.com>,
"mst@redhat.com" <mst@redhat.com>,
"jasowang@redhat.com" <jasowang@redhat.com>,
"stefanha@redhat.com" <stefanha@redhat.com>,
"pbonzini@redhat.com" <pbonzini@redhat.com>,
"mgurtovoy@nvidia.com" <mgurtovoy@nvidia.com>,
"dongli.zhang@oracle.com" <dongli.zhang@oracle.com>,
"hch@infradead.org" <hch@infradead.org>
Cc: "virtualization@lists.linux-foundation.org"
<virtualization@lists.linux-foundation.org>,
"linux-block@vger.kernel.org" <linux-block@vger.kernel.org>
Subject: RE: [PATCH v5 1/2] virtio-blk: support polling I/O
Date: Wed, 6 Apr 2022 01:43:55 +0000 [thread overview]
Message-ID: <MW5PR84MB18421588C1806B6E37FCECAEABE79@MW5PR84MB1842.NAMPRD84.PROD.OUTLOOK.COM> (raw)
In-Reply-To: <20220405150924.147021-2-suwan.kim027@gmail.com>
> -----Original Message-----
> From: Suwan Kim <suwan.kim027@gmail.com>
> Sent: Tuesday, April 5, 2022 10:09 AM
> Subject: [PATCH v5 1/2] virtio-blk: support polling I/O
>
> diff --git a/drivers/block/virtio_blk.c b/drivers/block/virtio_blk.c
> @@ -81,6 +85,7 @@ struct virtio_blk {
>
> /* num of vqs */
> int num_vqs;
> + int io_queues[HCTX_MAX_TYPES];
> struct virtio_blk_vq *vqs;
...
> };> @@ -565,6 +572,18 @@ static int init_vq(struct virtio_blk *vblk)
> min_not_zero(num_request_queues, nr_cpu_ids),
> num_vqs);
>
> + num_poll_vqs = min_t(unsigned int, poll_queues, num_vqs - 1);
> +
> + memset(vblk->io_queues, 0, sizeof(int) * HCTX_MAX_TYPES);
Using
sizeof(vblk->io_queues)
would automatically follow any changes in the definition of that field,
similar to the line below:
...
> vblk->vqs = kmalloc_array(num_vqs, sizeof(*vblk->vqs), GFP_KERNEL);
next prev parent reply other threads:[~2022-04-06 16:29 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-05 15:09 [PATCH v5 0/2] virtio-blk: support polling I/O and mq_ops->queue_rqs() Suwan Kim
2022-04-05 15:09 ` [PATCH v5 1/2] virtio-blk: support polling I/O Suwan Kim
2022-04-06 1:43 ` Elliott, Robert (Servers) [this message]
2022-04-06 13:36 ` Suwan Kim
2022-04-06 5:00 ` Christoph Hellwig
2022-04-06 5:00 ` Christoph Hellwig
2022-04-06 13:41 ` Suwan Kim
2022-04-06 14:10 ` Max Gurtovoy
2022-04-05 15:09 ` [PATCH v5 2/2] virtio-blk: support mq_ops->queue_rqs() Suwan Kim
2022-04-06 5:01 ` Christoph Hellwig
2022-04-06 5:01 ` Christoph Hellwig
2022-04-05 15:46 ` [PATCH v5 0/2] virtio-blk: support polling I/O and mq_ops->queue_rqs() Stefan Hajnoczi
2022-04-05 15:46 ` Stefan Hajnoczi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=MW5PR84MB18421588C1806B6E37FCECAEABE79@MW5PR84MB1842.NAMPRD84.PROD.OUTLOOK.COM \
--to=elliott@hpe.com \
--cc=dongli.zhang@oracle.com \
--cc=hch@infradead.org \
--cc=jasowang@redhat.com \
--cc=linux-block@vger.kernel.org \
--cc=mgurtovoy@nvidia.com \
--cc=mst@redhat.com \
--cc=pbonzini@redhat.com \
--cc=stefanha@redhat.com \
--cc=suwan.kim027@gmail.com \
--cc=virtualization@lists.linux-foundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.