search for: set_guest_features

Displaying 20 results from an estimated 20 matches for "set_guest_features".

2015 Nov 18
2
[RFC] kvmtool: add support for modern virtio-pci
...d(int offset, bool msix, u32 *config_off); enum virtio_trans { + VIRTIO_PCI_MODERN, VIRTIO_PCI, VIRTIO_MMIO, }; @@ -138,8 +142,8 @@ struct virtio_device { struct virtio_ops { u8 *(*get_config)(struct kvm *kvm, void *dev); - u32 (*get_host_features)(struct kvm *kvm, void *dev); - void (*set_guest_features)(struct kvm *kvm, void *dev, u32 features); + u32 (*get_host_features)(struct kvm *kvm, void *dev, int sel); + void (*set_guest_features)(struct kvm *kvm, void *dev, u32 features, int sel); int (*init_vq)(struct kvm *kvm, void *dev, u32 vq, u32 page_size, u32 align, u32 pfn); int (*no...
2015 Nov 18
2
[RFC] kvmtool: add support for modern virtio-pci
...d(int offset, bool msix, u32 *config_off); enum virtio_trans { + VIRTIO_PCI_MODERN, VIRTIO_PCI, VIRTIO_MMIO, }; @@ -138,8 +142,8 @@ struct virtio_device { struct virtio_ops { u8 *(*get_config)(struct kvm *kvm, void *dev); - u32 (*get_host_features)(struct kvm *kvm, void *dev); - void (*set_guest_features)(struct kvm *kvm, void *dev, u32 features); + u32 (*get_host_features)(struct kvm *kvm, void *dev, int sel); + void (*set_guest_features)(struct kvm *kvm, void *dev, u32 features, int sel); int (*init_vq)(struct kvm *kvm, void *dev, u32 vq, u32 page_size, u32 align, u32 pfn); int (*no...
2012 Jul 23
4
[RFC 0/2] virtio: provide a way for host to monitor critical events in the device
As it was discussed recently, there's currently no way for the guest to notify the host about panics. Further more, there's no reasonable way to notify the host of other critical events such as an OOM kill. This short patch series introduces a new device named virtio-notifier which does two simple things: 1. Provide a simple interface for the guest to notify the host of critical
2012 Jul 23
4
[RFC 0/2] virtio: provide a way for host to monitor critical events in the device
As it was discussed recently, there's currently no way for the guest to notify the host about panics. Further more, there's no reasonable way to notify the host of other critical events such as an OOM kill. This short patch series introduces a new device named virtio-notifier which does two simple things: 1. Provide a simple interface for the guest to notify the host of critical
2011 Nov 11
1
[RFC] kvm tools: Implement multiple VQ for virtio-net
...s(struct kvm *kvm, void *dev) | 1UL << VIRTIO_NET_F_HOST_TSO6 | 1UL << VIRTIO_NET_F_GUEST_UFO | 1UL << VIRTIO_NET_F_GUEST_TSO4 - | 1UL << VIRTIO_NET_F_GUEST_TSO6; + | 1UL << VIRTIO_NET_F_GUEST_TSO6 + | 1UL << VIRTIO_NET_F_MULTIQUEUE; } static void set_guest_features(struct kvm *kvm, void *dev, u32 features) { struct net_dev *ndev = dev; + if (features & (1UL << VIRTIO_NET_F_MULTIQUEUE)) + ndev->vq_num = ndev->config.num_queues; + else + ndev->vq_num = 2; + ndev->features = features; } @@ -395,6 +401,8 @@ void virtio_net__init(...
2011 Nov 11
1
[RFC] kvm tools: Implement multiple VQ for virtio-net
...s(struct kvm *kvm, void *dev) | 1UL << VIRTIO_NET_F_HOST_TSO6 | 1UL << VIRTIO_NET_F_GUEST_UFO | 1UL << VIRTIO_NET_F_GUEST_TSO4 - | 1UL << VIRTIO_NET_F_GUEST_TSO6; + | 1UL << VIRTIO_NET_F_GUEST_TSO6 + | 1UL << VIRTIO_NET_F_MULTIQUEUE; } static void set_guest_features(struct kvm *kvm, void *dev, u32 features) { struct net_dev *ndev = dev; + if (features & (1UL << VIRTIO_NET_F_MULTIQUEUE)) + ndev->vq_num = ndev->config.num_queues; + else + ndev->vq_num = 2; + ndev->features = features; } @@ -395,6 +401,8 @@ void virtio_net__init(...
2012 Apr 07
0
[PATCH 05/14] kvm tools: Add virtio-mmio support
...URES_SEL: + case VIRTIO_MMIO_QUEUE_SEL: + case VIRTIO_MMIO_STATUS: + val = ioport__read32(data); + *(u32 *)(((void *)&vmmio->hdr) + addr) = val; + break; + case VIRTIO_MMIO_GUEST_FEATURES: + if (vmmio->hdr.guest_features_sel == 0) { + val = ioport__read32(data); + vdev->ops->set_guest_features(vmmio->kvm, + vmmio->dev, val); + } + break; + case VIRTIO_MMIO_GUEST_PAGE_SIZE: + val = ioport__read32(data); + vmmio->hdr.guest_page_size = val; + /* FIXME: set guest page size */ + break; + case VIRTIO_MMIO_QUEUE_NUM: + val = ioport__read32(data); + vmmio->hdr.queu...
2012 Apr 07
0
[PATCH 05/14] kvm tools: Add virtio-mmio support
...URES_SEL: + case VIRTIO_MMIO_QUEUE_SEL: + case VIRTIO_MMIO_STATUS: + val = ioport__read32(data); + *(u32 *)(((void *)&vmmio->hdr) + addr) = val; + break; + case VIRTIO_MMIO_GUEST_FEATURES: + if (vmmio->hdr.guest_features_sel == 0) { + val = ioport__read32(data); + vdev->ops->set_guest_features(vmmio->kvm, + vmmio->dev, val); + } + break; + case VIRTIO_MMIO_GUEST_PAGE_SIZE: + val = ioport__read32(data); + vmmio->hdr.guest_page_size = val; + /* FIXME: set guest page size */ + break; + case VIRTIO_MMIO_QUEUE_NUM: + val = ioport__read32(data); + vmmio->hdr.queu...
2011 Nov 15
2
[RFC] kvm tools: Add support for virtio-mmio
...O_QUEUE_NUM: + case VIRTIO_MMIO_QUEUE_ALIGN: + case VIRTIO_MMIO_STATUS: + *(u32 *)(((void *)&vmmio->hdr) + addr) = ioport__read32(data); + break; + case VIRTIO_MMIO_GUEST_FEATURES: + if (vmmio->hdr.guest_features_sel == 0) { + val = ioport__read32(data); + vtrans->virtio_ops->set_guest_features(vmmio->kvm, vmmio->dev, val); + } + break; + case VIRTIO_MMIO_QUEUE_PFN: + val = ioport__read32(data); + vtrans->virtio_ops->init_vq(vmmio->kvm, vmmio->dev, vmmio->hdr.queue_sel, val); + break; + case VIRTIO_MMIO_QUEUE_NOTIFY: + val = ioport__read32(data); + vtrans->v...
2011 Nov 15
2
[RFC] kvm tools: Add support for virtio-mmio
...O_QUEUE_NUM: + case VIRTIO_MMIO_QUEUE_ALIGN: + case VIRTIO_MMIO_STATUS: + *(u32 *)(((void *)&vmmio->hdr) + addr) = ioport__read32(data); + break; + case VIRTIO_MMIO_GUEST_FEATURES: + if (vmmio->hdr.guest_features_sel == 0) { + val = ioport__read32(data); + vtrans->virtio_ops->set_guest_features(vmmio->kvm, vmmio->dev, val); + } + break; + case VIRTIO_MMIO_QUEUE_PFN: + val = ioport__read32(data); + vtrans->virtio_ops->init_vq(vmmio->kvm, vmmio->dev, vmmio->hdr.queue_sel, val); + break; + case VIRTIO_MMIO_QUEUE_NOTIFY: + val = ioport__read32(data); + vtrans->v...
2016 Aug 31
4
[RFC/PATCHSET 0/3] virtio: Implement virtio pstore device (v4)
Hello, This is another iteration of the virtio-pstore work. I've addressed all comments from Daniel Berrange on the qemu side. * changes in v4) - use qio_channel_file_new_path() (Daniel) - rename to delete_old_pstore_file (Daniel) - convert G_REMOVE_SOURCE to FALSE (Daniel) * changes in v3) - use QIOChannel API (Stefan, Daniel) - add bound check for malcious guests
2016 Aug 31
4
[RFC/PATCHSET 0/3] virtio: Implement virtio pstore device (v4)
Hello, This is another iteration of the virtio-pstore work. I've addressed all comments from Daniel Berrange on the qemu side. * changes in v4) - use qio_channel_file_new_path() (Daniel) - rename to delete_old_pstore_file (Daniel) - convert G_REMOVE_SOURCE to FALSE (Daniel) * changes in v3) - use QIOChannel API (Stefan, Daniel) - add bound check for malcious guests
2016 Jul 18
7
[RFC/PATCHSET 0/3] virtio-pstore: Implement virtio pstore device
Hello, This patchset is a proof of concept of virtio-pstore idea [1]. It has some rough edges and I'm not familiar with this area, so please give me feedbacks and advices if I'm going to a wrong direction. It started from the fact that dumping ftrace buffer at kernel oops/panic takes too much time. Although there's a way to reduce the size of the original data, sometimes I want to
2016 Jul 18
7
[RFC/PATCHSET 0/3] virtio-pstore: Implement virtio pstore device
Hello, This patchset is a proof of concept of virtio-pstore idea [1]. It has some rough edges and I'm not familiar with this area, so please give me feedbacks and advices if I'm going to a wrong direction. It started from the fact that dumping ftrace buffer at kernel oops/panic takes too much time. Although there's a way to reduce the size of the original data, sometimes I want to
2016 Jul 27
11
[RFC/PATCHSET 0/7] virtio: Implement virtio pstore device (v2)
Hello, This is v2 of the virtio-pstore work. In this patchset I addressed most of feedbacks from previous version. Limiting disk size is not implemented yet. * changes in v2) - update VIRTIO_ID_PSTORE to 22 (Cornelia, Stefan) - make buffer size configurable (Cornelia) - support PSTORE_TYPE_CONSOLE (Kees) - use separate virtqueues for read and write - support concurrent async
2016 Jul 27
11
[RFC/PATCHSET 0/7] virtio: Implement virtio pstore device (v2)
Hello, This is v2 of the virtio-pstore work. In this patchset I addressed most of feedbacks from previous version. Limiting disk size is not implemented yet. * changes in v2) - update VIRTIO_ID_PSTORE to 22 (Cornelia, Stefan) - make buffer size configurable (Cornelia) - support PSTORE_TYPE_CONSOLE (Kees) - use separate virtqueues for read and write - support concurrent async
2016 Aug 20
7
[RFC/PATCHSET 0/3] virtio: Implement virtio pstore device (v3)
Hello, This is another iteration of the virtio-pstore work. In this patchset I addressed most of feedbacks from previous version and drooped the support for PSTORE_TYPE_CONSOLE for simplicity. It'll be added once the basic implementation * changes in v3) - use QIOChannel API (Stefan, Daniel) - add bound check for malcious guests (Daniel) - drop support PSTORE_TYPE_CONSOLE for now
2016 Aug 20
7
[RFC/PATCHSET 0/3] virtio: Implement virtio pstore device (v3)
Hello, This is another iteration of the virtio-pstore work. In this patchset I addressed most of feedbacks from previous version and drooped the support for PSTORE_TYPE_CONSOLE for simplicity. It'll be added once the basic implementation * changes in v3) - use QIOChannel API (Stefan, Daniel) - add bound check for malcious guests (Daniel) - drop support PSTORE_TYPE_CONSOLE for now
2017 Apr 07
34
[RFC 0/3] virtio-iommu: a paravirtualized IOMMU
This is the initial proposal for a paravirtualized IOMMU device using virtio transport. It contains a description of the device, a Linux driver, and a toy implementation in kvmtool. With this prototype, you can translate DMA to guest memory from emulated (virtio), or passed-through (VFIO) devices. In its simplest form, implemented here, the device handles map/unmap requests from the guest. Future
2017 Apr 07
34
[RFC 0/3] virtio-iommu: a paravirtualized IOMMU
This is the initial proposal for a paravirtualized IOMMU device using virtio transport. It contains a description of the device, a Linux driver, and a toy implementation in kvmtool. With this prototype, you can translate DMA to guest memory from emulated (virtio), or passed-through (VFIO) devices. In its simplest form, implemented here, the device handles map/unmap requests from the guest. Future