qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: George Dunlap <george.dunlap@eu.citrix.com>
To: Stefano Stabellini <stefano.stabellini@eu.citrix.com>,
	Paolo Bonzini <pbonzini@redhat.com>
Cc: peter.maydell@linaro.org, xen-devel@lists.xensource.com,
	Ian Campbell <Ian.Campbell@citrix.com>,
	mst@redhat.com, Ian Jackson <Ian.Jackson@eu.citrix.com>,
	allen.m.kay@intel.com, Kelly.Zytaruk@amd.com,
	Jan Beulich <JBeulich@novell.com>,
	qemu-devel@nongnu.org, yang.z.zhang@intel.com,
	Tim Deegan <tim@xen.org>, Anthony Liguori <anthony@codemonkey.ws>,
	anthony.perard@citrix.com, Tiejun Chen <tiejun.chen@intel.com>,
	George Dunlap <george.dunlap@citrix.com>,
	Konrad Rzeszutek Wilk <konrad@kernel.org>
Subject: Re: [Qemu-devel] [v4][PATCH 2/5] xen, gfx passthrough: create intel isa bridge
Date: Tue, 3 Jun 2014 12:42:44 +0100	[thread overview]
Message-ID: <538DB4B4.6000602@eu.citrix.com> (raw)
In-Reply-To: <alpine.DEB.2.02.1406031203340.4779@kaball.uk.xensource.com>

On 06/03/2014 12:29 PM, Stefano Stabellini wrote:
> On Tue, 3 Jun 2014, Paolo Bonzini wrote:
>> Il 30/05/2014 10:59, Tiejun Chen ha scritto:
>>> +static int create_pch_isa_bridge(PCIBus *bus, XenHostPCIDevice *hdev)
>>> +{
>>> +    struct PCIDevice *dev;
>>> +
>>> +    char rid;
>>> +
>>> +    dev = pci_create(bus, PCI_DEVFN(0x1f, 0), "intel-pch-isa-bridge");
>> This is really a huge hack.  You're going to have two ISA bridge devices in
>> the machine, with the BIOS imagining that the "good" one is at 1f.0 and the
>> ACPI tables actually describing the other one.  But the PCI device at 1f.0
>> remains there and a driver in the OS could catch it---not just
>> intel_detect_pch---and if you want to add such a hack it should be done in the
>> Xen management layers.
>>
>> If possible, the host bridge patches are even worse.  If you change the vendor
>> and device ID while keeping the registers of the i440FX you're going to get
>> conflicts or break firmware badly; TianoCore and SeaBIOS both expect the
>> normal i440FX vendor and device IDs, for example.
>>
>> The hardcoded list of offsets is also not acceptable.  It is also not clear
>> who is accessing the registers, whether the BIOS or the driver. For Linux, a
>> cursory look at the driver shows that it only accesses 0x50/0x52 of the listed
>> offsets, but also 0x44/0x48 ("MCH BAR"), what happens if that code path is
>> encountered?
>>
>> The main problem with IGD passthrough is the incestuous (and that's a
>> euphemism) relationship between the MCH, PCH and graphics driver.  It may make
>> sense at the hardware level, but for virtualization it doesn't.  A
>> virt-specific driver for GPU command passthrough (with aid from the kernel
>> driver, but abstracting all the MCH/PCH-dependent details) would make much
>> more sense.
>>
>> It's really not your fault, there's not much you can do given the hardware
>> architecture.  But I don't think this code can be accepted upstream, sorry.
> Yeah, the code is not nice and it is not Tiejun's fault.
>
> Is there any way at all he could change the patch series to make it more
> appealing to you? Or maybe we could having more clearly separated from
> the rest of the codebase?
>
>
> Otherwise I hate to have to diverge again from upstream QEMU but given
> that we were already carrying these changes in the old
> qemu-xen-traditional tree without issues, I feel that it would be unfair
> for me not to merge them in the upstream based qemu-xen tree.
> Unfortunately I imagine that the lack of this feature could be
> considered a regression for us.
>
> Do the other Xen maintainters have any opinions on this? I would
> appreciate your opinions.

Well my very initial take is to say that it was a mistake to accept the 
IGD stuff into qemu-xen-traditional before making sure that it would be 
suitable for qemu-upstream.  Avoiding having a fork again (or 
maintaining a set of out-of-tree patches) is more important than this 
one feature, IMHO.

When Intel submitted this for qemu-xen-traditional, we should have 
recommended to them at that time to start with qemu-upstream; or, we 
should have made it clear that if they chose to submit it to 
qemu-xen-traditional first, they would be taking the risk of having it 
only be there.  If we didn't warn them of that, that was a mistake on 
our part; but I don't think we can do anything other than apologize.  
(And of course see if there *is* a way to actually get it upstream.)

  -George

  parent reply	other threads:[~2014-06-03 11:43 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1401440369-29929-1-git-send-email-tiejun.chen@intel.com>
     [not found] ` <1401440369-29929-2-git-send-email-tiejun.chen@intel.com>
2014-06-02 14:51   ` [Qemu-devel] [v4][PATCH 1/5] xen, gfx passthrough: basic graphics passthrough support Stefano Stabellini
     [not found] ` <1401440369-29929-3-git-send-email-tiejun.chen@intel.com>
2014-06-02 14:52   ` [Qemu-devel] [v4][PATCH 2/5] xen, gfx passthrough: create intel isa bridge Stefano Stabellini
2014-06-03  8:46   ` Paolo Bonzini
2014-06-03 11:29     ` Stefano Stabellini
2014-06-03 11:39       ` Paolo Bonzini
2014-06-03 11:43         ` Stefano Stabellini
2014-06-03 23:24         ` Tian, Kevin
2014-06-03 11:42       ` George Dunlap [this message]
2014-06-03 12:21         ` [Qemu-devel] [Xen-devel] " Sander Eikelenboom
2014-06-03 12:24           ` Paolo Bonzini
2014-06-03 12:38             ` Sander Eikelenboom
2014-06-06  3:06     ` [Qemu-devel] " Zhang, Yang Z
2014-06-06  6:44       ` Paolo Bonzini
     [not found] ` <1401440369-29929-4-git-send-email-tiejun.chen@intel.com>
2014-06-02 14:53   ` [Qemu-devel] [v4][PATCH 3/5] xen, gfx passthrough: support Intel IGD passthrough with VT-D Stefano Stabellini
     [not found] ` <1401440369-29929-6-git-send-email-tiejun.chen@intel.com>
2014-06-02 14:56   ` [Qemu-devel] [v4][PATCH 5/5] xen, gfx passthrough: add opregion mapping Stefano Stabellini
2014-06-02 14:59 ` [Qemu-devel] [v4][PATCH 0/5] xen: add Intel IGD passthrough support Stefano Stabellini
     [not found] ` <1401440369-29929-5-git-send-email-tiejun.chen@intel.com>
2014-06-02 14:54   ` [Qemu-devel] [v4][PATCH 4/5] xen, gfx passthrough: create host bridge to passthrough Stefano Stabellini
2014-06-02 20:36   ` Michael S. Tsirkin
2014-06-03  1:10     ` Chen, Tiejun

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=538DB4B4.6000602@eu.citrix.com \
    --to=george.dunlap@eu.citrix.com \
    --cc=Ian.Campbell@citrix.com \
    --cc=Ian.Jackson@eu.citrix.com \
    --cc=JBeulich@novell.com \
    --cc=Kelly.Zytaruk@amd.com \
    --cc=allen.m.kay@intel.com \
    --cc=anthony.perard@citrix.com \
    --cc=anthony@codemonkey.ws \
    --cc=george.dunlap@citrix.com \
    --cc=konrad@kernel.org \
    --cc=mst@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.org \
    --cc=stefano.stabellini@eu.citrix.com \
    --cc=tiejun.chen@intel.com \
    --cc=tim@xen.org \
    --cc=xen-devel@lists.xensource.com \
    --cc=yang.z.zhang@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).