Re: [PATCH] Inter-VM shared memory PCI device

2010-03-11 Thread Arnd Bergmann
On Thursday 11 March 2010, Avi Kivity wrote: A totally different option that avoids this whole problem would be to separate the signalling from the shared memory, making the PCI shared memory device a trivial device with a single memory BAR, and using something a higher-level concept like

Re: [PATCH] Inter-VM shared memory PCI device

2010-03-11 Thread Avi Kivity
On 03/11/2010 02:57 PM, Arnd Bergmann wrote: On Thursday 11 March 2010, Avi Kivity wrote: A totally different option that avoids this whole problem would be to separate the signalling from the shared memory, making the PCI shared memory device a trivial device with a single memory BAR, and

Re: [PATCH] Inter-VM shared memory PCI device

2010-03-11 Thread Arnd Bergmann
On Thursday 11 March 2010, Avi Kivity wrote: That would be much slower. The current scheme allows for an ioeventfd/irqfd short circuit which allows one guest to interrupt another without involving their qemus at all. Yes, the serial line approach would be much slower, but my point

Re: [PATCH] Inter-VM shared memory PCI device

2010-03-10 Thread Avi Kivity
On 03/09/2010 08:34 PM, Cam Macdonell wrote: On Tue, Mar 9, 2010 at 10:28 AM, Avi Kivitya...@redhat.com wrote: On 03/09/2010 05:27 PM, Cam Macdonell wrote: Registers are used for synchronization between guests sharing the same memory object when interrupts are

Re: [PATCH] Inter-VM shared memory PCI device

2010-03-10 Thread Arnd Bergmann
On Tuesday 09 March 2010, Cam Macdonell wrote: We could make the masking in RAM, not in registers, like virtio, which would require no exits. It would then be part of the application specific protocol and out of scope of of this spec. This kind of implementation would be possible now

Re: [PATCH] Inter-VM shared memory PCI device

2010-03-10 Thread Cam Macdonell
On Wed, Mar 10, 2010 at 2:21 AM, Avi Kivity a...@redhat.com wrote: On 03/09/2010 08:34 PM, Cam Macdonell wrote: On Tue, Mar 9, 2010 at 10:28 AM, Avi Kivitya...@redhat.com  wrote: On 03/09/2010 05:27 PM, Cam Macdonell wrote:  Registers are used for synchronization between guests

Re: [PATCH] Inter-VM shared memory PCI device

2010-03-10 Thread Avi Kivity
On 03/10/2010 06:36 PM, Cam Macdonell wrote: On Wed, Mar 10, 2010 at 2:21 AM, Avi Kivitya...@redhat.com wrote: On 03/09/2010 08:34 PM, Cam Macdonell wrote: On Tue, Mar 9, 2010 at 10:28 AM, Avi Kivitya...@redhat.comwrote: On 03/09/2010 05:27 PM, Cam Macdonell wrote:

Re: [PATCH] Inter-VM shared memory PCI device

2010-03-10 Thread Avi Kivity
On 03/10/2010 04:04 PM, Arnd Bergmann wrote: On Tuesday 09 March 2010, Cam Macdonell wrote: We could make the masking in RAM, not in registers, like virtio, which would require no exits. It would then be part of the application specific protocol and out of scope of of this spec.

Re: [PATCH] Inter-VM shared memory PCI device

2010-03-09 Thread Arnd Bergmann
On Monday 08 March 2010, Cam Macdonell wrote: enum ivshmem_registers { IntrMask = 0, IntrStatus = 2, Doorbell = 4, IVPosition = 6, IVLiveList = 8 }; The first two registers are the interrupt mask and status registers. Interrupts are triggered when a message is

Re: [PATCH] Inter-VM shared memory PCI device

2010-03-09 Thread Avi Kivity
On 03/08/2010 07:57 PM, Cam Macdonell wrote: Can you provide a spec that describes the device? This would be useful for maintaining the code, writing guest drivers, and as a framework for review. I'm not sure if you want the Qemu command-line part as part of the spec here, but I've

Re: [PATCH] Inter-VM shared memory PCI device

2010-03-09 Thread Avi Kivity
On 03/09/2010 02:49 PM, Arnd Bergmann wrote: On Monday 08 March 2010, Cam Macdonell wrote: enum ivshmem_registers { IntrMask = 0, IntrStatus = 2, Doorbell = 4, IVPosition = 6, IVLiveList = 8 }; The first two registers are the interrupt mask and status registers.

Re: [PATCH] Inter-VM shared memory PCI device

2010-03-09 Thread Cam Macdonell
On Tue, Mar 9, 2010 at 6:03 AM, Avi Kivity a...@redhat.com wrote: On 03/09/2010 02:49 PM, Arnd Bergmann wrote: On Monday 08 March 2010, Cam Macdonell wrote: enum ivshmem_registers {     IntrMask = 0,     IntrStatus = 2,     Doorbell = 4,     IVPosition = 6,     IVLiveList = 8 }; The

Re: [PATCH] Inter-VM shared memory PCI device

2010-03-09 Thread Avi Kivity
On 03/09/2010 05:27 PM, Cam Macdonell wrote: Registers are used for synchronization between guests sharing the same memory object when interrupts are supported (this requires using the shared memory server). How does the driver detect whether interrupts are supported or not?

Re: [PATCH] Inter-VM shared memory PCI device

2010-03-09 Thread Anthony Liguori
On 03/09/2010 11:28 AM, Avi Kivity wrote: On 03/09/2010 05:27 PM, Cam Macdonell wrote: Registers are used for synchronization between guests sharing the same memory object when interrupts are supported (this requires using the shared memory server). How does the driver detect whether

Re: [PATCH] Inter-VM shared memory PCI device

2010-03-09 Thread Cam Macdonell
On Tue, Mar 9, 2010 at 10:28 AM, Avi Kivity a...@redhat.com wrote: On 03/09/2010 05:27 PM, Cam Macdonell wrote:  Registers are used for synchronization between guests sharing the same memory object when interrupts are supported (this requires using the shared memory server). How does the

Re: [PATCH] Inter-VM shared memory PCI device

2010-03-08 Thread Avi Kivity
On 03/06/2010 01:52 AM, Cam Macdonell wrote: Support an inter-vm shared memory device that maps a shared-memory object as a PCI device in the guest. This patch also supports interrupts between guest by communicating over a unix domain socket. This patch applies to the qemu-kvm repository.

Re: [PATCH] Inter-VM shared memory PCI device

2010-03-08 Thread Cam Macdonell
On Mon, Mar 8, 2010 at 2:56 AM, Avi Kivity a...@redhat.com wrote: On 03/06/2010 01:52 AM, Cam Macdonell wrote: Support an inter-vm shared memory device that maps a shared-memory object as a PCI device in the guest.  This patch also supports interrupts between guest by communicating over a