Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-16 Thread Muli Ben-Yehuda
On Tue, Dec 15, 2009 at 07:24:47PM +0100, Alexander Graf wrote: > Michael S. Tsirkin wrote: > > > I guess this means you'll have to find a device with a sub-page > > BAR to test this on, instead of hacking driver for a device with > > full page BAR. Did anyone ever try doing passthrough on an > > e

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-15 Thread Alexander Graf
Michael S. Tsirkin wrote: > I guess this means you'll have to find a device with a sub-page BAR > to test this on, instead of hacking driver for a device with full > page BAR. Did anyone ever try doing passthrough on an emulated > device in nested virt? > We don't emulate an IOMMU, so no. Ale

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-15 Thread Michael S. Tsirkin
On Tue, Dec 15, 2009 at 07:16:13PM +0100, Alexander Graf wrote: > Michael S. Tsirkin wrote: > > On Fri, Dec 11, 2009 at 12:06:25AM +0100, Alexander Graf wrote: > > > >> While trying to get device passthrough working with an emulex hba, kvm > >> refused to pass it through because it has a BAR of

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-15 Thread Alexander Graf
Michael S. Tsirkin wrote: > On Fri, Dec 11, 2009 at 12:06:25AM +0100, Alexander Graf wrote: > >> While trying to get device passthrough working with an emulex hba, kvm >> refused to pass it through because it has a BAR of 256 bytes: >> >> Region 0: Memory at d210 (64-bit, non-prefetc

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-11 Thread Michael S. Tsirkin
On Fri, Dec 11, 2009 at 12:06:25AM +0100, Alexander Graf wrote: > While trying to get device passthrough working with an emulex hba, kvm > refused to pass it through because it has a BAR of 256 bytes: > > Region 0: Memory at d210 (64-bit, non-prefetchable) [size=4K] > Region 2:

[PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Alexander Graf
While trying to get device passthrough working with an emulex hba, kvm refused to pass it through because it has a BAR of 256 bytes: Region 0: Memory at d210 (64-bit, non-prefetchable) [size=4K] Region 2: Memory at d2101000 (64-bit, non-prefetchable) [size=256] Region 4

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Gleb Natapov
On Thu, Dec 10, 2009 at 01:21:40PM +0200, Michael S. Tsirkin wrote: > On Thu, Dec 10, 2009 at 12:09:13PM +0100, Alexander Graf wrote: > > > > On 10.12.2009, at 11:56, Michael S. Tsirkin wrote: > > > > > On Thu, Dec 10, 2009 at 12:37:37PM +0200, Muli Ben-Yehuda wrote: > > >> On Thu, Dec 10, 2009 a

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Michael S. Tsirkin
On Thu, Dec 10, 2009 at 12:34:38PM +0100, Alexander Graf wrote: > > On 10.12.2009, at 12:28, Muli Ben-Yehuda wrote: > > > On Thu, Dec 10, 2009 at 12:56:56PM +0200, Michael S. Tsirkin wrote: > > > >>> mmio and pio are easy, DMA you'd need an IOMMU for security, or > >>> whatever uio does just for

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Michael S. Tsirkin
On Thu, Dec 10, 2009 at 01:28:49PM +0200, Muli Ben-Yehuda wrote: > On Thu, Dec 10, 2009 at 12:56:56PM +0200, Michael S. Tsirkin wrote: > > > > mmio and pio are easy, DMA you'd need an IOMMU for security, or > > > whatever uio does just for translation, > > > > uio currently does not support DMA,

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Alexander Graf
On 10.12.2009, at 12:28, Muli Ben-Yehuda wrote: > On Thu, Dec 10, 2009 at 12:56:56PM +0200, Michael S. Tsirkin wrote: > >>> mmio and pio are easy, DMA you'd need an IOMMU for security, or >>> whatever uio does just for translation, >> >> uio currently does not support DMA, but I plan to fix thi

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Muli Ben-Yehuda
On Thu, Dec 10, 2009 at 12:56:56PM +0200, Michael S. Tsirkin wrote: > > mmio and pio are easy, DMA you'd need an IOMMU for security, or > > whatever uio does just for translation, > > uio currently does not support DMA, but I plan to fix this With or without an IOMMU? > > and interrupts you pro

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Michael S. Tsirkin
On Thu, Dec 10, 2009 at 12:09:13PM +0100, Alexander Graf wrote: > > On 10.12.2009, at 11:56, Michael S. Tsirkin wrote: > > > On Thu, Dec 10, 2009 at 12:37:37PM +0200, Muli Ben-Yehuda wrote: > >> On Thu, Dec 10, 2009 at 11:31:01AM +0100, Alexander Graf wrote: > >> > What do you have in mind

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Alexander Graf
On 10.12.2009, at 11:56, Michael S. Tsirkin wrote: > On Thu, Dec 10, 2009 at 12:37:37PM +0200, Muli Ben-Yehuda wrote: >> On Thu, Dec 10, 2009 at 11:31:01AM +0100, Alexander Graf wrote: >> What do you have in mind for such a rewrite? >>> >>> I'd like to see it more well-abstracted and versa

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Michael S. Tsirkin
On Thu, Dec 10, 2009 at 12:37:37PM +0200, Muli Ben-Yehuda wrote: > On Thu, Dec 10, 2009 at 11:31:01AM +0100, Alexander Graf wrote: > > > > What do you have in mind for such a rewrite? > > > > I'd like to see it more well-abstracted and versatile. I don't see > > an obvious reason why we shouldn't

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Michael S. Tsirkin
On Thu, Dec 10, 2009 at 11:31:54AM +0100, Alexander Graf wrote: > > On 10.12.2009, at 11:27, Michael S. Tsirkin wrote: > > > On Thu, Dec 10, 2009 at 11:08:58AM +0100, Alexander Graf wrote: > >> > >> On 10.12.2009, at 10:52, Alexander Graf wrote: > >> > >>> > >>> On 10.12.2009, at 10:43, Michae

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Muli Ben-Yehuda
On Thu, Dec 10, 2009 at 11:31:01AM +0100, Alexander Graf wrote: > > What do you have in mind for such a rewrite? > > I'd like to see it more well-abstracted and versatile. I don't see > an obvious reason why we shouldn't be able to use a physical device > in a TCG target :-). mmio and pio are ea

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Avi Kivity
On 12/09/2009 11:06 PM, Alexander Graf wrote: Am 09.12.2009 um 21:49 schrieb "Michael S. Tsirkin" : On Wed, Dec 09, 2009 at 06:38:54PM +0100, Alexander Graf wrote: While trying to get device passthrough working with an emulex hba, kvm refused to pass it through because it has a BAR of 256 byt

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Alexander Graf
On 10.12.2009, at 11:27, Michael S. Tsirkin wrote: > On Thu, Dec 10, 2009 at 11:08:58AM +0100, Alexander Graf wrote: >> >> On 10.12.2009, at 10:52, Alexander Graf wrote: >> >>> >>> On 10.12.2009, at 10:43, Michael S. Tsirkin wrote: >>> On Thu, Dec 10, 2009 at 07:16:04AM +0200, Muli Ben-Y

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Alexander Graf
On 10.12.2009, at 11:23, Muli Ben-Yehuda wrote: > On Thu, Dec 10, 2009 at 10:52:46AM +0100, Alexander Graf wrote: > >> Either way, FWIW the device assignment stuff needs to be completely >> rewritten for qemu upstream anyways. So while it's good to collect >> ideas for now, let's not too put too

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Michael S. Tsirkin
On Thu, Dec 10, 2009 at 11:08:58AM +0100, Alexander Graf wrote: > > On 10.12.2009, at 10:52, Alexander Graf wrote: > > > > > On 10.12.2009, at 10:43, Michael S. Tsirkin wrote: > > > >> On Thu, Dec 10, 2009 at 07:16:04AM +0200, Muli Ben-Yehuda wrote: > >>> On Wed, Dec 09, 2009 at 06:38:54PM +010

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Muli Ben-Yehuda
On Thu, Dec 10, 2009 at 10:52:46AM +0100, Alexander Graf wrote: > Either way, FWIW the device assignment stuff needs to be completely > rewritten for qemu upstream anyways. So while it's good to collect > ideas for now, let's not too put too much effort code-wise into the > current code (unless it

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Muli Ben-Yehuda
On Thu, Dec 10, 2009 at 10:35:41AM +0100, Alexander Graf wrote: > That's exactly what this patch does. It only allows access to the > region defined in the BAR. Sorry, missed it! Cheers, Muli -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majord...@

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Alexander Graf
On 10.12.2009, at 10:52, Alexander Graf wrote: > > On 10.12.2009, at 10:43, Michael S. Tsirkin wrote: > >> On Thu, Dec 10, 2009 at 07:16:04AM +0200, Muli Ben-Yehuda wrote: >>> On Wed, Dec 09, 2009 at 06:38:54PM +0100, Alexander Graf wrote: >>> While trying to get device passthrough workin

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Alexander Graf
On 10.12.2009, at 10:43, Michael S. Tsirkin wrote: > On Thu, Dec 10, 2009 at 07:16:04AM +0200, Muli Ben-Yehuda wrote: >> On Wed, Dec 09, 2009 at 06:38:54PM +0100, Alexander Graf wrote: >> >>> While trying to get device passthrough working with an emulex hba, >>> kvm refused to pass it through be

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Michael S. Tsirkin
On Thu, Dec 10, 2009 at 07:16:04AM +0200, Muli Ben-Yehuda wrote: > On Wed, Dec 09, 2009 at 06:38:54PM +0100, Alexander Graf wrote: > > > While trying to get device passthrough working with an emulex hba, > > kvm refused to pass it through because it has a BAR of 256 bytes: > > > > Region 0

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-10 Thread Alexander Graf
On 10.12.2009, at 06:16, Muli Ben-Yehuda wrote: > On Wed, Dec 09, 2009 at 06:38:54PM +0100, Alexander Graf wrote: > >> While trying to get device passthrough working with an emulex hba, >> kvm refused to pass it through because it has a BAR of 256 bytes: >> >>Region 0: Memory at d21

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-09 Thread Muli Ben-Yehuda
On Wed, Dec 09, 2009 at 06:38:54PM +0100, Alexander Graf wrote: > While trying to get device passthrough working with an emulex hba, > kvm refused to pass it through because it has a BAR of 256 bytes: > > Region 0: Memory at d210 (64-bit, non-prefetchable) [size=4K] > Region 2:

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-09 Thread Alexander Graf
Am 09.12.2009 um 21:49 schrieb "Michael S. Tsirkin" : On Wed, Dec 09, 2009 at 06:38:54PM +0100, Alexander Graf wrote: While trying to get device passthrough working with an emulex hba, kvm refused to pass it through because it has a BAR of 256 bytes: Region 0: Memory at d210 (64-

Re: [PATCH] Enable non page boundary BAR device assignment

2009-12-09 Thread Michael S. Tsirkin
On Wed, Dec 09, 2009 at 06:38:54PM +0100, Alexander Graf wrote: > While trying to get device passthrough working with an emulex hba, kvm > refused to pass it through because it has a BAR of 256 bytes: > > Region 0: Memory at d210 (64-bit, non-prefetchable) [size=4K] > Region 2:

[PATCH] Enable non page boundary BAR device assignment

2009-12-09 Thread Alexander Graf
While trying to get device passthrough working with an emulex hba, kvm refused to pass it through because it has a BAR of 256 bytes: Region 0: Memory at d210 (64-bit, non-prefetchable) [size=4K] Region 2: Memory at d2101000 (64-bit, non-prefetchable) [size=256] Region 4