KVM: Clarify KVM_ASSIGN_PCI_DEVICE documentation
Subsystems (2)
PATCH 1/1 KVM: Clarify KVM_ASSIGN_PCI_DEVICE documentation
From: Jan Kiszka <[email protected]>
Neither host_irq nor the guest_msi struct are used anymore today. Tag the former, drop the latter to avoid confusion.
--- Documentation/virtual/kvm/api.txt | 7 +------ 1 files changed, 1 insertions(+), 6 deletions(-)
Documentation/virtual/kvm/api.txt +1 -6
@@ -1143,15 +1143,10 @@ Assigns an IRQ to a passed-through device. struct kvm_assigned_irq { __u32 assigned_dev_id; - __u32 host_irq; + __u32 host_irq; /* ignored (legacy field) */ __u32 guest_irq; __u32 flags; union { - struct { - __u32 addr_lo; - __u32 addr_hi; - __u32 data; - } guest_msi; __u32 reserved[12]; }; };
Quoted 21 lines · Jan Kiszka
From: Jan Kiszka <[email protected]>
Neither
host_irqnor theguest_msistruct are used anymore today. Tag the former, drop the latter to avoid confusion.Signed-off-by Jan Kiszka <[email protected]>--- Documentation/virtual/kvm/api.txt | 7 +------ 1 files changed, 1 insertions(+), 6 deletions(-)Documentation/virtual/kvm/api.txt +1
-1@@ -1143,15 +1143,10 @@ Assigns an IRQ to a passed-through device. struct kvm_assigned_irq { __u32 assigned_dev_id; - __u32 host_irq; + __u32 host_irq; /* ignored (legacy field) */ __u32 guest_irq;
Documentation/virtual/kvm/api.txt Assigns an IRQ to a passed-through device. · line 1152
Quoted 10 lines
Documentation/virtual/kvm/api.txt +0
-5__u32 flags; union { - struct { - __u32 addr_lo; - __u32 addr_hi; - __u32 data; - } guest_msi; __u32 reserved[12]; }; };
Please update the kernel headers accordingly.
PATCH v2 1/1 KVM: Clarify KVM_ASSIGN_PCI_DEVICE documentation
From: Jan Kiszka <[email protected]>
Neither host_irq nor the guest_msi struct are used anymore today. Tag the former, drop the latter to avoid confusion.
--- Documentation/virtual/kvm/api.txt | 7 +------ include/linux/kvm.h | 8 +------- 2 files changed, 2 insertions(+), 13 deletions(-)
Documentation/virtual/kvm/api.txt +1 -6
@@ -1143,15 +1143,10 @@ Assigns an IRQ to a passed-through device. struct kvm_assigned_irq { __u32 assigned_dev_id; - __u32 host_irq; + __u32 host_irq; /* ignored (legacy field) */ __u32 guest_irq; __u32 flags; union { - struct { - __u32 addr_lo; - __u32 addr_hi; - __u32 data; - } guest_msi; __u32 reserved[12]; }; };
include/linux/kvm.h +1 -7
@@ -773,20 +773,14 @@ struct kvm_assigned_pci_dev {struct kvm_assigned_irq {__u32 assigned_dev_id; -__u32 host_irq; +__u32 host_irq;/* ignored (legacy field) */ __u32 guest_irq;__u32 flags;union { -struct { -__u32 addr_lo; -__u32 addr_hi; -__u32 data; - } guest_msi;__u32 reserved[12 ]; }; }; -struct kvm_assigned_msix_nr {__u32 assigned_dev_id;__u16 entry_nr;
Signature · 1 line
1.7.1
Quoted 22 lines · Jan Kiszka
From: Jan Kiszka<[email protected]>
Neither
host_irqnor theguest_msistruct are used anymore today. Tag the former, drop the latter to avoid confusion.include/linux/kvm.h +1
-4@@ -773,20 +773,14 @@ struct kvm_assigned_pci_dev {struct kvm_assigned_irq {__u32 assigned_dev_id; - __u32 host_irq; +__u32 host_irq;/* ignored (legacy field) */ __u32 guest_irq;__u32 flags;union { - struct { - __u32 addr_lo; - __u32 addr_hi;
include/linux/kvm.h struct kvm_assigned_pci_dev { · line 786
Quoted 10 lines
include/linux/kvm.h +0
-3-__u32 data; - } guest_msi;__u32 reserved[12 ]; }; }; -struct kvm_assigned_msix_nr {__u32 assigned_dev_id;__u16 entry_nr;
Can we just drop a definition like this? When did we last use this?
(in fact I can't find when we *ever* used this)
Signature · 1 line
error compiling committee.c: too many arguments to function
Quoted 29 lines · Avi Kivity
Quoted 28 lines · Jan Kiszka
From: Jan Kiszka<[email protected]>
Neither
host_irqnor theguest_msistruct are used anymore today. Tag the former, drop the latter to avoid confusion.include/linux/kvm.h +1
-6@@ -773,20 +773,14 @@ struct kvm_assigned_pci_dev {struct kvm_assigned_irq {__u32 assigned_dev_id; -__u32 host_irq; +__u32 host_irq;/* ignored (legacy field) */ __u32 guest_irq;__u32 flags;union { -struct { -__u32 addr_lo; -__u32 addr_hi; -__u32 data; - } guest_msi;__u32 reserved[12 ]; }; };
Quoted 9 lines
include/linux/kvm.h struct kvm_assigned_pci_dev { · line 786
Quoted 4 lines
include/linux/kvm.h +0
-1-struct kvm_assigned_msix_nr {__u32 assigned_dev_id;__u16 entry_nr;Can we just drop a definition like this? When did we last use this?
(in fact I can't find when we *ever* used this)
The kernel interface was present between in 2.6.29 only. The fact that we simply dropped that API (replacing it with the current one) indicates that no one was expecting this to be actually used.
I also do not find any traces of the old way of assigning MSIs in qemu-kvm.
Jan
Quoted 12 lines · Jan Kiszka
Quoted 5 lines
Can we just drop a definition like this? When did we last use this?
(in fact I can't find when we *ever* used this)
The kernel interface was present between in 2.6.29 only. The fact that we simply dropped that API (replacing it with the current one) indicates that no one was expecting this to be actually used.
I also do not find any traces of the old way of assigning MSIs in qemu-kvm.
Okay. There's some remote possibility that someone will pick up .29 and develop for it, but I think we can ignore that. Applied.
Signature · 1 line
error compiling committee.c: too many arguments to function