[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 5/8] virtio-balloon: fill in the table of feature_si
From: |
Jesse Larrew |
Subject: |
[Qemu-devel] [PATCH 5/8] virtio-balloon: fill in the table of feature_sizes |
Date: |
Mon, 18 Feb 2013 16:22:42 -0600 |
There are two feature bits for virtio-balloon:
VIRTIO_BALLOON_F_MUST_TELL_HOST, and
VIRTIO_BALLOON_F_STATS_VQ.
Since these features don't require additional fields in the config struct,
set the 'end' field to the end of the last field in the struct.
Signed-off-by: Jesse Larrew <address@hidden>
---
hw/virtio-balloon.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/hw/virtio-balloon.c b/hw/virtio-balloon.c
index 81f27e9..c64e1b7 100644
--- a/hw/virtio-balloon.c
+++ b/hw/virtio-balloon.c
@@ -30,8 +30,10 @@
#endif
static VirtIOFeature feature_sizes[] = {
- {.flags = 0xffffffff, /* dummy table -- all features included. */
- .end = sizeof(struct virtio_balloon_config)},
+ {.flags = 1 << VIRTIO_BALLOON_F_MUST_TELL_HOST,
+ .end = endof(struct virtio_balloon_config, actual)},
+ {.flags = 1 << VIRTIO_BALLOON_F_STATS_VQ,
+ .end = endof(struct virtio_balloon_config, actual)},
{}
};
--
1.7.11.7
- [Qemu-devel] [PATCH 0/8] virtio: set config size using host features, Jesse Larrew, 2013/02/18
- [Qemu-devel] [PATCH 1/8] virtio-net: replace redundant config_size field with config_len, Jesse Larrew, 2013/02/18
- [Qemu-devel] [PATCH 8/8] virtio-blk: fill in the feature table, Jesse Larrew, 2013/02/18
- [Qemu-devel] [PATCH 6/8] virtio-serial: fill in the feature table, Jesse Larrew, 2013/02/18
- [Qemu-devel] [PATCH 7/8] virtio-scsi: fill in table of feature sizes, Jesse Larrew, 2013/02/18
- [Qemu-devel] [PATCH 2/8] virtio: put struct VirtIOFeature in a header, Jesse Larrew, 2013/02/18
- [Qemu-devel] [PATCH 4/8] virtio: set config size using host features, Jesse Larrew, 2013/02/18
- [Qemu-devel] [PATCH 5/8] virtio-balloon: fill in the table of feature_sizes,
Jesse Larrew <=
- [Qemu-devel] [PATCH 3/8] virtio: pass host features to driver init functions, Jesse Larrew, 2013/02/18
- Re: [Qemu-devel] [PATCH 0/8] virtio: set config size using host features, Anthony Liguori, 2013/02/19