- 16 12月, 2014 8 次提交
-
-
由 Michael S. Tsirkin 提交于
When switching everything over to virtio 1.0 memory access APIs, I missed converting vringh. Fortunately, it's straight-forward. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Pass u64 everywhere. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Seems to mostly be a positive. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Missed one place where vringh_test used long to pass features. Fix it up to u64. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Include missing virtio_config.h Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
As usual, add more stubs to fix test build after main codebase changes. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 15 12月, 2014 1 次提交
-
-
由 Michael S. Tsirkin 提交于
virtio 1.0 spec says: Drivers MUST NOT assume reads from fields greater than 32 bits wide are atomic, nor are reads from multiple fields: drivers SHOULD read device configuration space fields like so: u32 before, after; do { before = get_config_generation(device); // read config entry/entries. after = get_config_generation(device); } while (after != before); Do exactly this, for transports that support it. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 14 12月, 2014 2 次提交
-
-
由 Michael S. Tsirkin 提交于
Add macro to disable all legacy register defines. Helpful to make sure legacy macros don't leak through into modern code. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
It turns out this make everything easier. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 12 12月, 2014 3 次提交
-
-
由 Michael S. Tsirkin 提交于
Legacy drivers use virtio_pci_common.h too, we should not define VIRTIO_PCI_NO_LEGACY there. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
virtio_cread_bytes is implemented incorrectly in case length happens to be 2,4 or 8 bytes: transports and devices will assume it's an integer value that has to be converted to LE format. Let's just do multiple 1-byte reads: this also makes life easier for transports who only need to implement 1,2,4 and 8 byte reads. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
virtio 1.0 devices require that drivers set VIRTIO_CONFIG_S_FEATURES_OK after finalizing features. virtio core missed doing this on restore, fix it up. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Reviewed-by: NCornelia Huck <cornelia.huck@de.ibm.com>
-
- 10 12月, 2014 15 次提交
-
-
由 Cornelia Huck 提交于
We previously tried to use device even if finalize_features failed, but that's wrong since driver and device are now out of sync. Fail probe if we detect failures during finalize_features. Signed-off-by: NCornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
We never negotiate revision > 1, but just to make this code more likely to work when we do, require VERSION_1 with any revision >= 1. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Acked-by: NCornelia Huck <cornelia.huck@de.ibm.com>
-
由 Michael S. Tsirkin 提交于
kbuild does not seem to like it when we name source files same as the module. Let's rename virtio_pci -> virtio_pci_common, and get rid of #include-ing c files. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
There's been a lot of changes since 2007. List main authors, add Red Hat copyright. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Move everything dealing with legacy devices out to virtio_pci_legacy.c. Expose common code APIs in virtio_pci.h Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
config vector setup is version specific, do it indirectly. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
VQ setup is mostly version-specific, add another level of indirection to split the version-independent code out. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
VQ deletion is mostly version-specific, add another level of indirection to split the version-independent code out. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
slightly reduce the amount of pointer chasing this needs to do. More importantly, this will easily generalize to virtio 1.0. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
We don't need to go from vq to vq info on data path, so using direct vq->priv pointer for that seems like a waste. Let's build an array of vq infos, then we can use vq->index for that lookup. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
should be struct foo { } not struct foo { } Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Use isr field instead of direct access to ioaddr. This way generalizes easily to virtio 1.0. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
legacy_only flag is now unused, drop it from core. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Acked-by: NCornelia Huck <cornelia.huck@de.ibm.com>
-
由 Michael S. Tsirkin 提交于
we have blacklisted balloon in core, no need for a driver flag. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Acked-by: NCornelia Huck <cornelia.huck@de.ibm.com>
-
由 Michael S. Tsirkin 提交于
What does it mean if rev 1 device does not set VIRTIO_F_VERSION_1? E.g. is it native endian? Let's not even try to drive such devices: fail attempts to finalize features. virtio core will detect this and bail out. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 09 12月, 2014 11 次提交
-
-
由 Michael S. Tsirkin 提交于
This will make it easy for transports to validate features and return failure. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Legacy balloon device doesn't pretend to support revision 1 or 64 bit features. But just in case someone implements a broken one that does, let's not even try to drive legacy only devices using revision 1, and let's not give them a chance to say they support VIRTIO_F_VERSION_1 by not reading or writing high feature bits. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Reviewed-by: NCornelia Huck <cornelia.huck@de.ibm.com>
-
由 Michael S. Tsirkin 提交于
transports need to be able to detect legacy-only devices (ATM balloon only) to use legacy path to drive them. Add a core API to do just that. The implementation just blacklists balloon: not too pretty, but let's not over-engineer. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Acked-by: NCornelia Huck <cornelia.huck@de.ibm.com>
-
由 Michael S. Tsirkin 提交于
CHECK drivers/char/virtio_console.c drivers/char/virtio_console.c:687:36: warning: incorrect type in argument 1 (different address spaces) drivers/char/virtio_console.c:687:36: expected void [noderef] <asn:1>*to drivers/char/virtio_console.c:687:36: got char *out_buf drivers/char/virtio_console.c:790:35: warning: incorrect type in argument 2 (different address spaces) drivers/char/virtio_console.c:790:35: expected char *out_buf drivers/char/virtio_console.c:790:35: got char [noderef] <asn:1>*ubuf fill_readbuf is reused with both kernel and userspace pointers, depending on value of to_user flag. Tag address parameter as __user, and cast to/from regular pointer type when we know it's safe. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Jason Wang 提交于
Signed-off-by: NJason Wang <jasowang@redhat.com> Acked-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Core activates this bit automatically now, drop it from drivers that set it explicitly. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Activate VIRTIO_F_VERSION_1 automatically unless legacy_only is set. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
We have no plans to support virtio 1.0 in balloon driver. Add an explicit flag to mark it legacy only. This will be used by follow-up patches. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Pretty straight-forward, just use accessors for all fields. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
This merely fixes sparse warnings, without actually adding support for the new APIs. Still working out the best way to enable the new functionality. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
由 Michael S. Tsirkin 提交于
Include all endian conversions as required by virtio 1.0. Don't set virtio 1.0 yet, since that requires ANY_LAYOUT which we don't yet support. Signed-off-by: NMichael S. Tsirkin <mst@redhat.com> Acked-by: NPaolo Bonzini <pbonzini@redhat.com>
-