virtio_mmio: generation support
authorMichael S. Tsirkin <mst@redhat.com>
Thu, 12 Mar 2015 02:26:43 +0000 (12:56 +1030)
committerRusty Russell <rusty@rustcorp.com.au>
Fri, 13 Mar 2015 05:25:43 +0000 (15:55 +1030)
commit87e7bf1450c9f6bd0927f63ebc0fe2d12e8bc83d
treea4292d97cd9671365d410c6c840d162c5a0da99b
parent71e4b8bf0482fc7d70e9d4c10b13c207a285d58a
virtio_mmio: generation support

virtio_mmio currently lacks generation support which
makes multi-byte field access racy.
Fix by getting the value at offset 0xfc for version 2
devices. Nothing we can do for version 1, so return
generation id 0.

Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
drivers/virtio/virtio_mmio.c