aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/virtio/virtio_balloon.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/virtio/virtio_balloon.c')
-rw-r--r--drivers/virtio/virtio_balloon.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/virtio/virtio_balloon.c b/drivers/virtio/virtio_balloon.c
index 34bdabaecbd6..36e7859a31aa 100644
--- a/drivers/virtio/virtio_balloon.c
+++ b/drivers/virtio/virtio_balloon.c
@@ -310,6 +310,12 @@ static int balloon(void *_vballoon)
310 else if (diff < 0) 310 else if (diff < 0)
311 leak_balloon(vb, -diff); 311 leak_balloon(vb, -diff);
312 update_balloon_size(vb); 312 update_balloon_size(vb);
313
314 /*
315 * For large balloon changes, we could spend a lot of time
316 * and always have work to do. Be nice if preempt disabled.
317 */
318 cond_resched();
313 } 319 }
314 return 0; 320 return 0;
315} 321}