qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Alex Williamson <alex.williamson@redhat.com>
To: Zhi Wang <zhi.a.wang@intel.com>
Cc: qemu-devel@nongnu.org, kevin.tian@intel.com,
	daniel.vetter@ffwll.ch, joonas.lahtinen@linux.intel.com,
	zhenyuw@linux.intel.com, zhiyuan.lv@intel.com,
	chuanxiao.dong@intel.com, xiong.y.zhang@intel.com
Subject: Re: [Qemu-devel] [RFC 1/6] vfio: Add Intel platform definitions
Date: Thu, 1 Jun 2017 14:22:00 -0600	[thread overview]
Message-ID: <20170601142200.0a733c56@w520.home> (raw)
In-Reply-To: <1496079043-26694-9-git-send-email-zhi.a.wang@intel.com>

On Tue, 30 May 2017 01:30:38 +0800
Zhi Wang <zhi.a.wang@intel.com> wrote:

> This patch introduces device descriptions for Intel platforms. Most of
> the Intel device definitions come from i915.
> 
> Suggested-by: Xiong Zhang <xiong.y.zhang@intel.com>
> Signed-off-by: Zhi Wang <zhi.a.wang@intel.com>
> ---
>  hw/vfio/Makefile.objs    |   2 +-
>  hw/vfio/intel-platform.c | 366 +++++++++++++++++++++++++++++++++++++++++++++++
>  hw/vfio/intel-platform.h |  38 +++++
>  hw/vfio/pci-quirks.c     |  28 ++--
>  4 files changed, 421 insertions(+), 13 deletions(-)
>  create mode 100644 hw/vfio/intel-platform.c
>  create mode 100644 hw/vfio/intel-platform.h

Thanks to IGD hardware designers seeing fit to change the
implementation on a whim, this has a non-trivial future maintenance
burden.  Is Intel signing up to support this?  I would suggest being
overly explicit with where each define and function lives in the Linux
kernel so that it doesn't take a great deal of research to lift new
defines here.  Extra points if we could simply include Linux kernel
headers in a way to pick them up automatically.

Along those same lines, there's a subtle behavior change here where
igd_gen() hopes that Intel is eventually converging on a stable layout
and therefore assumes newer devices are compatible with the latest
version we know about.  That's removed here, so it seems we'll always
be trailing the latest hardware.  The comment:

> +        error_report("IGD device %s is unsupported in legacy mode, "
> +                     "try SandyBridge or newer", vdev->vbasedev.name);

is also really no longer accurate.  igd_gen() had code to match older
hardware as specifically unsupported vs only unknown (and assumed to be
supported using the newest generation we know about).  Now the unknown
device could be new or old, so suggesting SandyBridge or newer isn't
helpful advice for a user.

Why "intel-platform"?  Maybe this is subtly trying to indicate that IGD
is really a broken mix of PCI and "platform" devices since it's PCI yet
relies on various non-PCI resources, like stolen memory.  In any case,
it's a bit confusing from a vfio perspective.  Perhaps pci-igd?  Thanks,

Alex

  reply	other threads:[~2017-06-01 20:22 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-29 17:30 [Qemu-devel] [RFC 0/6] Refine IGD stolen memory support in VFIO Zhi Wang
2017-05-29  8:29 ` Zhi Wang
2017-05-31 22:13   ` Wang, Zhi A
2017-05-29  8:43 ` no-reply
2017-05-29  8:45 ` no-reply
2017-05-29  8:50 ` no-reply
2017-05-29 17:30 ` [Qemu-devel] [RFC 1/6] vfio: Add Intel platform definitions Zhi Wang
2017-05-29 17:30 ` [Qemu-devel] [RFC 2/6] vfio: Setup IGD quirks earlier Zhi Wang
2017-06-01 20:34   ` Alex Williamson
2017-05-29 17:30 ` [Qemu-devel] [RFC 3/6] vfio: Setup IGD stolen memory Zhi Wang
2017-06-01 21:10   ` Alex Williamson
2017-05-29 17:30 ` [Qemu-devel] [RFC 4/6] vfio: Refine GGTT clearing Zhi Wang
2017-05-29 17:30 ` [Qemu-devel] [RFC 5/6] vfio: Remove extra quirks and old definitions Zhi Wang
2017-05-29 17:30 ` [Qemu-devel] [RFC 6/6] vfio: Setup IGD stolen memory under secondary mode Zhi Wang
2017-05-29 17:30 ` [Qemu-devel] [RFC 0/6] Refine IGD stolen memory support in VFIO Zhi Wang
2017-06-01  2:52   ` Tian, Kevin
2017-05-29 17:30 ` [Qemu-devel] [RFC 1/6] vfio: Add Intel platform definitions Zhi Wang
2017-06-01 20:22   ` Alex Williamson [this message]
2017-05-29 17:30 ` [Qemu-devel] [RFC 2/6] vfio: Setup IGD quirks earlier Zhi Wang
2017-05-29 17:30 ` [Qemu-devel] [RFC 3/6] vfio: Setup IGD stolen memory Zhi Wang
2017-05-29 17:30 ` [Qemu-devel] [RFC 4/6] vfio: Refine GGTT clearing Zhi Wang
2017-05-29 17:30 ` [Qemu-devel] [RFC 5/6] vfio: Remove extra quirks and old definitions Zhi Wang
2017-05-29 17:30 ` [Qemu-devel] [RFC 6/6] vfio: Setup IGD stolen memory under secondary mode Zhi Wang

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=20170601142200.0a733c56@w520.home \
    --to=alex.williamson@redhat.com \
    --cc=chuanxiao.dong@intel.com \
    --cc=daniel.vetter@ffwll.ch \
    --cc=joonas.lahtinen@linux.intel.com \
    --cc=kevin.tian@intel.com \
    --cc=qemu-devel@nongnu.org \
    --cc=xiong.y.zhang@intel.com \
    --cc=zhenyuw@linux.intel.com \
    --cc=zhi.a.wang@intel.com \
    --cc=zhiyuan.lv@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).