From: Ben Widawsky <benjamin.widawsky@intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>, intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH] drm/i915: VM eviction only targets address space not physical pages
Date: Wed, 29 Jan 2014 12:06:36 -0800 [thread overview]
Message-ID: <20140129200636.GA31282@intel.com> (raw)
In-Reply-To: <1390932518-3893-1-git-send-email-chris@chris-wilson.co.uk>
On Tue, Jan 28, 2014 at 06:08:38PM +0000, Chris Wilson wrote:
> During eviction, we are only considering how to free up space within the
> current address space and not concerned with freeing up physical memory.
> As such we need only skip nodes that pinned in the current VM and not
> globally.
>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
> Cc: Ben Widawsky <benjamin.widawsky@intel.com>
Can you rename i915_gem_evict_something() or add a comment at the top
that the function is not used by the shrinker, and is for evicting a VM?
The comment we currently have in the function doesn't suggest this at
all.
Reviewed-by: Ben Widawsky <ben@bwidawsk.net>
> ---
> drivers/gpu/drm/i915/i915_gem_evict.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/i915_gem_evict.c b/drivers/gpu/drm/i915/i915_gem_evict.c
> index 525b242ac512..a745966b7e16 100644
> --- a/drivers/gpu/drm/i915/i915_gem_evict.c
> +++ b/drivers/gpu/drm/i915/i915_gem_evict.c
> @@ -36,8 +36,7 @@
> static bool
> mark_free(struct i915_vma *vma, struct list_head *unwind)
> {
> - /* Freeing up memory requires no VMAs are pinned */
> - if (i915_gem_obj_is_pinned(vma->obj))
> + if (vma->pin_count)
> return false;
>
> if (WARN_ON(!list_empty(&vma->exec_list)))
> --
> 1.8.5.3
>
--
Ben Widawsky, Intel Open Source Technology Center
next prev parent reply other threads:[~2014-01-29 20:06 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-28 18:08 [PATCH] drm/i915: VM eviction only targets address space not physical pages Chris Wilson
2014-01-29 20:06 ` Ben Widawsky [this message]
2014-01-29 21:19 ` Daniel Vetter
2014-01-29 21:55 ` Chris Wilson
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=20140129200636.GA31282@intel.com \
--to=benjamin.widawsky@intel.com \
--cc=chris@chris-wilson.co.uk \
--cc=daniel.vetter@ffwll.ch \
--cc=intel-gfx@lists.freedesktop.org \
/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.