Re: [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-08 Thread Avi Kivity
On 10/07/2009 02:48 PM, Gregory Haskins wrote: If f() can cause another agent to write to p (by freeing it to a global list, for example), then it is its responsibility to issue the smp_rmb(), otherwise no calculation that took place before f() and accessed p is safe. IOW: David is

Re: [Alacrityvm-devel] [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-07 Thread Avi Kivity
On 10/06/2009 08:18 PM, Ira W. Snyder wrote: The limitation I have is that memory made available from the host system (PCI card) as PCI BAR1 must not be migrated around in memory. I can only change the address decoding to hit a specific physical address. AFAIK, this means it cannot be userspace

Re: [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-07 Thread Avi Kivity
On 10/06/2009 09:40 PM, Gregory Haskins wrote: Thinking about this some more over lunch, I think we (Avi and I) might both be wrong (and David is right). Avi is right that we don't need rmb() or barrier() for the reasons already stated, but I think David is right that we need an smp_mb() to

Re: [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-07 Thread Gregory Haskins
Avi Kivity wrote: On 10/06/2009 09:40 PM, Gregory Haskins wrote: Thinking about this some more over lunch, I think we (Avi and I) might both be wrong (and David is right). Avi is right that we don't need rmb() or barrier() for the reasons already stated, but I think David is right that we

Re: [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-06 Thread Avi Kivity
On 10/06/2009 01:57 AM, Gregory Haskins wrote: Avi Kivity wrote: On 10/02/2009 10:19 PM, Gregory Haskins wrote: What: xinterface is a mechanism that allows kernel modules external to the kvm.ko proper to interface with a running guest. It accomplishes this by creating an abstracted

Re: [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-06 Thread Gregory Haskins
Avi Kivity wrote: On 10/06/2009 01:57 AM, Gregory Haskins wrote: Avi Kivity wrote: On 10/02/2009 10:19 PM, Gregory Haskins wrote: What: xinterface is a mechanism that allows kernel modules external to the kvm.ko proper to interface with a running guest. It accomplishes this by

Re: [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-06 Thread Gregory Haskins
Gregory Haskins wrote: Avi Kivity wrote: On 10/06/2009 01:57 AM, Gregory Haskins wrote: Avi Kivity wrote: On 10/02/2009 10:19 PM, Gregory Haskins wrote: + +static inline void +_kvm_xinterface_release(struct kref *kref) +{ +struct kvm_xinterface *intf; +struct module *owner;

Re: [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-06 Thread Avi Kivity
On 10/06/2009 03:31 PM, Gregory Haskins wrote: slots would be one implementation, if you can think of others then you'd add them. I'm more interested in *how* you'd add them more than if we would add them. What I am getting at are the logistics of such a beast. Add alternative

Re: [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-06 Thread Avi Kivity
On 10/06/2009 04:22 PM, Gregory Haskins wrote: + +static inline void +_kvm_xinterface_release(struct kref *kref) +{ +struct kvm_xinterface *intf; +struct module *owner; + +intf = container_of(kref, struct kvm_xinterface, kref); + +owner = intf-owner; +rmb();

Re: [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-06 Thread Gregory Haskins
Avi Kivity wrote: On 10/06/2009 03:31 PM, Gregory Haskins wrote: slots would be one implementation, if you can think of others then you'd add them. I'm more interested in *how* you'd add them more than if we would add them. What I am getting at are the logistics of such a beast.

Re: [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-06 Thread Gregory Haskins
Avi Kivity wrote: On 10/06/2009 04:22 PM, Gregory Haskins wrote: + +static inline void +_kvm_xinterface_release(struct kref *kref) +{ +struct kvm_xinterface *intf; +struct module *owner; + +intf = container_of(kref, struct kvm_xinterface, kref); + +owner = intf-owner; +

Re: [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-06 Thread Gregory Haskins
Gregory Haskins wrote: Avi Kivity wrote: On 10/06/2009 04:22 PM, Gregory Haskins wrote: + +static inline void +_kvm_xinterface_release(struct kref *kref) +{ +struct kvm_xinterface *intf; +struct module *owner; + +intf = container_of(kref, struct kvm_xinterface, kref); + +

Re: [Alacrityvm-devel] [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-06 Thread Ira W. Snyder
On Tue, Oct 06, 2009 at 12:58:06PM -0400, Gregory Haskins wrote: Avi Kivity wrote: On 10/06/2009 03:31 PM, Gregory Haskins wrote: slots would be one implementation, if you can think of others then you'd add them. I'm more interested in *how* you'd add them more than if we would

Re: [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-06 Thread Gregory Haskins
Gregory Haskins wrote: Gregory Haskins wrote: Avi Kivity wrote: On 10/06/2009 04:22 PM, Gregory Haskins wrote: + +static inline void +_kvm_xinterface_release(struct kref *kref) +{ +struct kvm_xinterface *intf; +struct module *owner; + +intf = container_of(kref, struct

Re: [Alacrityvm-devel] [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-06 Thread Amit Shah
On (Tue) Oct 06 2009 [11:18:59], Ira W. Snyder wrote: The limitation I have is that memory made available from the host system (PCI card) as PCI BAR1 must not be migrated around in memory. I can only change the address decoding to hit a specific physical address. AFAIK, this means it cannot

Re: [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-05 Thread Gregory Haskins
Hi Marcelo! Marcelo Tosatti wrote: On Fri, Oct 02, 2009 at 04:19:27PM -0400, Gregory Haskins wrote: What: xinterface is a mechanism that allows kernel modules external to the kvm.ko proper to interface with a running guest. It accomplishes this by creating an abstracted interface which does

Re: [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-05 Thread Gregory Haskins
Avi Kivity wrote: On 10/02/2009 10:19 PM, Gregory Haskins wrote: What: xinterface is a mechanism that allows kernel modules external to the kvm.ko proper to interface with a running guest. It accomplishes this by creating an abstracted interface which does not expose any private details of

Re: [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-04 Thread Avi Kivity
On 10/02/2009 10:19 PM, Gregory Haskins wrote: What: xinterface is a mechanism that allows kernel modules external to the kvm.ko proper to interface with a running guest. It accomplishes this by creating an abstracted interface which does not expose any private details of the guest or its

Re: [PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-03 Thread Marcelo Tosatti
On Fri, Oct 02, 2009 at 04:19:27PM -0400, Gregory Haskins wrote: What: xinterface is a mechanism that allows kernel modules external to the kvm.ko proper to interface with a running guest. It accomplishes this by creating an abstracted interface which does not expose any private details of

[PATCH v2 2/4] KVM: introduce xinterface API for external interaction with guests

2009-10-02 Thread Gregory Haskins
What: xinterface is a mechanism that allows kernel modules external to the kvm.ko proper to interface with a running guest. It accomplishes this by creating an abstracted interface which does not expose any private details of the guest or its related KVM structures, and provides a mechanism to