Re: [virtio-dev] Re: [PATCH] Add virtio gpu driver.
It's not about virtio at all. It's about vga compatibility, so we have a simple framebuffer as boot display. Only used when virtio is *not* enabled. VGA can be a separate device altogether. In fact there were *real* PCI graphics cards that did this and had a register than flipped the output source over. Alan ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization
Re: [virtio-dev] Re: [PATCH] Add virtio gpu driver.
Hi, Completely different thing crossing my mind: I think we can make virtio-vga fully compatible with stdvga. stdvga has two bars, memory (#0) and mmio (#2). We can make the mmio bar larger and place all the virtio regions there. Full compatibility with some standard sounds like a better motivation, yes. Ok, I'll look into it. I think in any case I'll go split off the vga compatibility bits to a different patch (and possible a separate patch series). cheers, Gerd Will you still need me to change core to claim specific memory only? That would be great, yes. The resource conflict with vesafb/efifb will stay no matter how we design the pci resource layout of virtio-vga. cheers, Gerd ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization
Re: [virtio-dev] Re: [PATCH] Add virtio gpu driver.
Hi, And is it possible to use offset within BAR and/or memory BARs? If yes I'd strongly prefer this. What is the point? Do you want place virtio regions and vga framebuffer in the same pci bar? Why? virtio is mmio and traps into qemu on access, whereas the vga framebuffer is memory-backed (with dirty tracking turned on). Don't think this is a good idea, even though the memory api would probably allow to do this. cheers, Gerd ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization
Re: [virtio-dev] Re: [PATCH] Add virtio gpu driver.
On Thu, Mar 26, 2015 at 09:42:47AM +0100, Gerd Hoffmann wrote: Hi, And is it possible to use offset within BAR and/or memory BARs? If yes I'd strongly prefer this. What is the point? Do you want place virtio regions and vga framebuffer in the same pci bar? Why? virtio is mmio and traps into qemu on access, whereas the vga framebuffer is memory-backed (with dirty tracking turned on). Don't think this is a good idea, even though the memory api would probably allow to do this. cheers, Gerd Absolutely, it's pretty common to mix regions in a BAR. For example, we have virtio kick (ioeventfd backed, handled in kernel) in same BAR as common and device specific configuration. We did the same thing you are now doing with the virtio BAR, and now we have to maintain two code bases, virtio pci config was designed to be future proof so why not use it? This is mostly just making sure we don't paint ourselves into a corner. -- MST ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization
Re: [virtio-dev] Re: [PATCH] Add virtio gpu driver.
On Thu, Mar 26, 2015 at 12:38:43PM +0100, Gerd Hoffmann wrote: Hi, Absolutely, it's pretty common to mix regions in a BAR. For example, we have virtio kick (ioeventfd backed, handled in kernel) in same BAR as common and device specific configuration. We did the same thing you are now doing with the virtio BAR, and now we have to maintain two code bases, virtio pci config was designed to be future proof so why not use it? It's not about virtio at all. It's about vga compatibility, so we have a simple framebuffer as boot display. Only used when virtio is *not* enabled. I don't know. This seems exactly like the kind of thing we had in mind when we added the virtio pci capability. For example, we have text in spec that requires drivers to skip unknown capabilities. And yes, if bios pokes at a specific bar then we do need to list this info in the virtio spec so this makes it an issue that is virtio related. This is mostly just making sure we don't paint ourselves into a corner. It's a simple memory bar. vga cards have that since pci was invented (standalone ones, chipset graphics aside), and there havn't been fundamental changes ... cheers, Gerd Yes, it's not about what we put there now. It's about being able to move things about in the future without breaking guests. -- MST ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization
Re: [virtio-dev] Re: [PATCH] Add virtio gpu driver.
Hi, Absolutely, it's pretty common to mix regions in a BAR. For example, we have virtio kick (ioeventfd backed, handled in kernel) in same BAR as common and device specific configuration. We did the same thing you are now doing with the virtio BAR, and now we have to maintain two code bases, virtio pci config was designed to be future proof so why not use it? It's not about virtio at all. It's about vga compatibility, so we have a simple framebuffer as boot display. Only used when virtio is *not* enabled. This is mostly just making sure we don't paint ourselves into a corner. It's a simple memory bar. vga cards have that since pci was invented (standalone ones, chipset graphics aside), and there havn't been fundamental changes ... cheers, Gerd ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization
Re: [virtio-dev] Re: [PATCH] Add virtio gpu driver.
On Thu, Mar 26, 2015 at 04:07:16PM +0100, Gerd Hoffmann wrote: Hi, I don't know. This seems exactly like the kind of thing we had in mind when we added the virtio pci capability. For example, we have text in spec that requires drivers to skip unknown capabilities. And yes, if bios pokes at a specific bar then we do need to list this info in the virtio spec so this makes it an issue that is virtio related. Hmm, virtio-vga is a two-in-one device basically. When virtio is enabled it behaves like virtio-gpu-pci, otherwise it behaves very simliar to stdvga. So you need to know nothing about virtio to handle the vga side, and I want keep it that way. When no vga compatibility is needed there always is the option to just use virtio-gpu-pci instead. Yes, it's not about what we put there now. It's about being able to move things about in the future without breaking guests. We don't have that today for stdvga, and I still fail to see what this buys us. Completely different thing crossing my mind: I think we can make virtio-vga fully compatible with stdvga. stdvga has two bars, memory (#0) and mmio (#2). We can make the mmio bar larger and place all the virtio regions there. Full compatibility with some standard sounds like a better motivation, yes. I think in any case I'll go split off the vga compatibility bits to a different patch (and possible a separate patch series). cheers, Gerd Will you still need me to change core to claim specific memory only? -- MST ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization
Re: [virtio-dev] Re: [PATCH] Add virtio gpu driver.
Hi, I don't know. This seems exactly like the kind of thing we had in mind when we added the virtio pci capability. For example, we have text in spec that requires drivers to skip unknown capabilities. And yes, if bios pokes at a specific bar then we do need to list this info in the virtio spec so this makes it an issue that is virtio related. Hmm, virtio-vga is a two-in-one device basically. When virtio is enabled it behaves like virtio-gpu-pci, otherwise it behaves very simliar to stdvga. So you need to know nothing about virtio to handle the vga side, and I want keep it that way. When no vga compatibility is needed there always is the option to just use virtio-gpu-pci instead. Yes, it's not about what we put there now. It's about being able to move things about in the future without breaking guests. We don't have that today for stdvga, and I still fail to see what this buys us. Completely different thing crossing my mind: I think we can make virtio-vga fully compatible with stdvga. stdvga has two bars, memory (#0) and mmio (#2). We can make the mmio bar larger and place all the virtio regions there. I think in any case I'll go split off the vga compatibility bits to a different patch (and possible a separate patch series). cheers, Gerd ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization