diff options
author | Luiz Capitulino <lcapitulino@redhat.com> | 2013-12-05 13:04:10 +1030 |
---|---|---|
committer | Rusty Russell <rusty@rustcorp.com.au> | 2013-12-05 13:12:39 +1030 |
commit | 3459f11a8b16f40f9cde8e4281c2d5dd2ff1a732 (patch) | |
tree | 2591a49f6649fdaace3425a7a495011df53acd1e /drivers/virtio | |
parent | af91706d5ddecb4a9858cca9e90d463037cfd498 (diff) |
virtio_balloon: update_balloon_size(): update correct field
According to the virtio spec, the device configuration field
that should be updated after an inflation or deflation
operation is the 'actual' field, not the 'num_pages' one.
Commit 855e0c5288177bcb193f6f6316952d2490478e1c swapped them
in update_balloon_size(). Fix it.
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Fixes: 855e0c5288177bcb193f6f6316952d2490478e1c
Diffstat (limited to 'drivers/virtio')
-rw-r--r-- | drivers/virtio/virtio_balloon.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/virtio/virtio_balloon.c b/drivers/virtio/virtio_balloon.c index c444654fc33..5c4a95b516c 100644 --- a/drivers/virtio/virtio_balloon.c +++ b/drivers/virtio/virtio_balloon.c @@ -285,7 +285,7 @@ static void update_balloon_size(struct virtio_balloon *vb) { __le32 actual = cpu_to_le32(vb->num_pages); - virtio_cwrite(vb->vdev, struct virtio_balloon_config, num_pages, + virtio_cwrite(vb->vdev, struct virtio_balloon_config, actual, &actual); } |