lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 1 Jan 2016 12:13:48 +0200
From:	"Michael S. Tsirkin" <mst@...hat.com>
To:	linux-kernel@...r.kernel.org
Cc:	Petr Mladek <pmladek@...e.com>,
	virtualization@...ts.linux-foundation.org,
	Jeff Epler <jepler@...ythonic.net>, Tejun Heo <tj@...nel.org>,
	Jiri Kosina <jkosina@...e.cz>
Subject: [PATCH RFC] virtio_balloon: refill by config handler

Peter Mladek reported that balloon might never refill completely after
restore.  This is because fill_balloon is only called once there.
Calling fill_balloon repeatedly seems too aggressive,
especially in light of the fact that it sleeps on failure: let's
wake the config change handler and fill it asynchronously.

Reported-by: Petr Mladek <pmladek@...e.com>
Signed-off-by: Michael S. Tsirkin <mst@...hat.com>
---

I was unable to test this - for some reason my test VM
doesn't resume (with or without the patch).
Petr, does this work for you?

 drivers/virtio/virtio_balloon.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/virtio/virtio_balloon.c b/drivers/virtio/virtio_balloon.c
index 7efc329..ee29473 100644
--- a/drivers/virtio/virtio_balloon.c
+++ b/drivers/virtio/virtio_balloon.c
@@ -589,7 +589,7 @@ static int virtballoon_restore(struct virtio_device *vdev)
 
 	virtio_device_ready(vdev);
 
-	fill_balloon(vb, towards_target(vb));
+	wake_up(&vb->config_change);
 	update_balloon_size(vb);
 	return 0;
 }
-- 
MST
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ