All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chris Wilson <chris@chris-wilson.co.uk>
To: Andrea Arcangeli <aarcange@redhat.com>
Cc: Martin Kepplinger <martink@posteo.de>,
	Thorsten Leemhuis <regressions@leemhuis.info>,
	daniel.vetter@intel.com, Dave Airlie <airlied@gmail.com>,
	intel-gfx@lists.freedesktop.org, linux-kernel@vger.kernel.org,
	dri-devel@lists.freedesktop.org
Subject: Re: [PATCH 2/5] i915: flush gem obj freeing workqueues to add accuracy to the i915 shrinker
Date: Fri, 7 Apr 2017 11:02:11 +0100	[thread overview]
Message-ID: <20170407100211.GG10496@nuc-i3427.alporthouse.com> (raw)
In-Reply-To: <20170406232347.988-3-aarcange@redhat.com>

On Fri, Apr 07, 2017 at 01:23:44AM +0200, Andrea Arcangeli wrote:
> Waiting a RCU grace period only guarantees the work gets queued, but
> until after the queued workqueue returns, there's no guarantee the
> memory was actually freed. So flush the work to provide better
> guarantees to the reclaim code in addition of waiting a RCU grace
> period to pass.

We are not allowed to call flush_work() from the shrinker, the workqueue
doesn't have and can't have the right reclaim flags.
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre

WARNING: multiple messages have this Message-ID (diff)
From: Chris Wilson <chris@chris-wilson.co.uk>
To: Andrea Arcangeli <aarcange@redhat.com>
Cc: intel-gfx@lists.freedesktop.org, linux-kernel@vger.kernel.org,
	dri-devel@lists.freedesktop.org,
	Thorsten Leemhuis <regressions@leemhuis.info>,
	Martin Kepplinger <martink@posteo.de>,
	daniel.vetter@intel.com
Subject: Re: [PATCH 2/5] i915: flush gem obj freeing workqueues to add accuracy to the i915 shrinker
Date: Fri, 7 Apr 2017 11:02:11 +0100	[thread overview]
Message-ID: <20170407100211.GG10496@nuc-i3427.alporthouse.com> (raw)
In-Reply-To: <20170406232347.988-3-aarcange@redhat.com>

On Fri, Apr 07, 2017 at 01:23:44AM +0200, Andrea Arcangeli wrote:
> Waiting a RCU grace period only guarantees the work gets queued, but
> until after the queued workqueue returns, there's no guarantee the
> memory was actually freed. So flush the work to provide better
> guarantees to the reclaim code in addition of waiting a RCU grace
> period to pass.

We are not allowed to call flush_work() from the shrinker, the workqueue
doesn't have and can't have the right reclaim flags.
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  reply	other threads:[~2017-04-07 10:02 UTC|newest]

Thread overview: 41+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-22  8:38 [BUG][REGRESSION] i915 gpu hangs under load Martin Kepplinger
2017-03-22 10:36 ` [Intel-gfx] " Jani Nikula
2017-03-22 10:36   ` Jani Nikula
2017-04-02 11:50   ` [Intel-gfx] " Thorsten Leemhuis
2017-04-02 11:50     ` Thorsten Leemhuis
2017-04-02 12:13     ` [Intel-gfx] " Martin Kepplinger
2017-04-02 12:13       ` Martin Kepplinger
2017-04-03 15:09       ` [Intel-gfx] " Jani Nikula
2017-04-03 15:09         ` Jani Nikula
2017-04-06 23:23         ` [PATCH 0/5] " Andrea Arcangeli
2017-04-06 23:23           ` [PATCH 0/5] " Andrea Arcangeli
2017-04-06 23:23           ` [PATCH 1/5] i915: avoid kernel hang caused by synchronize rcu struct_mutex deadlock Andrea Arcangeli
2017-04-06 23:23             ` Andrea Arcangeli
2017-04-07  9:05             ` [Intel-gfx] " Joonas Lahtinen
2017-04-07  9:05               ` Joonas Lahtinen
2017-04-06 23:23           ` [PATCH 2/5] i915: flush gem obj freeing workqueues to add accuracy to the i915 shrinker Andrea Arcangeli
2017-04-06 23:23             ` Andrea Arcangeli
2017-04-07 10:02             ` Chris Wilson [this message]
2017-04-07 10:02               ` Chris Wilson
2017-04-07 13:06               ` Andrea Arcangeli
2017-04-07 13:06                 ` Andrea Arcangeli
2017-04-07 15:30                 ` Chris Wilson
2017-04-07 15:30                   ` Chris Wilson
2017-04-07 16:48                   ` Andrea Arcangeli
2017-04-07 16:48                     ` Andrea Arcangeli
2017-04-10  9:39                     ` Chris Wilson
2017-04-10  9:39                       ` Chris Wilson
2017-04-06 23:23           ` [PATCH 3/5] i915: initialize the free_list of the fencing atomic_helper Andrea Arcangeli
2017-04-06 23:23             ` Andrea Arcangeli
2017-04-07 10:35             ` Chris Wilson
2017-04-07 10:35               ` Chris Wilson
2017-04-06 23:23           ` [PATCH 4/5] i915: schedule while freeing the lists of gem objects Andrea Arcangeli
2017-04-06 23:23             ` Andrea Arcangeli
2017-04-06 23:23           ` [PATCH 5/5] i915: fence workqueue optimization Andrea Arcangeli
2017-04-06 23:23             ` Andrea Arcangeli
2017-04-07  9:58             ` Chris Wilson
2017-04-07  9:58               ` Chris Wilson
2017-04-07 13:13               ` Andrea Arcangeli
2017-04-07 13:13                 ` Andrea Arcangeli
2017-04-10 10:15           ` [PATCH 0/5] Re: [Intel-gfx] [BUG][REGRESSION] i915 gpu hangs under load Martin Kepplinger
2017-04-10 10:15             ` [PATCH 0/5] " Martin Kepplinger

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=20170407100211.GG10496@nuc-i3427.alporthouse.com \
    --to=chris@chris-wilson.co.uk \
    --cc=aarcange@redhat.com \
    --cc=airlied@gmail.com \
    --cc=daniel.vetter@intel.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=martink@posteo.de \
    --cc=regressions@leemhuis.info \
    /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.