Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1451786
| Path | csiph.com!news.mixmin.net!news.unit0.net!news.panservice.it!bofh.it!news.nic.it!robomod |
|---|---|
| From | Bob Liu <bob.liu@oracle.com> |
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] drivers: virtio_blk: notify blk-core when hw-queue number changes |
| Date | Thu, 28 Jul 2016 10:20:01 +0200 |
| Message-ID | <rZOHT-3yL-5@gated-at.bofh.it> (permalink) |
| References | <rLwKS-1CT-3@gated-at.bofh.it> <rLwKS-1CT-1@gated-at.bofh.it> |
| User-Agent | Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130308 Thunderbird/17.0.4 |
| MIME-Version | 1.0 |
| Content-Type | text/plain; charset=windows-1252 |
| Content-Transfer-Encoding | 7bit |
| X-Source-IP | aserv0022.oracle.com [141.146.126.234] |
| Sender | robomod@news.nic.it |
| List-ID | <linux-kernel.vger.kernel.org> |
| X-Mailing-List | linux-kernel@vger.kernel.org |
| Approved | robomod@news.nic.it |
| Lines | 40 |
| Organization | linux.* mail to news gateway |
| X-Original-Cc | linux-kernel@vger.kernel.org, virtualization@lists.linux-foundation.org, mst@redhat.com |
| X-Original-Date | Thu, 28 Jul 2016 16:18:08 +0800 |
| X-Original-Message-ID | <5799BFC0.1060804@oracle.com> |
| X-Original-References | <1465811906-24510-1-git-send-email-bob.liu__9616.24590349874$1465832216$gmane$org@oracle.com> <3cd56d3a-85f0-9cce-d42f-f4eace84667b@redhat.com> |
| X-Original-Sender | linux-kernel-owner@vger.kernel.org |
| Xref | csiph.com linux.kernel:1451786 |
Show key headers only | View raw
On 06/19/2016 06:10 AM, Paolo Bonzini wrote: > > > On 13/06/2016 11:58, Bob Liu wrote: >> A guest might be migrated to other hosts with different num_queues, the >> blk-core should aware of that else the reference of &vblk->vqs[qid] may be wrong. >> >> Signed-off-by: Bob Liu <bob.liu@oracle.com> >> --- >> drivers/block/virtio_blk.c | 3 +++ >> 1 file changed, 3 insertions(+) >> >> diff --git a/drivers/block/virtio_blk.c b/drivers/block/virtio_blk.c >> index 42758b5..c169238 100644 >> --- a/drivers/block/virtio_blk.c >> +++ b/drivers/block/virtio_blk.c >> @@ -819,6 +819,9 @@ static int virtblk_restore(struct virtio_device *vdev) >> if (ret) >> return ret; >> >> + if (vblk->num_vqs != vblk->tag_set.nr_hw_queues) >> + blk_mq_update_nr_hw_queues(&vblk->tag_set, vblk->num_vqs); >> + >> virtio_device_ready(vdev); >> >> blk_mq_start_stopped_hw_queues(vblk->disk->queue, true); >> > > This should never happen; it'd be a configuration problem. > Do you mean all hosts have to be configured with the same number of ->num_vqs? What about cases like migrating a guest from HostA to HostB while HostB is much more powerful and would like to run more hardware queues to get better performance. Thanks, Bob Liu
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
Re: [PATCH] drivers: virtio_blk: notify blk-core when hw-queue number changes Bob Liu <bob.liu@oracle.com> - 2016-07-28 10:20 +0200 Re: [PATCH] drivers: virtio_blk: notify blk-core when hw-queue number changes Paolo Bonzini <pbonzini@redhat.com> - 2016-08-01 12:20 +0200
csiph-web