All of lore.kernel.org
 help / color / mirror / Atom feed
From: Johannes Weiner <hannes@cmpxchg.org>
To: Chris Wilson <chris@chris-wilson.co.uk>
Cc: linux-mm@kvack.org, intel-gfx@lists.freedesktop.org,
	sourab.gupta@intel.com, Akash Goel <akash.goel@intel.com>
Subject: Re: [PATCH v2] drm/i915: Disable shrinker for non-swapped backed objects
Date: Wed, 25 Nov 2015 15:46:35 -0500	[thread overview]
Message-ID: <20151125204635.GA14536@cmpxchg.org> (raw)
In-Reply-To: <20151125203102.GJ22980@nuc-i3427.alporthouse.com>

On Wed, Nov 25, 2015 at 08:31:02PM +0000, Chris Wilson wrote:
> On Wed, Nov 25, 2015 at 02:06:10PM -0500, Johannes Weiner wrote:
> > On Wed, Nov 25, 2015 at 06:36:56PM +0000, Chris Wilson wrote:
> > > +static bool swap_available(void)
> > > +{
> > > +	return total_swap_pages || frontswap_enabled;
> > > +}
> > 
> > If you use get_nr_swap_pages() instead of total_swap_pages, this will
> > also stop scanning objects once the swap space is full. We do that in
> > the VM to stop scanning anonymous pages.
> 
> Thanks. Would EXPORT_SYMBOL_GPL(nr_swap_pages) (or equivalent) be
> acceptable?

No opposition from me. Just please add a small comment that this is
for shrinkers with swappable objects.
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

WARNING: multiple messages have this Message-ID (diff)
From: Johannes Weiner <hannes@cmpxchg.org>
To: Chris Wilson <chris@chris-wilson.co.uk>
Cc: intel-gfx@lists.freedesktop.org, linux-mm@kvack.org,
	Akash Goel <akash.goel@intel.com>,
	sourab.gupta@intel.com
Subject: Re: [PATCH v2] drm/i915: Disable shrinker for non-swapped backed objects
Date: Wed, 25 Nov 2015 15:46:35 -0500	[thread overview]
Message-ID: <20151125204635.GA14536@cmpxchg.org> (raw)
In-Reply-To: <20151125203102.GJ22980@nuc-i3427.alporthouse.com>

On Wed, Nov 25, 2015 at 08:31:02PM +0000, Chris Wilson wrote:
> On Wed, Nov 25, 2015 at 02:06:10PM -0500, Johannes Weiner wrote:
> > On Wed, Nov 25, 2015 at 06:36:56PM +0000, Chris Wilson wrote:
> > > +static bool swap_available(void)
> > > +{
> > > +	return total_swap_pages || frontswap_enabled;
> > > +}
> > 
> > If you use get_nr_swap_pages() instead of total_swap_pages, this will
> > also stop scanning objects once the swap space is full. We do that in
> > the VM to stop scanning anonymous pages.
> 
> Thanks. Would EXPORT_SYMBOL_GPL(nr_swap_pages) (or equivalent) be
> acceptable?

No opposition from me. Just please add a small comment that this is
for shrinkers with swappable objects.

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

  reply	other threads:[~2015-11-25 20:46 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-23  9:20 [PATCH] drm/i915: Disable shrinker for non-swapped backed objects Chris Wilson
2015-11-24 17:15 ` Daniel Vetter
2015-11-24 23:17   ` Chris Wilson
2015-11-25  9:17     ` Daniel Vetter
2015-11-25  9:58       ` Chris Wilson
2015-11-25 13:36         ` Goel, Akash
2015-11-26  9:34         ` Daniel Vetter
2015-11-26 10:30           ` Chris Wilson
2015-11-26 11:36             ` Daniel Vetter
2015-11-25 18:36     ` [PATCH v2] " Chris Wilson
2015-11-25 18:53       ` Chris Wilson
2015-11-25 18:53         ` Chris Wilson
2015-11-25 19:06       ` Johannes Weiner
2015-11-25 20:31         ` Chris Wilson
2015-11-25 20:46           ` Johannes Weiner [this message]
2015-11-25 20:46             ` Johannes Weiner
2015-11-26 11:25             ` Chris Wilson
2015-11-26 15:40               ` Johannes Weiner
2015-11-26 15:40                 ` Johannes Weiner

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=20151125204635.GA14536@cmpxchg.org \
    --to=hannes@cmpxchg.org \
    --cc=akash.goel@intel.com \
    --cc=chris@chris-wilson.co.uk \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=linux-mm@kvack.org \
    --cc=sourab.gupta@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.