Re: [Intel-gfx] [PATCH] drm/i915: fix build error without CONFIG_BACKLIGHT_CLASS_DEVICE

2017-03-29 Thread Jani Nikula
On Wed, 29 Mar 2017, Tobias Regnery wrote: > With CONFIG_ACPI=n and CONFIG_BACKLIGHT_CLASS_DEVICE=n we see the following > link error in the i915 driver: > > drivers/built-in.o: In function 'intel_backlight_device_register': > (.text+0x2a921d): undefined reference to 'backlight_device_register' >

Re: [Intel-gfx] [i-g-t PATCH v4] tests/kms_hdmi_inject: Add test for HDMI injection capabilities.

2017-03-29 Thread Abdiel Janulgue
On 30.03.2017 09:43, Petri Latvala wrote: > On Wed, Mar 29, 2017 at 12:52:29PM +0300, Abdiel Janulgue wrote: >> Original author: Marius Vlad. Includes fixes below. >> >> v4: Add a unit test to make sure synthetic EDID blocks generated by >> IGT is valid (suggested by Petri). >> > > > No no,

Re: [Intel-gfx] [i-g-t PATCH v4] tests/kms_hdmi_inject: Add test for HDMI injection capabilities.

2017-03-29 Thread Petri Latvala
On Wed, Mar 29, 2017 at 12:52:29PM +0300, Abdiel Janulgue wrote: > Original author: Marius Vlad. Includes fixes below. > > v4: Add a unit test to make sure synthetic EDID blocks generated by > IGT is valid (suggested by Petri). > No no, I meant a build-time test, in lib/tests, run by 'make [

Re: [Intel-gfx] [maintainer-tools PATCH] dim: Fix assorted documentation typos

2017-03-29 Thread Jani Nikula
On Wed, 29 Mar 2017, Lukas Wunner wrote: > Just a bunch of trivial typos that caught my eye while perusing the > documentation. > > Signed-off-by: Lukas Wunner Reviewed-by: Jani Nikula Thanks, please push yourself! > --- > dim.rst | 14 +++--- > drm-intel.rst | 10 +- >

Re: [Intel-gfx] [PATCH] drm/i915: Setting pch_id for Gen7.5+ in virtual environment

2017-03-29 Thread Jani Nikula
On Thu, 30 Mar 2017, "Zhang, Xiong Y" wrote: >> On Wed, Mar 29, 2017 at 05:02:47PM +0800, Xiong Zhang wrote: >> I'm not 100% sure the ULT/ULX <=> LP thing always holds. I *think* it >> should but I've never been able to convince myself totally. > [Zhang, Xiong Y] For BDW ULT/ULX, it should be LP.

Re: [Intel-gfx] [PATCH RESEND 4/4] drm/i915/opregion: let user specify override VBT via firmware load

2017-03-29 Thread Jani Nikula
On Wed, 29 Mar 2017, Bob Paauwe wrote: > On Wed, 29 Mar 2017 13:32:58 +0300 > Jani Nikula wrote: > >> Sometimes it would be most enlightening to debug systems by replacing >> the VBT to be used. For example, in the referenced bug the BIOS provides >> different VBT depending on the boot mode (UEFI

Re: [Intel-gfx] Panic after S3 resume and modeset with MST

2017-03-29 Thread Takashi Iwai
On Thu, 30 Mar 2017 02:24:37 +0200, Lyude Paul wrote: > > On Wed, 2017-03-29 at 15:54 +0200, Takashi Iwai wrote: > > On Wed, 29 Mar 2017 15:34:15 +0200, > > Ville Syrjälä wrote: > > > > > > On Wed, Mar 29, 2017 at 03:10:09PM +0200, Takashi Iwai wrote: > > > > On Mon, 27 Mar 2017 18:02:13 +0200, >

Re: [Intel-gfx] [PATCH] drm/i915: Setting pch_id for Gen7.5+ in virtual environment

2017-03-29 Thread Zhang, Xiong Y
> On Wed, Mar 29, 2017 at 05:02:47PM +0800, Xiong Zhang wrote: > > In a virtual passthrough environment, the ISA bridge isn't able to > > be passed through. So pch_id couldn't be gotten from ISA bridge, but > > pch_id is used to identify LPT_H and LPT_LP, this patch set pch_id > > according to IGD

Re: [Intel-gfx] [PATCH v4 0/6] Enhancement to intel_dp_aux_backlight driver

2017-03-29 Thread Puthikorn Voravootivat
Friendly ping. Can anyone please review this? Thanks On Wed, Mar 22, 2017 at 3:54 PM, Puthikorn Voravootivat wrote: > Rebase since this is not applied cleanly now. > > This patch set contain 6 patches. > - First two patches allow enable DPCD backlight control when panel > can also do that via

[Intel-gfx] linux-next: manual merge of the drm tree with the drm-intel-fixes tree

2017-03-29 Thread Stephen Rothwell
Hi Dave, Today's linux-next merge of the drm tree got a conflict in: drivers/gpu/drm/i915/intel_ringbuffer.h between commit: dd68f2ba0720 ("drm/i915/execlists: Wrap tail pointer after reset tweaking") from the drm-intel-fixes tree and commit: 73dec95e6ba3 ("drm/i915: Emit to ringbuffer

[Intel-gfx] linux-next: manual merge of the drm tree with the drm-intel-fixes tree

2017-03-29 Thread Stephen Rothwell
Hi Dave, Today's linux-next merge of the drm tree got a conflict in: drivers/gpu/drm/i915/intel_lrc.c between commit: dd68f2ba0720 ("drm/i915/execlists: Wrap tail pointer after reset tweaking") from the drm-intel-fixes tree and commit: 944a36d472be ("drm/i915: Assert that the request->t

Re: [Intel-gfx] Panic after S3 resume and modeset with MST

2017-03-29 Thread Lyude Paul
On Wed, 2017-03-29 at 15:54 +0200, Takashi Iwai wrote: > On Wed, 29 Mar 2017 15:34:15 +0200, > Ville Syrjälä wrote: > > > > On Wed, Mar 29, 2017 at 03:10:09PM +0200, Takashi Iwai wrote: > > > On Mon, 27 Mar 2017 18:02:13 +0200, > > > Takashi Iwai wrote: > > > > > > > > Hi, > > > > > > > > the up

Re: [Intel-gfx] [PATCH 1/4] drm/i915: Wait for inflight writes before checking intel_engine_is_idle()

2017-03-29 Thread Chris Wilson
On Wed, Mar 29, 2017 at 10:36:16PM +0100, Chris Wilson wrote: > Some GPUs may have writes inflight much longer than expected, so before > declaring the GPU is idle, try to flush them using any > engine->irq_seqno_barrier() if available. By allowing them to be > flushed, we can be a little more conf

Re: [Intel-gfx] [PATCH 2/4] drm/i915: Wait for all engines to be idle as part of i915_gem_wait_for_idle()

2017-03-29 Thread Chris Wilson
On Wed, Mar 29, 2017 at 10:36:17PM +0100, Chris Wilson wrote: > Make i915_gem_wait_for_idle() be a little heavier in order to try and > guarantee that the GPU is indeed idle (by checking each engine > individually is idle, i.e. all writes are complete and the rings > stopped) after waiting for in-f

Re: [Intel-gfx] [PATCH 3/3] drm/i915: Add format modifiers for Intel

2017-03-29 Thread Ben Widawsky
On 17-03-29 23:17:13, Ville Syrjälä wrote: On Fri, Mar 24, 2017 at 02:29:50PM -0700, Ben Widawsky wrote: This was based on a patch originally by Kristian. It has been modified pretty heavily to use the new callbacks from the previous patch. v2: - Add LINEAR and Yf modifiers to list (Ville)

Re: [Intel-gfx] [PATCH 2/4] drm/i915: Wait for all engines to be idle as part of i915_gem_wait_for_idle()

2017-03-29 Thread Chris Wilson
On Wed, Mar 29, 2017 at 10:36:17PM +0100, Chris Wilson wrote: > Make i915_gem_wait_for_idle() be a little heavier in order to try and > guarantee that the GPU is indeed idle (by checking each engine > individually is idle, i.e. all writes are complete and the rings > stopped) after waiting for in-f

[Intel-gfx] [PATCH] drm/i915: Drop verbose and archaic "ring" from our internal engine names

2017-03-29 Thread Chris Wilson
We pretty print the name of an engine in several places, mostly for debug, but also in the GPU hang report. Using "ring" in the name is archaic (we call those engines now to differentiate them from the multiple rings of commands we execute on each engine), quite verbose and often tautological. We r

[Intel-gfx] ✓ Fi.CI.BAT: success for series starting with [1/4] drm/i915: Wait for inflight writes before checking intel_engine_is_idle() (rev2)

2017-03-29 Thread Patchwork
== Series Details == Series: series starting with [1/4] drm/i915: Wait for inflight writes before checking intel_engine_is_idle() (rev2) URL : https://patchwork.freedesktop.org/series/22126/ State : success == Summary == Series 22126v2 Series without cover letter https://patchwork.freedesktop

[Intel-gfx] [PATCH] drm/i915: Combine reset_all_global_seqno() loops into one

2017-03-29 Thread Chris Wilson
We can merge the pair of loops over the engines and their timelines into a single loop, making it easier to read and more consistent with the commentary. Signed-off-by: Chris Wilson --- git add ftw --- drivers/gpu/drm/i915/i915_gem_request.c | 14 +- 1 file changed, 5 insertions(+),

[Intel-gfx] ✗ Fi.CI.BAT: failure for series starting with [1/4] drm/i915: Wait for inflight writes before checking intel_engine_is_idle()

2017-03-29 Thread Patchwork
== Series Details == Series: series starting with [1/4] drm/i915: Wait for inflight writes before checking intel_engine_is_idle() URL : https://patchwork.freedesktop.org/series/22126/ State : failure == Summary == LD [M] drivers/net/ethernet/broadcom/genet/genet.o LD net/packet/buil

[Intel-gfx] [PATCH 3/4] drm/i915: Remove redudant wait for each engine to idle from seqno wrap

2017-03-29 Thread Chris Wilson
Having added the wait upon each engine to idle into the central i915_gem_wait_for_idle(), we can remove the now redundant wait from reset_all_global_seqno(). This has the advantage of removing the late detection of an error (an engine still busy) which left the seqno reset only partially complete (

[Intel-gfx] [PATCH 4/4] drm/i915: Combine reset_all_global_seqno() loops into one

2017-03-29 Thread Chris Wilson
We can merge the pair of loops over the engines and their timelines into a single loop, making it easier to read and more consistent with the commentary. Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/i915_gem_request.c | 11 +++ 1 file changed, 3 insertions(+), 8 deletions(-) dif

[Intel-gfx] [PATCH 2/4] drm/i915: Wait for all engines to be idle as part of i915_gem_wait_for_idle()

2017-03-29 Thread Chris Wilson
Make i915_gem_wait_for_idle() be a little heavier in order to try and guarantee that the GPU is indeed idle (by checking each engine individually is idle, i.e. all writes are complete and the rings stopped) after waiting for in-flight requests to be completed. References: https://bugs.freedesktop.

[Intel-gfx] [PATCH 1/4] drm/i915: Wait for inflight writes before checking intel_engine_is_idle()

2017-03-29 Thread Chris Wilson
Some GPUs may have writes inflight much longer than expected, so before declaring the GPU is idle, try to flush them using any engine->irq_seqno_barrier() if available. By allowing them to be flushed, we can be a little more confident that the GPU really is idle when we think it is! References: ht

Re: [Intel-gfx] [PATCH v2 2/2] drm/i915: Implement cdclk restrictions based on Azalia BCLK

2017-03-29 Thread Pandiyan, Dhinakaran
On Wed, 2017-03-29 at 11:50 +0300, Ville Syrjälä wrote: > On Tue, Mar 07, 2017 at 04:12:52PM -0800, Dhinakaran Pandiyan wrote: > > According to BSpec, "The CD clock frequency must be at least twice the > > frequency of the Azalia BCLK." and BCLK is configured to 96 MHz by > > default. This check is

[Intel-gfx] [maintainer-tools PATCH] dim: Fix assorted documentation typos

2017-03-29 Thread Lukas Wunner
Just a bunch of trivial typos that caught my eye while perusing the documentation. Signed-off-by: Lukas Wunner --- dim.rst | 14 +++--- drm-intel.rst | 10 +- drm-misc.rst | 2 +- 3 files changed, 13 insertions(+), 13 deletions(-) diff --git a/dim.rst b/dim.rst index aed

[Intel-gfx] [drm-intel:drm-intel-nightly 1066/1091] drivers/gpu/drm/drm_plane.c:933:48-49: ERROR: reference preceded by free on line 926 (fwd)

2017-03-29 Thread Julia Lawall
The kfree on line 926 would only be a problem for the references to e on lines 933 and 937 if the return value of drm_event_reserve_init can be -EDEADLK. julia -- Forwarded message -- Date: Thu, 30 Mar 2017 00:48:54 +0800 From: kbuild test robot To: kbu...@01.org Cc: Julia Lawall

Re: [Intel-gfx] [PATCH 1/3] drm/i915: Use LINEAR modifier instead of NONE

2017-03-29 Thread Ville Syrjälä
On Wed, Mar 29, 2017 at 11:03:40PM +0300, Ville Syrjälä wrote: > On Fri, Mar 24, 2017 at 02:29:48PM -0700, Ben Widawsky wrote: > > They're the same, so use the one which makes more sense. > > > > Signed-off-by: Ben Widawsky > > Reviewed-by: Ville Syrjälä And pushed to dinq immediately. Thanks

Re: [Intel-gfx] [PATCH 3/3] drm/i915: Add format modifiers for Intel

2017-03-29 Thread Ville Syrjälä
On Fri, Mar 24, 2017 at 02:29:50PM -0700, Ben Widawsky wrote: > This was based on a patch originally by Kristian. It has been modified > pretty heavily to use the new callbacks from the previous patch. > > v2: > - Add LINEAR and Yf modifiers to list (Ville) > - Combine i8xx and i965 into one l

Re: [Intel-gfx] [PATCH 1/3] drm/i915: Use LINEAR modifier instead of NONE

2017-03-29 Thread Ville Syrjälä
On Fri, Mar 24, 2017 at 02:29:48PM -0700, Ben Widawsky wrote: > They're the same, so use the one which makes more sense. > > Signed-off-by: Ben Widawsky Reviewed-by: Ville Syrjälä > --- > drivers/gpu/drm/i915/intel_display.c | 28 ++-- > 1 file changed, 14 insertions(+

Re: [Intel-gfx] [PATCH] drm: Fixup failure paths in drm_atomic_helper_set_config

2017-03-29 Thread Harry Wentland
Of course. I totally missed that. Reviewed-by: Harry Wentland Harry On 2017-03-29 01:41 PM, Daniel Vetter wrote: I've screwed this up when removing the legacy backoff hack. Fixes: 38b6441e4e75 ("drm/atomic-helper: Remove the backoff hack from set_config") Cc: Harry Wentland Cc: Daniel Vett

[Intel-gfx] [PATCH 1/3] drm/i915: Group all the global context information together

2017-03-29 Thread Chris Wilson
Create a substruct to hold all the global context state under drm_i915_private. Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/i915_debugfs.c | 4 +-- drivers/gpu/drm/i915/i915_drv.c | 2 +- drivers/gpu/drm/i915/i915_drv.h | 20 +++--

[Intel-gfx] [PATCH 3/3] drm/i915: Enable rcu-only context lookups

2017-03-29 Thread Chris Wilson
Whilst the contents of the context is still protected by the big struct_mutex, this is not much of an improvement. It is just one tiny step towards reducing our BKL. Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/i915_drv.h| 16 +-- drivers/gpu/drm/i915/i915_gem_context.c

[Intel-gfx] [PATCH 2/3] drm/i915: Allows contexts to be unreferenced locklessly

2017-03-29 Thread Chris Wilson
If we move the actual cleanup of the context to a worker, we can allow the final free to be called from any context and avoid undue latency in the caller. Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/gvt/scheduler.c| 2 +- drivers/gpu/drm/i915/i915_drv.h | 23 ++-

[Intel-gfx] ✓ Fi.CI.BAT: success for drm: Fixup failure paths in drm_atomic_helper_set_config

2017-03-29 Thread Patchwork
== Series Details == Series: drm: Fixup failure paths in drm_atomic_helper_set_config URL : https://patchwork.freedesktop.org/series/22106/ State : success == Summary == Series 22106v1 drm: Fixup failure paths in drm_atomic_helper_set_config https://patchwork.freedesktop.org/api/1.0/series/221

Re: [Intel-gfx] [PATCH RESEND 4/4] drm/i915/opregion: let user specify override VBT via firmware load

2017-03-29 Thread Bob Paauwe
On Wed, 29 Mar 2017 13:32:58 +0300 Jani Nikula wrote: > Sometimes it would be most enlightening to debug systems by replacing > the VBT to be used. For example, in the referenced bug the BIOS provides > different VBT depending on the boot mode (UEFI vs. legacy). It would be > interesting to try t

Re: [Intel-gfx] [PATCH RESEND 3/4] drm/i915/opregion: debug log about invalid ACPI OpRegion VBT

2017-03-29 Thread Bob Paauwe
On Wed, 29 Mar 2017 13:32:57 +0300 Jani Nikula wrote: > Leave more breadcrumbs for debuggers. > > Signed-off-by: Jani Nikula Reviewed-by: Bob Paauwe > --- > drivers/gpu/drm/i915/intel_opregion.c | 4 > 1 file changed, 4 insertions(+) > > diff --git a/drivers/gpu/drm/i915/intel_opregio

Re: [Intel-gfx] [PATCH RESEND 2/4] drm/i915/opregion: try to validate RVDA VBT only if it's there

2017-03-29 Thread Bob Paauwe
On Wed, 29 Mar 2017 13:32:56 +0300 Jani Nikula wrote: > Seems more sensible this way, and reduces indent for the more common > case. > > Signed-off-by: Jani Nikula Reviewed-by: Bob Paauwe > --- > drivers/gpu/drm/i915/intel_opregion.c | 41 > +-- > 1 file cha

Re: [Intel-gfx] [PATCH RESEND 1/4] drm/i915/opregion: bail out early for systems with no opregion VBT

2017-03-29 Thread Bob Paauwe
On Wed, 29 Mar 2017 13:32:55 +0300 Jani Nikula wrote: > Reduce indent. No functional changes. > > Signed-off-by: Jani Nikula Reviewed-by: Bob Paauwe > --- > drivers/gpu/drm/i915/intel_opregion.c | 64 > +-- > 1 file changed, 32 insertions(+), 32 deletions(-)

Re: [Intel-gfx] [PATCH v4 08/11] drm/exynos: Remove custom FB helper deferred setup

2017-03-29 Thread Daniel Vetter
On Wed, Mar 29, 2017 at 04:43:58PM +0200, Thierry Reding wrote: > From: Thierry Reding > > The FB helper core now supports deferred setup, so the driver's custom > implementation can be removed. > > Signed-off-by: Thierry Reding > --- > drivers/gpu/drm/exynos/exynos_drm_drv.c | 6 -- >

[Intel-gfx] [PATCH] drm: Fixup failure paths in drm_atomic_helper_set_config

2017-03-29 Thread Daniel Vetter
I've screwed this up when removing the legacy backoff hack. Fixes: 38b6441e4e75 ("drm/atomic-helper: Remove the backoff hack from set_config") Cc: Harry Wentland Cc: Daniel Vetter Cc: Daniel Vetter Cc: Jani Nikula Cc: Sean Paul Cc: David Airlie Cc: dri-de...@lists.freedesktop.org Signed-off

Re: [Intel-gfx] [PATCH v2] drm/i915/dp: Validate cached link rate and lane count before retraining

2017-03-29 Thread Manasi Navare
On Wed, Mar 29, 2017 at 03:11:46PM +0300, Jani Nikula wrote: > On Wed, 29 Mar 2017, Ville Syrjälä wrote: > > On Wed, Mar 29, 2017 at 10:29:24AM +0300, Jani Nikula wrote: > >> On Tue, 28 Mar 2017, Manasi Navare wrote: > >> > Jani, > >> > > >> > Should I just hold on to this until your patch series

[Intel-gfx] [PATCH v8 1/3] drm_fourcc: Add new P010, P016 video format

2017-03-29 Thread clinton . a . taylor
From: Clint Taylor P010 is a planar 4:2:0 YUV with interleaved UV plane, 10 bits per channel video format. P012 is a planar 4:2:0 YUV 12 bits per channel P016 is a planar 4:2:0 YUV with interleaved UV plane, 16 bits per channel video format. V3: Added P012 and fixed cpp for P010 V4: format def

[Intel-gfx] ✓ Fi.CI.BAT: success for series starting with [01/13] drm/i915: Reinstate reservation_object zapping for batch_pool objects

2017-03-29 Thread Patchwork
== Series Details == Series: series starting with [01/13] drm/i915: Reinstate reservation_object zapping for batch_pool objects URL : https://patchwork.freedesktop.org/series/22099/ State : success == Summary == Series 22099v1 Series without cover letter https://patchwork.freedesktop.org/api/

Re: [Intel-gfx] [PATCH] drm/i915: Extend wait-ioctl to only wait on writes

2017-03-29 Thread Chris Wilson
On Wed, Mar 29, 2017 at 03:58:26PM +0100, Chris Wilson wrote: > Currently, we allow read-read CPU/GPU concurrency via set-domain-ioctl, > but we don't have a similar facility for a plain wait-ioctl. If we add a > new flag that userspace can use to opt-in for only waiting for GPU > writes, userspace

[Intel-gfx] [PATCH 13/13] drm/i915/scheduler: Support user-defined priorities

2017-03-29 Thread Chris Wilson
Use a priority stored in the context as the initial value when submitting a request. This allows us to change the default priority on a per-context basis, allowing different contexts to be favoured with GPU time at the expense of lower importance work. The user can adjust the context's priority via

[Intel-gfx] [PATCH 08/13] drm/i915: Eliminate lots of iterations over the execobjects array

2017-03-29 Thread Chris Wilson
The major scaling bottleneck in execbuffer is the processing of the execobjects. Creating an auxiliary list is inefficient when compared to using the execobject array we already have allocated. Reservation is then split into phases. As we lookup up the VMA, we try and bind it back into active loca

[Intel-gfx] [PATCH 12/13] drm/i915: Async GPU relocation processing

2017-03-29 Thread Chris Wilson
If the user requires patching of their batch or auxiliary buffers, we currently make the alterations on the cpu. If they are active on the GPU at the time, we wait under the struct_mutex for them to finish executing before we rewrite the contents. This happens if shared relocation trees are used be

[Intel-gfx] [PATCH 09/13] drm/i915: First try the previous execbuffer location

2017-03-29 Thread Chris Wilson
When choosing a slot for an execbuffer, we ideally want to use the same address as last time (so that we don't have to rebind it) and the same address as expected by the user (so that we don't have to fixup any relocations pointing to it). If we first try to bind the incoming execbuffer->offset fro

[Intel-gfx] [PATCH 03/13] drm/i915: Amalgamate execbuffer parameter structures

2017-03-29 Thread Chris Wilson
Combine the two slightly overlapping parameter structures we pass around the execbuffer routines into one. Signed-off-by: Chris Wilson Reviewed-by: Joonas Lahtinen --- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 550 - 1 file changed, 233 insertions(+), 317 deletion

[Intel-gfx] [PATCH 10/13] drm/i915: Wait upon userptr get-user-pages within execbuffer

2017-03-29 Thread Chris Wilson
This simply hides the EAGAIN caused by userptr when userspace causes resource contention. However, it is quite beneficial with highly contended userptr users as we avoid repeating the setup costs and kernel-user context switches. Signed-off-by: Chris Wilson Reviewed-by: Michał Winiarski --- dri

[Intel-gfx] [PATCH 11/13] drm/i915: Allow execbuffer to use the first object as the batch

2017-03-29 Thread Chris Wilson
Currently, the last object in the execlist is the always the batch. However, when building the batch buffer we often know the batch object first and if we can use the first slot in the execlist we can emit relocation instructions relative to it immediately and avoid a separate pass to adjust the re

[Intel-gfx] [PATCH 06/13] drm/i915: Store a direct lookup from object handle to vma

2017-03-29 Thread Chris Wilson
The advent of full-ppgtt lead to an extra indirection between the object and its binding. That extra indirection has a noticeable impact on how fast we can convert from the user handles to our internal vma for execbuffer. In order to bypass the extra indirection, we use a resizable hashtable to jum

[Intel-gfx] [PATCH 07/13] drm/i915: Pass vma to relocate entry

2017-03-29 Thread Chris Wilson
We can simplify our tracking of pending writes in an execbuf to the single bit in the vma->exec_entry->flags, but that requires the relocation function knowing the object's vma. Pass it along. Note we have only been using a single bit to track flushing since commit cc889e0f6ce6a63c62db17d702ecfed

[Intel-gfx] [PATCH 04/13] drm/i915: Use vma->exec_entry as our double-entry placeholder

2017-03-29 Thread Chris Wilson
This has the benefit of not requiring us to manipulate the vma->exec_link list when tearing down the execbuffer, and is a marginally cheaper test to detect the user error. Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/i915_gem_evict.c | 17 ++- drivers/gpu/drm/i915/i915_gem_execb

[Intel-gfx] [PATCH 02/13] drm/i915: Copy user requested buffers into the error state

2017-03-29 Thread Chris Wilson
Introduce a new execobject.flag (EXEC_OBJECT_CAPTURE) that userspace may use to indicate that it wants the contents of this buffer preserved in the error state (/sys/class/drm/cardN/error) following a GPU hang involving this batch. Use this at your discretion, the contents of the error state. alth

[Intel-gfx] Another week, another eb bomb

2017-03-29 Thread Chris Wilson
Just to remind everyone that this series is unstoppable and we want the green, not to mention the small boosts we get from dramatically reducing overhead of execbuf for many typical submission paths. -Chris ___ Intel-gfx mailing list Intel-gfx@lists.free

[Intel-gfx] [PATCH 01/13] drm/i915: Reinstate reservation_object zapping for batch_pool objects

2017-03-29 Thread Chris Wilson
I removed the zapping of the reservation_object->fence array of shared fences prematurely. We don't yet have the code to zap that array when retiring the object, and so currently it remains possible to continually grow the shared array trapping requests when reusing the batch_pool object across man

[Intel-gfx] [PATCH 05/13] drm/i915: Split vma exec_link/evict_link

2017-03-29 Thread Chris Wilson
Currently the vma has one link member that is used for both holding its place in the execbuf reservation list, and in any eviction list. This dual property is quite tricky and error prone. Signed-off-by: Chris Wilson Reviewed-by: Mika Kuoppala --- drivers/gpu/drm/i915/i915_gem_evict.c | 14

[Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915: Extend wait-ioctl to only wait on writes

2017-03-29 Thread Patchwork
== Series Details == Series: drm/i915: Extend wait-ioctl to only wait on writes URL : https://patchwork.freedesktop.org/series/22093/ State : success == Summary == Series 22093v1 drm/i915: Extend wait-ioctl to only wait on writes https://patchwork.freedesktop.org/api/1.0/series/22093/revisions

[Intel-gfx] [drm-intel:drm-intel-nightly 1077/1091] drivers/gpu/drm/drm_irq.c:341:6: error: call to '__cmpxchg_called_with_bad_pointer' declared with attribute error: Bad argument size for cmpxchg

2017-03-29 Thread kbuild test robot
tree: git://anongit.freedesktop.org/drm-intel drm-intel-nightly head: 2f9f22b419350cafb06ba7e5342bc461fcb0afca commit: 43dc7fe2b2118c76fbc2808dec0c57b3158e6dc0 [1077/1091] drm: Mark up accesses of vblank->enabled outside of its spinlock config: tile-tilegx_defconfig (attached as .config) compi

[Intel-gfx] ✗ Fi.CI.BAT: warning for drm/fb-helper: Deferred setup support (rev3)

2017-03-29 Thread Patchwork
== Series Details == Series: drm/fb-helper: Deferred setup support (rev3) URL : https://patchwork.freedesktop.org/series/8410/ State : warning == Summary == Series 8410v3 drm/fb-helper: Deferred setup support https://patchwork.freedesktop.org/api/1.0/series/8410/revisions/3/mbox/ Test core_au

[Intel-gfx] [PATCH] drm/i915: Extend wait-ioctl to only wait on writes

2017-03-29 Thread Chris Wilson
Currently, we allow read-read CPU/GPU concurrency via set-domain-ioctl, but we don't have a similar facility for a plain wait-ioctl. If we add a new flag that userspace can use to opt-in for only waiting for GPU writes, userspace can use it to co-ordinate its own read-read concurrency (without the

Re: [Intel-gfx] [PATCH v4 06/11] drm/fb-helper: Make top-level lock more robust

2017-03-29 Thread Thierry Reding
On Wed, Mar 29, 2017 at 04:43:56PM +0200, Thierry Reding wrote: > From: Thierry Reding > > The existing drm_fb_helper_hotplug_event() function needs to take the > top-level fb-helper lock. However, the function can also be called from > code that has already taken this lock. Introduce an unlocked

[Intel-gfx] [PATCH v4 07/11] drm/fb-helper: Support deferred setup

2017-03-29 Thread Thierry Reding
From: Thierry Reding FB helper code falls back to a 1024x768 mode if no outputs are connected or don't report back any modes upon initialization. This can be annoying because outputs that are added to FB helper later on can't be used with FB helper if they don't support a matching mode. The fall

[Intel-gfx] [PATCH v4 08/11] drm/exynos: Remove custom FB helper deferred setup

2017-03-29 Thread Thierry Reding
From: Thierry Reding The FB helper core now supports deferred setup, so the driver's custom implementation can be removed. Signed-off-by: Thierry Reding --- drivers/gpu/drm/exynos/exynos_drm_drv.c | 6 -- drivers/gpu/drm/exynos/exynos_drm_fbdev.c | 23 --- 2 files ch

[Intel-gfx] [PATCH v4 04/11] drm/fb-helper: Push down modeset lock into FB helpers

2017-03-29 Thread Thierry Reding
From: Thierry Reding Move the modeset locking from drivers into FB helpers. Tested-by: John Stultz Reviewed-by: Daniel Vetter Signed-off-by: Thierry Reding --- drivers/gpu/drm/drm_fb_helper.c| 40 +- drivers/gpu/drm/i915/intel_dp_mst.c| 3 --- dri

[Intel-gfx] [PATCH v4 10/11] drm/atmel-hlcdc: Remove unnecessary NULL check

2017-03-29 Thread Thierry Reding
From: Thierry Reding drm_fbdev_cma_hotplug_event() already checks for NULL pointers before dereferencing, so callers don't need to do that. Reviewed-by: Daniel Vetter Signed-off-by: Thierry Reding --- drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.c | 3 +-- 1 file changed, 1 insertion(+), 2 dele

[Intel-gfx] [PATCH v4 03/11] drm/fb-helper: Improve code readability

2017-03-29 Thread Thierry Reding
From: Thierry Reding Add a couple of temporary variables and use shorter names for existing variables in drm_fb_helper_add_one_connector() for better readability. Tested-by: John Stultz Reviewed-by: Daniel Vetter Signed-off-by: Thierry Reding --- drivers/gpu/drm/drm_fb_helper.c | 25

[Intel-gfx] [PATCH v4 09/11] drm/hisilicon: Remove custom FB helper deferred setup

2017-03-29 Thread Thierry Reding
From: Thierry Reding The FB helper core now supports deferred setup, so the driver's custom implementation can be removed. Reviewed-by: Daniel Vetter Signed-off-by: Thierry Reding --- drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c | 21 +++-- 1 file changed, 11 insertions(+),

[Intel-gfx] [PATCH v4 11/11] drm/rockchip: Remove unnecessary NULL check

2017-03-29 Thread Thierry Reding
From: Thierry Reding The expression &private->fbdev_helper can never be NULL, so the check is completely unnecessary. Reviewed-by: Daniel Vetter Signed-off-by: Thierry Reding --- drivers/gpu/drm/rockchip/rockchip_drm_fb.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/

[Intel-gfx] [PATCH v4 06/11] drm/fb-helper: Make top-level lock more robust

2017-03-29 Thread Thierry Reding
From: Thierry Reding The existing drm_fb_helper_hotplug_event() function needs to take the top-level fb-helper lock. However, the function can also be called from code that has already taken this lock. Introduce an unlocked variant of this function that can be used in the latter case. This funct

[Intel-gfx] [PATCH v4 02/11] drm/fb-helper: Reshuffle code for subsequent patches

2017-03-29 Thread Thierry Reding
From: Thierry Reding An unlocked version of the drm_fb_helper_add_one_connector() function will be added in a subsequent patch. Reshuffle the code separately to make the diff more readable later on. Tested-by: John Stultz Reviewed-by: Daniel Vetter Signed-off-by: Thierry Reding --- drivers/g

[Intel-gfx] [PATCH v4 05/11] drm/fb-helper: Add top-level lock

2017-03-29 Thread Thierry Reding
From: Thierry Reding Introduce a new top-level lock for the FB helper code. This will allow better locking granularity and avoid the need to abuse modeset locking for this purpose instead. Tested-by: John Stultz Reviewed-by: Daniel Vetter Signed-off-by: Thierry Reding --- drivers/gpu/drm/drm

[Intel-gfx] [PATCH v4 01/11] drm/fb-helper: Cleanup checkpatch warnings

2017-03-29 Thread Thierry Reding
From: Thierry Reding Fix up a couple of checkpatch warnings, such as whitespace or coding style issues. Tested-by: John Stultz Reviewed-by: Daniel Vetter Signed-off-by: Thierry Reding --- drivers/gpu/drm/drm_fb_helper.c | 54 - 1 file changed, 32 inser

[Intel-gfx] [PATCH v4 00/11] drm/fb-helper: Deferred setup support

2017-03-29 Thread Thierry Reding
From: Thierry Reding This set of patches adds support for deferring FB helper setup, which is useful to obtain a sane configuration even when no outputs are available during probe. One example is HDMI, where fbdev will currently fallback to a 1024x786 resolution if no monitor is connected, and w

[Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915: Make legacy cursor updates more unsynced (rev2)

2017-03-29 Thread Patchwork
== Series Details == Series: drm/i915: Make legacy cursor updates more unsynced (rev2) URL : https://patchwork.freedesktop.org/series/22031/ State : success == Summary == Series 22031v2 drm/i915: Make legacy cursor updates more unsynced https://patchwork.freedesktop.org/api/1.0/series/22031/re

[Intel-gfx] ✓ Fi.CI.BAT: success for series starting with [RFC,1/3] drm/i915: Rename intel_engine_cs.exec_id to uabi_id

2017-03-29 Thread Patchwork
== Series Details == Series: series starting with [RFC,1/3] drm/i915: Rename intel_engine_cs.exec_id to uabi_id URL : https://patchwork.freedesktop.org/series/22088/ State : success == Summary == Series 22088v1 Series without cover letter https://patchwork.freedesktop.org/api/1.0/series/22088

[Intel-gfx] [PATCH v2] drm/i915: Make legacy cursor updates more unsynced

2017-03-29 Thread ville . syrjala
From: Ville Syrjälä We're clearing the legacy_cursor_update flag before calling drm_atomic_helper_setup_commit() which means the helper will wait for the flip to complete before cleaning up the framebuffers. That's not what we want for the legacy cursor, so let's clear the flag after setting up t

Re: [Intel-gfx] [PATCH] drm/atomic: Acquire connection_mutex lock in drm_helper_probe_single_connector_modes.

2017-03-29 Thread Maarten Lankhorst
Op 29-03-17 om 16:06 schreef Daniel Vetter: > On Wed, Mar 29, 2017 at 03:51:08PM +0200, Maarten Lankhorst wrote: >> Op 29-03-17 om 15:31 schreef Boris Brezillon: >>> On Wed, 29 Mar 2017 15:26:45 +0200 >>> Daniel Vetter wrote: >>> On Wed, Mar 29, 2017 at 12:16:50PM +0200, Maarten Lankhorst wro

Re: [Intel-gfx] [PATCH] drm/atomic: Acquire connection_mutex lock in drm_helper_probe_single_connector_modes.

2017-03-29 Thread Daniel Vetter
On Wed, Mar 29, 2017 at 03:51:08PM +0200, Maarten Lankhorst wrote: > Op 29-03-17 om 15:31 schreef Boris Brezillon: > > On Wed, 29 Mar 2017 15:26:45 +0200 > > Daniel Vetter wrote: > > > >> On Wed, Mar 29, 2017 at 12:16:50PM +0200, Maarten Lankhorst wrote: > >>> mode_valid() and get_modes() called >

[Intel-gfx] [RFC 1/3] drm/i915: Rename intel_engine_cs.exec_id to uabi_id

2017-03-29 Thread Chris Wilson
We want to refer to the index of the engine consistently throughout the userspace ABI. We already have such an index through the execbuffer engine specifier, that needs to be able to refer to each engine specifically. Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/i915_cmd_parser.c | 8 +

[Intel-gfx] [RFC 2/3] drm/i915: Add a routine to map from UABI id to engine

2017-03-29 Thread Chris Wilson
We have to mix a static UABI engine id with the potential for a varying hw_id and layout, and so we need a way to map from the userspace id for an engine to our internal pointers. Signed-off-by: Chris Wilson --- drivers/gpu/drm/i915/intel_engine_cs.c | 17 + drivers/gpu/drm/i915

[Intel-gfx] [RFC 3/3] drm/i915: Finally assign BSD2 its own specific UABI identifier

2017-03-29 Thread Chris Wilson
3 years too late, but hopefully better late than never, start to rectify the damage caused by commit a8ebba75b358 ("drm/i915: Use the coarse ping-pong mechanism based on drm fd to dispatch the BSD command on BDW GT3") and compounded by commit 8d360dffd6d8 ("drm/i915: Specify bsd rings through exec

Re: [Intel-gfx] [PATCH] drm/i915: Make legacy cursor updates more unsynced

2017-03-29 Thread Maarten Lankhorst
Op 28-03-17 om 21:35 schreef ville.syrj...@linux.intel.com: > From: Ville Syrjälä > > We're clearing the legacy_cursor_update flag before calling > drm_atomic_helper_setup_commit() which means the helper will > wait for the flip to complete before cleaning up the framebuffers. > That's not what we

Re: [Intel-gfx] Panic after S3 resume and modeset with MST

2017-03-29 Thread Takashi Iwai
On Wed, 29 Mar 2017 15:34:15 +0200, Ville Syrjälä wrote: > > On Wed, Mar 29, 2017 at 03:10:09PM +0200, Takashi Iwai wrote: > > On Mon, 27 Mar 2017 18:02:13 +0200, > > Takashi Iwai wrote: > > > > > > Hi, > > > > > > the upstream fix a16b7658f4e0d4aec9bc3e75a5f0cc3f7a3a0422 > > > drm/i915: Cal

Re: [Intel-gfx] [PATCH] drm/atomic: Acquire connection_mutex lock in drm_helper_probe_single_connector_modes.

2017-03-29 Thread Maarten Lankhorst
Op 29-03-17 om 15:31 schreef Boris Brezillon: > On Wed, 29 Mar 2017 15:26:45 +0200 > Daniel Vetter wrote: > >> On Wed, Mar 29, 2017 at 12:16:50PM +0200, Maarten Lankhorst wrote: >>> mode_valid() and get_modes() called >>> from drm_helper_probe_single_connector_modes() >>> may need to look at conne

Re: [Intel-gfx] [PATCH] drm/atomic: Acquire connection_mutex lock in drm_helper_probe_single_connector_modes.

2017-03-29 Thread Boris Brezillon
On Wed, 29 Mar 2017 15:26:45 +0200 Daniel Vetter wrote: > On Wed, Mar 29, 2017 at 12:16:50PM +0200, Maarten Lankhorst wrote: > > mode_valid() and get_modes() called > > from drm_helper_probe_single_connector_modes() > > may need to look at connector->state because what a valid mode is may > > dep

Re: [Intel-gfx] Panic after S3 resume and modeset with MST

2017-03-29 Thread Ville Syrjälä
On Wed, Mar 29, 2017 at 03:10:09PM +0200, Takashi Iwai wrote: > On Mon, 27 Mar 2017 18:02:13 +0200, > Takashi Iwai wrote: > > > > Hi, > > > > the upstream fix a16b7658f4e0d4aec9bc3e75a5f0cc3f7a3a0422 > > drm/i915: Call intel_dp_mst_resume() before resuming displays > > > > seems to trigger a

Re: [Intel-gfx] [PATCH] drm/atomic: Acquire connection_mutex lock in drm_helper_probe_single_connector_modes.

2017-03-29 Thread Daniel Vetter
On Wed, Mar 29, 2017 at 12:16:50PM +0200, Maarten Lankhorst wrote: > mode_valid() and get_modes() called > from drm_helper_probe_single_connector_modes() > may need to look at connector->state because what a valid mode is may > depend on connector properties being set. For example some HDMI modes >

Re: [Intel-gfx] Panic after S3 resume and modeset with MST

2017-03-29 Thread Takashi Iwai
On Mon, 27 Mar 2017 18:02:13 +0200, Takashi Iwai wrote: > > Hi, > > the upstream fix a16b7658f4e0d4aec9bc3e75a5f0cc3f7a3a0422 > drm/i915: Call intel_dp_mst_resume() before resuming displays > > seems to trigger a kernel panic when some modeset change happens after > S3 resume. The details a

[Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915/guc: Skip enabling GuC submission if the driver is wedged

2017-03-29 Thread Patchwork
== Series Details == Series: drm/i915/guc: Skip enabling GuC submission if the driver is wedged URL : https://patchwork.freedesktop.org/series/22084/ State : success == Summary == Series 22084v1 drm/i915/guc: Skip enabling GuC submission if the driver is wedged https://patchwork.freedesktop.o

Re: [Intel-gfx] [PATCH] drm/i915/guc: Skip enabling GuC submission if the driver is wedged

2017-03-29 Thread Michal Wajdeczko
On Wed, Mar 29, 2017 at 01:35:00PM +0100, Chris Wilson wrote: > If the driver is wedged, we will not be using the GPU. (Userspace will > be told NO!) As we won't be using the GPU until the wedged status is > cleared and the device restarted, we can skip enabling the guc whilst > the driver is termi

Re: [Intel-gfx] Fixes that failed to backport to v4.11-rc1

2017-03-29 Thread Jani Nikula
On Wed, 29 Mar 2017, Chris Wilson wrote: > On Wed, Mar 29, 2017 at 01:45:38PM +0300, Jani Nikula wrote: >> On Tue, 21 Mar 2017, Jani Nikula wrote: >> > On Mon, 13 Mar 2017, Jani Nikula wrote: >> >> I'm already scripting my fixes backports quite a bit, and frankly don't >> >> really manually back

[Intel-gfx] [PATCH] drm/i915/guc: Skip enabling GuC submission if the driver is wedged

2017-03-29 Thread Chris Wilson
If the driver is wedged, we will not be using the GPU. (Userspace will be told NO!) As we won't be using the GPU until the wedged status is cleared and the device restarted, we can skip enabling the guc whilst the driver is terminally wedged, and so avoid trying to use a truly wedged device. Signe

Re: [Intel-gfx] [PATCH v2] drm/i915: Avoid lock dropping between rescheduling

2017-03-29 Thread Chris Wilson
On Wed, Mar 29, 2017 at 10:33:47AM +0100, Tvrtko Ursulin wrote: > > On 27/03/2017 21:21, Chris Wilson wrote: > >Unlocking is dangerous. In this case we combine an early update to the > >out-of-queue request, because we know that it will be inserted into the > >correct FIFO priority-ordered slot wh

Re: [Intel-gfx] Fixes that failed to backport to v4.11-rc1

2017-03-29 Thread Chris Wilson
On Wed, Mar 29, 2017 at 01:45:38PM +0300, Jani Nikula wrote: > On Tue, 21 Mar 2017, Jani Nikula wrote: > > On Mon, 13 Mar 2017, Jani Nikula wrote: > >> I'm already scripting my fixes backports quite a bit, and frankly don't > >> really manually backport anything that doesn't apply cleanly. I'm >

[Intel-gfx] [PATCH] drm/i915/execlists: Wrap tail pointer after reset tweaking

2017-03-29 Thread Chris Wilson
If the request->wa_tail is 0 (because it landed exactly on the end of the ringbuffer), when we reconstruct request->tail following a reset we fill in an illegal value (-8 or 0x0018). As a result, RING_HEAD is never able to catch up with RING_TAIL and the GPU spins endlessly. If the ring contain

Re: [Intel-gfx] [PATCH v2] drm/i915/dp: Validate cached link rate and lane count before retraining

2017-03-29 Thread Jani Nikula
On Wed, 29 Mar 2017, Ville Syrjälä wrote: > On Wed, Mar 29, 2017 at 10:29:24AM +0300, Jani Nikula wrote: >> On Tue, 28 Mar 2017, Manasi Navare wrote: >> > Jani, >> > >> > Should I just hold on to this until your patch series >> > gets merged so I can rebase this on top of it? >> >> I think I'd p

Re: [Intel-gfx] [PATCH] Revert "drm/i915: Skip execlists_dequeue() early if the list is empty"

2017-03-29 Thread Chris Wilson
On Wed, Mar 29, 2017 at 12:18:57PM +0100, Chris Wilson wrote: > On Wed, Mar 29, 2017 at 11:00:52AM +0100, Chris Wilson wrote: > > This reverts commit 6c943de6686f ("drm/i915: Skip execlists_dequeue() > > early if the list is empty"). > > > > The validity of using READ_ONCE there depends upon havin

  1   2   >