All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chris Wilson <chris@chris-wilson.co.uk>
To: "Bloomfield, Jon" <jon.bloomfield@intel.com>,
	"intel-gfx@lists.freedesktop.org"
	<intel-gfx@lists.freedesktop.org>,
	Abdiel Janulgue <abdiel.janulgue@linux.intel.com>
Cc: "Auld, Matthew" <matthew.auld@intel.com>
Subject: Re: [PATCH v2 3/5] drm/i915: Introduce DRM_I915_GEM_MMAP_OFFSET
Date: Mon, 07 Oct 2019 21:16:29 +0100	[thread overview]
Message-ID: <157047938955.5063.12889178651560443170@skylake-alporthouse-com> (raw)
In-Reply-To: <AD48BB7FB99B174FBCC69E228F58B3B68CE6C156@fmsmsx120.amr.corp.intel.com>

Quoting Bloomfield, Jon (2019-10-07 17:55:16)
> > -----Original Message-----
> > From: Intel-gfx <intel-gfx-bounces@lists.freedesktop.org> On Behalf Of Abdiel
> > Janulgue
> > Sent: Monday, October 7, 2019 2:19 AM
> > To: intel-gfx@lists.freedesktop.org
> > Cc: Auld, Matthew <matthew.auld@intel.com>
> > Subject: [Intel-gfx] [PATCH v2 3/5] drm/i915: Introduce
> > DRM_I915_GEM_MMAP_OFFSET
> > 
> > This is really just an alias of mmap_gtt. Add a new CPU mmap
> > implementation that allows multiple fault handlers that depends on
> > the object's backing pages.
> > 
> > Note that we multiplex mmap_gtt and mmap_offset through the same ioctl,
> > and use the zero extending behaviour of drm to differentiate between
> > them, when we inspect the flags.
> > 
> > Signed-off-by: Abdiel Janulgue <abdiel.janulgue@linux.intel.com>
> > Signed-off-by: Matthew Auld <matthew.auld@intel.com>
> > Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> > ---
> >  drivers/gpu/drm/i915/gem/i915_gem_mman.c      | 36 +++++++++++++++++--
> >  .../gpu/drm/i915/gem/i915_gem_object_types.h  |  3 ++
> >  drivers/gpu/drm/i915/i915_drv.c               |  2 +-
> >  include/uapi/drm/i915_drm.h                   | 28 +++++++++++++++
> >  4 files changed, 66 insertions(+), 3 deletions(-)
> 
> How does the label 'offset' fit into this API if it's really about multiple fault handlers?
> Could do with a much better description here I think. Who would use this, and why, would help a lot.

The ioctl returns the offset into the device fd userpace uses with
mmap(2). Hence DRM_IOCTL_I915_GEM_MMAP_OFFSET.
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  reply	other threads:[~2019-10-07 20:16 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-10-07  9:19 [PATCH v2 1/5] drm/i915: Allow i915 to manage the vma offset nodes instead of drm core Abdiel Janulgue
2019-10-07  9:19 ` [PATCH v2 2/5] drm/i915: define HAS_MAPPABLE_APERTURE Abdiel Janulgue
2019-10-07  9:19 ` [PATCH v2 3/5] drm/i915: Introduce DRM_I915_GEM_MMAP_OFFSET Abdiel Janulgue
2019-10-07  9:56   ` Chris Wilson
2019-10-07  9:58   ` Chris Wilson
2019-10-07  9:59   ` Chris Wilson
2019-10-07 10:01   ` Chris Wilson
2019-10-07 16:55   ` Bloomfield, Jon
2019-10-07 20:16     ` Chris Wilson [this message]
2019-10-07 20:17       ` Chris Wilson
2019-10-07  9:19 ` [PATCH v2 4/5] drm/i915: cpu-map based dumb buffers Abdiel Janulgue
2019-10-07 10:04   ` Chris Wilson
2019-10-07  9:19 ` [PATCH v2 5/5] drm/i915: Add cpu fault handler for mmap_offset Abdiel Janulgue
2019-10-07 10:10   ` Chris Wilson
2019-10-07 10:20   ` Chris Wilson
2019-10-07  9:25 ` ✗ Fi.CI.CHECKPATCH: warning for series starting with [v2,1/5] drm/i915: Allow i915 to manage the vma offset nodes instead of drm core Patchwork
2019-10-07  9:41 ` [PATCH v2 1/5] " Chris Wilson
2019-10-07  9:49 ` ✓ Fi.CI.BAT: success for series starting with [v2,1/5] " Patchwork
2019-10-07 11:17 ` ✓ Fi.CI.IGT: " Patchwork
  -- strict thread matches above, loose matches on Subject: below --
2019-08-26 12:20 [PATCH 1/5] " Abdiel Janulgue
2019-10-07  8:48 ` [PATCH v2 " Abdiel Janulgue
2019-10-07  8:48   ` [PATCH v2 3/5] drm/i915: Introduce DRM_I915_GEM_MMAP_OFFSET Abdiel Janulgue

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=157047938955.5063.12889178651560443170@skylake-alporthouse-com \
    --to=chris@chris-wilson.co.uk \
    --cc=abdiel.janulgue@linux.intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=jon.bloomfield@intel.com \
    --cc=matthew.auld@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.