qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Peter Xu <peterx@redhat.com>
To: Rita Sinha <rita.sinha89@gmail.com>
Cc: Jan Kiszka <jan.kiszka@siemens.com>, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH 2/2] i386: Interrupt remapping support for VT-d
Date: Thu, 10 Mar 2016 13:28:46 +0800	[thread overview]
Message-ID: <20160310052846.GB25832@pxdev.xzpeter.org> (raw)
In-Reply-To: <1457465297-15154-1-git-send-email-rita.sinha89@gmail.com>

On Wed, Mar 09, 2016 at 12:58:17AM +0530, Rita Sinha wrote:
> From: Jan Kiszka <jan.kiszka@siemens.com>
> 
> Still a bit hacky, unconditionally enabled (must become opt-in, not
> available with in-kernel irqchip), not reporting faults properly - but
> it works! And revealed a Linux bug [1]

If the patch is to be merged finally, shall we better add a
parameter to disable this feature for people do not need this?
Also, shall we make sure:

- make sure patches' in-reply-to are correct (so that it's in a
  series, as mentioned by Eric before)
- remove useless lines like "/* printf(...) */"
- add one-line subject for each patch (possibly)?
- ...

[...]

> diff --git a/hw/pci-host/q35.c b/hw/pci-host/q35.c
> index 566e3d8..f7adc8e 100644
> --- a/hw/pci-host/q35.c
> +++ b/hw/pci-host/q35.c
> @@ -431,6 +431,17 @@ static AddressSpace *q35_host_dma_iommu(PCIBus *bus, void *opaque, int devfn)
>      assert(0 <= devfn && devfn <= VTD_PCI_DEVFN_MAX);
>  
>      vtd_as = vtd_find_add_as(s, bus, devfn);
> +
> +    memory_region_init_iommu(&vtd_as->iommu, OBJECT(s),
> +                             &s->iommu_ops, "intel_iommu", UINT64_MAX);
> +    address_space_init(&vtd_as->as,
> +                             &vtd_as->iommu, "intel_iommu");
> +    memory_region_init_io(&vtd_as->int_remap_region, OBJECT(s),
> +                             &vtd_int_remap_ops, vtd_as,
> +                             "intel_int_remap", UINT64_MAX);
> +    address_space_init(&vtd_as->int_remap_as,
> +                             &vtd_as->int_remap_region,
> +                             "intel_int_remap");

One more thing... vtd_as->{as|iommu} should have been inited in
vtd_find_add_as() already.

Peter

  reply	other threads:[~2016-03-10  5:29 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-08 19:28 [Qemu-devel] [PATCH 2/2] i386: Interrupt remapping support for VT-d Rita Sinha
2016-03-10  5:28 ` Peter Xu [this message]
2016-03-11  7:28   ` Jan Kiszka

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=20160310052846.GB25832@pxdev.xzpeter.org \
    --to=peterx@redhat.com \
    --cc=jan.kiszka@siemens.com \
    --cc=qemu-devel@nongnu.org \
    --cc=rita.sinha89@gmail.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).