From: Daniel Vetter <daniel@ffwll.ch>
To: Thomas Daniel <thomas.daniel@intel.com>
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH v5 3/4] drm/i915/bdw: Pin the context backing objects to GGTT on-demand
Date: Mon, 24 Nov 2014 15:24:32 +0100 [thread overview]
Message-ID: <20141124142432.GS25711@phenom.ffwll.local> (raw)
In-Reply-To: <1415874490-386-1-git-send-email-thomas.daniel@intel.com>
On Thu, Nov 13, 2014 at 10:28:10AM +0000, Thomas Daniel wrote:
> From: Oscar Mateo <oscar.mateo@intel.com>
>
> Up until now, we have pinned every logical ring context backing object
> during creation, and left it pinned until destruction. This made my life
> easier, but it's a harmful thing to do, because we cause fragmentation
> of the GGTT (and, eventually, we would run out of space).
>
> This patch makes the pinning on-demand: the backing objects of the two
> contexts that are written to the ELSP are pinned right before submission
> and unpinned once the hardware is done with them. The only context that
> is still pinned regardless is the global default one, so that the HWS can
> still be accessed in the same way (ring->status_page).
>
> v2: In the early version of this patch, we were pinning the context as
> we put it into the ELSP: on the one hand, this is very efficient because
> only a maximum two contexts are pinned at any given time, but on the other
> hand, we cannot really pin in interrupt time :(
>
> v3: Use a mutex rather than atomic_t to protect pin count to avoid races.
> Do not unpin default context in free_request.
>
> v4: Break out pin and unpin into functions. Fix style problems reported
> by checkpatch
>
> v5: Remove unpin_lock as all pinning and unpinning is done with the struct
> mutex already locked. Add WARN_ONs to make sure this is the case in future.
>
> Issue: VIZ-4277
> Signed-off-by: Oscar Mateo <oscar.mateo@intel.com>
> Signed-off-by: Thomas Daniel <thomas.daniel@intel.com>
This patch here scored a regression (leak in the module unload path),
please address it asap. Deadline for regressions should be 1 week, then
I'll just drop the patch or apply the revert. That includes review and
everything.
https://bugs.freedesktop.org/show_bug.cgi?id=86507
Thanks,
--
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2014-11-24 14:24 UTC|newest]
Thread overview: 42+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-10-29 9:52 [PATCH 1/4] drm/i915/bdw: Clean up execlist queue items in retire_work Thomas Daniel
2014-10-29 9:52 ` [PATCH 2/4] drm/i915/bdw: Setup global hardware status page in execlists mode Thomas Daniel
2014-11-03 15:47 ` Daniel Vetter
2014-10-29 9:52 ` [PATCH 3/4] drm/i915/bdw: Pin the context backing objects to GGTT on-demand Thomas Daniel
2014-11-03 16:54 ` Daniel Vetter
2014-11-03 17:00 ` Daniel, Thomas
2014-11-03 17:11 ` Daniel Vetter
2014-11-03 21:04 ` Chris Wilson
2014-11-13 10:28 ` [PATCH v5 " Thomas Daniel
2014-11-17 14:38 ` akash goel
2014-11-17 14:55 ` Daniel, Thomas
2014-11-19 17:59 ` Daniel, Thomas
2014-11-17 18:09 ` Daniel Vetter
2014-11-18 9:27 ` Daniel, Thomas
2014-11-18 10:48 ` Daniel, Thomas
2014-11-18 14:33 ` Daniel Vetter
2014-11-18 14:51 ` Daniel, Thomas
2014-11-18 15:11 ` Daniel Vetter
2014-11-18 15:32 ` Daniel, Thomas
2014-11-19 9:53 ` Daniel Vetter
2014-11-18 6:40 ` Deepak S
2014-11-17 14:23 ` Daniel Vetter
2014-11-18 14:27 ` Deepak S
2014-11-24 14:24 ` Daniel Vetter [this message]
2014-11-24 17:14 ` Daniel, Thomas
2014-11-24 20:15 ` Daniel Vetter
2014-10-29 9:52 ` [PATCH 4/4] drm/i915/bdw: Pin the ringbuffer backing object " Thomas Daniel
2014-10-29 14:38 ` [PATCH 4/4] drm/i915/bdw: Pin the ringbuffer backing shuang.he
2014-11-13 10:28 ` [PATCH v5 4/4] drm/i915/bdw: Pin the ringbuffer backing object to GGTT on-demand Thomas Daniel
2014-11-18 5:18 ` akash goel
2014-11-18 6:37 ` Deepak S
2014-11-18 6:39 ` Deepak S
2014-11-17 14:29 ` Daniel Vetter
2014-11-18 14:30 ` Deepak S
2014-11-03 15:33 ` [PATCH 1/4] drm/i915/bdw: Clean up execlist queue items in retire_work Daniel Vetter
2014-11-03 16:05 ` Daniel, Thomas
2014-11-03 16:17 ` Daniel Vetter
2014-11-04 9:11 ` Chris Wilson
2014-11-07 14:55 ` [PATCH v4 " Thomas Daniel
2014-11-13 10:27 ` [PATCH v5 " Thomas Daniel
2014-11-18 6:29 ` Deepak S
2014-11-17 14:41 ` akash goel
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=20141124142432.GS25711@phenom.ffwll.local \
--to=daniel@ffwll.ch \
--cc=intel-gfx@lists.freedesktop.org \
--cc=thomas.daniel@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.