* Re: [PATCH] virtio-blk: Fix memory leak among suspend/resume procedure
[not found] <20210517084332.280-1-xieyongji@bytedance.com>
@ 2021-05-25 6:20 ` Jason Wang
0 siblings, 0 replies; only message in thread
From: Jason Wang @ 2021-05-25 6:20 UTC (permalink / raw)
To: Xie Yongji, mst, stefanha; +Cc: linux-kernel, virtualization
在 2021/5/17 下午4:43, Xie Yongji 写道:
> The vblk->vqs should be freed before we call init_vqs()
> in virtblk_restore().
>
> Signed-off-by: Xie Yongji <xieyongji@bytedance.com>
Acked-by: Jason Wang <jasowang@redhat.com>
> ---
> drivers/block/virtio_blk.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/block/virtio_blk.c b/drivers/block/virtio_blk.c
> index 367a1e929d7c..d24a8cea9aab 100644
> --- a/drivers/block/virtio_blk.c
> +++ b/drivers/block/virtio_blk.c
> @@ -948,6 +948,8 @@ static int virtblk_freeze(struct virtio_device *vdev)
> blk_mq_quiesce_queue(vblk->disk->queue);
>
> vdev->config->del_vqs(vdev);
> + kfree(vblk->vqs);
> +
> return 0;
> }
>
_______________________________________________
Virtualization mailing list
Virtualization@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/virtualization
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2021-05-25 6:21 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20210517084332.280-1-xieyongji@bytedance.com>
2021-05-25 6:20 ` [PATCH] virtio-blk: Fix memory leak among suspend/resume procedure Jason Wang
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).