diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-05-02 08:20:04 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-05-02 08:20:04 -0700 |
commit | 02cdf0827b61d51f0e9cc1b5ddd486950830ba08 (patch) | |
tree | a7e52e9f102782ccb52d72f5ca425f77fedce709 /drivers/virtio/virtio_balloon.c | |
parent | 8bec4a5d9305c86d028a519b08f05b81cd63cc55 (diff) | |
parent | a007a751d98fe97142e4724a83a4e31ec66b7532 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus
* git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus:
lguest: make Launcher see device status updates
lguest: remove bogus NULL cpu check
lguest: avoid using NR_CPUS as a bounds check.
virtio: add virtio disk geometry feature
virtio: explicit advertisement of driver features
virtio: change config to guest endian.
virtio: finer-grained features for virtio_net
virtio: wean net driver off NETDEV_TX_BUSY
virtio-blk: fix remove oops
virtio: fix scatterlist sizing in net driver.
virtio: de-structify virtio_block status byte
virtio: export more headers to userspace
virtio: fix sparse return void-valued expression warnings
virtio: fix tx_ stats in virtio_net
virtio: ignore corrupted virtqueues rather than spinning.
Diffstat (limited to 'drivers/virtio/virtio_balloon.c')
-rw-r--r-- | drivers/virtio/virtio_balloon.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/drivers/virtio/virtio_balloon.c b/drivers/virtio/virtio_balloon.c index 0b3efc31ee6..bfef604160d 100644 --- a/drivers/virtio/virtio_balloon.c +++ b/drivers/virtio/virtio_balloon.c @@ -155,9 +155,9 @@ static void virtballoon_changed(struct virtio_device *vdev) static inline s64 towards_target(struct virtio_balloon *vb) { u32 v; - __virtio_config_val(vb->vdev, - offsetof(struct virtio_balloon_config, num_pages), - &v); + vb->vdev->config->get(vb->vdev, + offsetof(struct virtio_balloon_config, num_pages), + &v, sizeof(v)); return v - vb->num_pages; } @@ -227,7 +227,7 @@ static int virtballoon_probe(struct virtio_device *vdev) } vb->tell_host_first - = vdev->config->feature(vdev, VIRTIO_BALLOON_F_MUST_TELL_HOST); + = virtio_has_feature(vdev, VIRTIO_BALLOON_F_MUST_TELL_HOST); return 0; @@ -259,7 +259,11 @@ static void virtballoon_remove(struct virtio_device *vdev) kfree(vb); } +static unsigned int features[] = { VIRTIO_BALLOON_F_MUST_TELL_HOST }; + static struct virtio_driver virtio_balloon = { + .feature_table = features, + .feature_table_size = ARRAY_SIZE(features), .driver.name = KBUILD_MODNAME, .driver.owner = THIS_MODULE, .id_table = id_table, |