<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/gpu/drm/i915/intel_ringbuffer.c, branch linux-3.19.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.19.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.19.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2015-03-18T13:10:57Z</updated>
<entry>
<title>drm/i915: Insert a command barrier on BLT/BSD cache flushes</title>
<updated>2015-03-18T13:10:57Z</updated>
<author>
<name>Chris Wilson</name>
</author>
<published>2015-01-22T13:42:00Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b16a8497a0342524a343d07a234508cc12b68443'/>
<id>urn:sha1:b16a8497a0342524a343d07a234508cc12b68443</id>
<content type='text'>
commit f0a1fb10e5f79f5aaf8d7e94b9fa6bf2fa9aeebf upstream.

This looked like an odd regression from

commit ec5cc0f9b019af95e4571a9fa162d94294c8d90b
Author: Chris Wilson &lt;chris@chris-wilson.co.uk&gt;
Date:   Thu Jun 12 10:28:55 2014 +0100

    drm/i915: Restrict GPU boost to the RCS engine

but in reality it undercovered a much older coherency bug. The issue that
boosting the GPU frequency on the BCS ring was masking was that we could
wake the CPU up after completion of a BCS batch and inspect memory prior
to the write cache being fully evicted. In order to serialise the
breadcrumb interrupt (and so ensure that the CPU's view of memory is
coherent) we need to perform a post-sync operation in the MI_FLUSH_DW.

v2: Fix all the MI_FLUSH_DW (bsd plus the duplication in execlists).

Also fix the invalidate_domains mask in gen8_emit_flush() for ring !=
VCS.

Testcase: gpuX-rcs-gpu-read-after-write
Signed-off-by: Chris Wilson &lt;chris@chris-wilson.co.uk&gt;
Acked-by: Daniel Vetter &lt;daniel@ffwll.ch&gt;
Signed-off-by: Jani Nikula &lt;jani.nikula@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>drm/i915: Force the CS stall for invalidate flushes</title>
<updated>2014-12-16T13:06:48Z</updated>
<author>
<name>Chris Wilson</name>
</author>
<published>2014-12-16T08:44:32Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=add284a3a2481e759d6bec35f6444c32c8ddc383'/>
<id>urn:sha1:add284a3a2481e759d6bec35f6444c32c8ddc383</id>
<content type='text'>
In order to act as a full command barrier by itself, we need to tell the
pipecontrol to actually stall the command streamer while the flush runs.
We require the full command barrier before operations like
MI_SET_CONTEXT, which currently rely on a prior invalidate flush.

References: https://bugs.freedesktop.org/show_bug.cgi?id=83677
Cc: Simon Farnsworth &lt;simon@farnz.org.uk&gt;
Cc: Daniel Vetter &lt;daniel@ffwll.ch&gt;
Cc: Ville Syrjälä &lt;ville.syrjala@linux.intel.com&gt;
Signed-off-by: Chris Wilson &lt;chris@chris-wilson.co.uk&gt;
Cc: stable@vger.kernel.org
Signed-off-by: Jani Nikula &lt;jani.nikula@intel.com&gt;
</content>
</entry>
<entry>
<title>drm/i915: Invalidate media caches on gen7</title>
<updated>2014-12-16T13:04:39Z</updated>
<author>
<name>Chris Wilson</name>
</author>
<published>2014-12-16T08:44:31Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=148b83d0815a3778c8949e6a97cb798cbaa0efb3'/>
<id>urn:sha1:148b83d0815a3778c8949e6a97cb798cbaa0efb3</id>
<content type='text'>
In the gen7 pipe control there is an extra bit to flush the media
caches, so let's set it during cache invalidation flushes.

v2: Rename to MEDIA_STATE_CLEAR to be more inline with spec.

Cc: Simon Farnsworth &lt;simon@farnz.org.uk&gt;
Cc: Ville Syrjälä &lt;ville.syrjala@linux.intel.com&gt;
Cc: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
Signed-off-by: Chris Wilson &lt;chris@chris-wilson.co.uk&gt;
Reviewed-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
Cc: stable@vger.kernel.org
Signed-off-by: Jani Nikula &lt;jani.nikula@intel.com&gt;
</content>
</entry>
<entry>
<title>drm/i915: Remove '&amp; 0xffff' from the mask given to WA_REG()</title>
<updated>2014-12-10T14:39:24Z</updated>
<author>
<name>Damien Lespiau</name>
</author>
<published>2014-12-08T17:35:38Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=26459343e0fac1ea4cb5192c490e3e519eed74dd'/>
<id>urn:sha1:26459343e0fac1ea4cb5192c490e3e519eed74dd</id>
<content type='text'>
We may be hidding bugs by doing that, so let remove it and have the
actual mask value shine through, for better or worse.

Signed-off-by: Damien Lespiau &lt;damien.lespiau@intel.com&gt;
Signed-off-by: Jani Nikula &lt;jani.nikula@intel.com&gt;
</content>
</entry>
<entry>
<title>drm/i915: Invert the mask and val arguments in wa_add() and WA_REG()</title>
<updated>2014-12-10T14:33:30Z</updated>
<author>
<name>Damien Lespiau</name>
</author>
<published>2014-12-08T17:35:37Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=cf4b0de6a3f6e1814c45206a8b175d09b265bb16'/>
<id>urn:sha1:cf4b0de6a3f6e1814c45206a8b175d09b265bb16</id>
<content type='text'>
While trying to unify the order of those arguments throughout the
driver, Daniel noticed what we were inverting them in this part of the
code.

Suggested-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
Cc: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
Signed-off-by: Damien Lespiau &lt;damien.lespiau@intel.com&gt;
Signed-off-by: Jani Nikula &lt;jani.nikula@intel.com&gt;
</content>
</entry>
<entry>
<title>drm/i915/bdw: Fix the write setting up the WIZ hashing mode</title>
<updated>2014-12-10T09:20:46Z</updated>
<author>
<name>Damien Lespiau</name>
</author>
<published>2014-12-08T17:33:51Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=98533251b0bbfa5f24c502b9ab2f01ccb25c26b8'/>
<id>urn:sha1:98533251b0bbfa5f24c502b9ab2f01ccb25c26b8</id>
<content type='text'>
I was playing with clang and oh surprise! a warning trigerred by
-Wshift-overflow (gcc doesn't have this one):

    WA_SET_BIT_MASKED(GEN7_GT_MODE,
                      GEN6_WIZ_HASHING_MASK | GEN6_WIZ_HASHING_16x4);

    drivers/gpu/drm/i915/intel_ringbuffer.c:786:2: warning: signed shift result
      (0x28002000000) requires 43 bits to represent, but 'int' only has 32 bits
      [-Wshift-overflow]
        WA_SET_BIT_MASKED(GEN7_GT_MODE,
        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    drivers/gpu/drm/i915/intel_ringbuffer.c:737:15: note: expanded from macro
      'WA_SET_BIT_MASKED'
        WA_REG(addr, _MASKED_BIT_ENABLE(mask), (mask) &amp; 0xffff)

Turned out GEN6_WIZ_HASHING_MASK was already shifted by 16, and we were
trying to shift it a bit more.

The other thing is that it's not the usual case of setting WA bits here, we
need to have separate mask and value.

To fix this, I've introduced a new _MASKED_FIELD() macro that takes both the
(unshifted) mask and the desired value and the rest of the patch ripples
through from it.

This bug was introduced when reworking the WA emission in:

  Commit 7225342ab501befdb64bcec76ded41f5897c0855
  Author: Mika Kuoppala &lt;mika.kuoppala@linux.intel.com&gt;
  Date:   Tue Oct 7 17:21:26 2014 +0300

      drm/i915: Build workaround list in ring initialization

v2: Invert the order of the mask and value arguments (Daniel Vetter)
    Rewrite _MASKED_BIT_ENABLE() and _MASKED_BIT_DISABLE() with
    _MASKED_FIELD() (Jani Nikula)
    Make sure we only evaluate 'a' once in _MASKED_BIT_ENABLE() (Dave Gordon)
    Add check to ensure the value is within the mask boundaries (Chris Wilson)

v3: Ensure the the value and mask are 16 bits (Dave Gordon)

Cc: Mika Kuoppala &lt;mika.kuoppala@linux.intel.com&gt;
Cc: Arun Siluvery &lt;arun.siluvery@linux.intel.com&gt;
Signed-off-by: Damien Lespiau &lt;damien.lespiau@intel.com&gt;
Signed-off-by: Jani Nikula &lt;jani.nikula@intel.com&gt;
</content>
</entry>
<entry>
<title>drm/i915: Remove DRI1 ring accessors and API</title>
<updated>2014-11-19T20:17:11Z</updated>
<author>
<name>Chris Wilson</name>
</author>
<published>2014-09-06T09:28:27Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5c6c600354adac5f95fd41b178b084ac0182e14c'/>
<id>urn:sha1:5c6c600354adac5f95fd41b178b084ac0182e14c</id>
<content type='text'>
With the deprecation of UMS, and by association DRI1, we have a tough
choice when updating the ring access routines. We either rewrite the
DRI1 routines blindly without testing (so likely to be broken) or take
the liberty of declaring them no longer supported and remove them
entirely. This takes the latter approach.

v2: Also remove the DRI1 sarea updates

Signed-off-by: Chris Wilson &lt;chris@chris-wilson.co.uk&gt;
[danvet: Fix rebase conflicts.]
Signed-off-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
</content>
</entry>
<entry>
<title>drm/i915/bdw: Pin the ringbuffer backing object to GGTT on-demand</title>
<updated>2014-11-19T18:56:44Z</updated>
<author>
<name>Thomas Daniel</name>
</author>
<published>2014-11-13T10:28:56Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=7ba717cf365d79f2b284e508205ec3d4a05fc41b'/>
<id>urn:sha1:7ba717cf365d79f2b284e508205ec3d4a05fc41b</id>
<content type='text'>
Same as with the context, pinning to GGTT regardless is harmful (it
badly fragments the GGTT and can even exhaust it).

Unfortunately, this case is also more complex than the previous one
because we need to map and access the ringbuffer in several places
along the execbuffer path (and we cannot make do by leaving the
default ringbuffer pinned, as before). Also, the context object
itself contains a pointer to the ringbuffer address that we have to
keep updated if we are going to allow the ringbuffer to move around.

v2: Same as with the context pinning, we cannot really do it during
an interrupt. Also, pin the default ringbuffers objects regardless
(makes error capture a lot easier).

v3: Rebased. Take a pin reference of the ringbuffer for each item
in the execlist request queue because the hardware may still be using
the ringbuffer after the MI_USER_INTERRUPT to notify the seqno update
is executed.  The ringbuffer must remain pinned until the context save
is complete.  No longer pin and unpin ringbuffer in
populate_lr_context() - this transient address is meaningless and the
pinning can cause a sleep while atomic.

v4: Moved ringbuffer pin and unpin into the lr_context_pin functions.
Downgraded pinning check BUG_ONs to WARN_ONs.

v5: Reinstated WARN_ONs for unexpected execlist states.  Removed unused
variable.

Issue: VIZ-4277
Signed-off-by: Oscar Mateo &lt;oscar.mateo@intel.com&gt;
Signed-off-by: Thomas Daniel &lt;thomas.daniel@intel.com&gt;
Reviewed-by: Akash Goel &lt;akash.goels@gmail.com&gt;
Reviewed-by: Deepak S&lt;deepak.s@linux.intel.com&gt;
Signed-off-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
</content>
</entry>
<entry>
<title>drm/i915: Initialize workarounds in logical ring mode too</title>
<updated>2014-11-14T09:29:25Z</updated>
<author>
<name>Michel Thierry</name>
</author>
<published>2014-11-11T16:47:33Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=771b9a532483cc45df19823b8dfaa0cecfd45836'/>
<id>urn:sha1:771b9a532483cc45df19823b8dfaa0cecfd45836</id>
<content type='text'>
Following the legacy ring submission example, update the
ring-&gt;init_context() hook to support the execlist submission mode.

v2: update to use the new workaround macros and cleanup unused code.
This takes care of both bdw and chv workarounds.

v2.1: Add missing call to init_context() during deferred context creation.

v3: Split init_context (emit) in legacy/lrc modes. For lrc, get the ringbuf
from the context (Mika/Daniel).

v4: Merge init_context interfaces back, the legacy mode only needs the ring,
but the lrc mode needs the ring and context (Mika).

Issue: VIZ-4092
Issue: GMIN-3475
Change-Id: Ie3d093b2542ab0e2a44b90460533e2f979788d6c
Cc: Deepak S &lt;deepak.s@intel.com&gt;
Cc: Mika Kuoppala &lt;mika.kuoppala@linux.intel.com&gt;
Cc: Daniel Vetter &lt;daniel@ffwll.ch&gt;
Signed-off-by: Michel Thierry &lt;michel.thierry@intel.com&gt;
Signed-off-by: Arun Siluvery &lt;arun.siluvery@linux.intel.com&gt;
Reviewed-by: Mika Kuoppala &lt;mika.kuoppala@intel.com&gt;
[danvet: Align function paramater lists properly.]
Signed-off-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
</content>
</entry>
<entry>
<title>drm/i915/chv: Add new workarounds for chv</title>
<updated>2014-11-14T09:29:15Z</updated>
<author>
<name>Arun Siluvery</name>
</author>
<published>2014-10-28T18:33:14Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=952890098a14043fe7acc5f595c6306c69baf40d'/>
<id>urn:sha1:952890098a14043fe7acc5f595c6306c69baf40d</id>
<content type='text'>
+WaForceEnableNonCoherent:chv
+WaHdcDisableFetchWhenMasked:chv

For: VIZ-4090
Signed-off-by: Arun Siluvery &lt;arun.siluvery@linux.intel.com&gt;
Reviewed-by: Ville Syrjälä &lt;ville.syrjala@linux.intel.com&gt;
Signed-off-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
</content>
</entry>
</feed>
