Re: [Intel-gfx] [PATCH v10] drm/i915/icl: Gen11 forcewake support

2018-02-01 Thread Michel Thierry
On 2/1/2018 2:25 AM, Tvrtko Ursulin wrote: On 01/02/2018 00:52, Michel Thierry wrote: From: Daniele Ceraolo Spurio The main difference with previous GENs is that starting from Gen11 each VCS and VECS engine has its own power well, which only exist if the related engine exists in the HW. The

[Intel-gfx] [PATCH v11] drm/i915/icl: Gen11 forcewake support

2018-02-01 Thread Michel Thierry
tko Ursulin Cc: Paulo Zanoni Acked-by: Michel Thierry Signed-off-by: Daniele Ceraolo Spurio Signed-off-by: Oscar Mateo Signed-off-by: Michel Thierry Reviewed-by: Tvrtko Ursulin --- drivers/gpu/drm/i915/i915_reg.h | 4 + drivers/gpu/drm/i915/intel_uncore.c |

Re: [Intel-gfx] [PATCH] drm/i915/execlists: Flush GTIIR on clearing CS interrupts during reset

2018-02-02 Thread Michel Thierry
hopefully reduces the frequency to 0... References: https://bugs.freedesktop.org/show_bug.cgi?id=104262 Signed-off-by: Chris Wilson Cc: Mika Kuoppala Cc: Michel Thierry Cc: Tvrtko Ursulin --- drivers/gpu/drm/i915/intel_lrc.c | 13 + 1 file changed, 9 insertions(+), 4 deletions

Re: [Intel-gfx] [PATCH v2 3/3] drm/i915: Only allocate preempt context when required

2018-02-07 Thread Michel Thierry
e was missing a r-b, but all 3: Reviewed-by: Michel Thierry --- drivers/gpu/drm/i915/i915_gem_context.c | 31 drivers/gpu/drm/i915/intel_engine_cs.c | 6 ++--- drivers/gpu/drm/i915/intel_guc_submission.c | 24 +- drivers/gpu/drm

Re: [Intel-gfx] [PATCH v9 1/7] drm/i915/guc: Move GuC WOPCM related code into separate files

2018-02-09 Thread Michel Thierry
On 2/9/2018 11:38 AM, Yaodong Li wrote: On 02/09/2018 08:46 AM, Michal Wajdeczko wrote: --- /dev/null +++ b/drivers/gpu/drm/i915/intel_guc_wopcm.c @@ -0,0 +1,48 @@ +/* + * SPDX-License-Identifier: MIT + * + * Copyright © 2017-2018 Intel Corporation + * Do we really want to keep legacy license

Re: [Intel-gfx] [PATCH i-g-t 3/8] lib: Define a common bit operations library

2017-03-01 Thread Michel Thierry
On 2/27/2017 1:35 AM, Daniel Vetter wrote: On Thu, Feb 09, 2017 at 09:34:49AM +0200, Joonas Lahtinen wrote: On ke, 2017-02-08 at 18:18 -0800, Michel Thierry wrote: Bring the test/set/clear bit functions we have into a single place. Signed-off-by: Michel Thierry Reviewed-by: Joonas

[Intel-gfx] [PATCH i-g-t v2] lib: Define a common bit operations library

2017-03-01 Thread Michel Thierry
Bring the test/set/clear bit functions we have into a single place. v2: Add gtk-doc comment blocks (Daniel) Cc: Daniel Vetter Reviewed-by: Joonas Lahtinen (v1) Signed-off-by: Michel Thierry --- .../intel-gpu-tools/intel-gpu-tools-docs.xml | 1 + lib/Makefile.sources

Re: [Intel-gfx] [PATCH i-g-t v2] lib: Define a common bit operations library

2017-03-02 Thread Michel Thierry
On 01/03/17 23:45, Daniel Vetter wrote: On Wed, Mar 01, 2017 at 04:14:31PM +, Chris Wilson wrote: On Wed, Mar 01, 2017 at 07:52:26AM -0800, Michel Thierry wrote: Bring the test/set/clear bit functions we have into a single place. v2: Add gtk-doc comment blocks (Daniel) Hiss, boo! Will

[Intel-gfx] [PATCH i-g-t v3] lib: Define a common bit operations library

2017-03-02 Thread Michel Thierry
Bring the test/set/clear bit functions we have into a single place. v2: Add gtk-doc comment blocks (Daniel) v3: Restore inline keyword. Cc: Daniel Vetter Reviewed-by: Joonas Lahtinen (v1) Signed-off-by: Michel Thierry --- .../intel-gpu-tools/intel-gpu-tools-docs.xml | 1 + lib

[Intel-gfx] [PATCH i-g-t] lib/igt_gt: Remove duplicated PARAM_NO_ERROR_CAPTURE define

2017-03-06 Thread Michel Thierry
LOCAL_CONTEXT_PARAM_NO_ERROR_CAPTURE exists in lib/ioctl_wrappers.h since commit 171b21d9f761 ("igt/gem_ctx_param: Update invalid parma number"). Cc: Chris Wilson Signed-off-by: Michel Thierry --- lib/igt_gt.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/lib/igt_gt.c b/li

[Intel-gfx] [PATCH] drm/i915: get a runtime PM ref in i915_wedged_set

2017-03-13 Thread Michel Thierry
). Reported-by: Antonio Argenziano Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_debugfs.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c index 9fcc4f1a86fc..89f211391ef9 100644 --- a/drive

Re: [Intel-gfx] [PATCH] drm/i915: get a runtime PM ref in i915_wedged_set

2017-03-14 Thread Michel Thierry
On 3/14/2017 2:09 AM, Chris Wilson wrote: On Mon, Mar 13, 2017 at 05:26:06PM -0700, Michel Thierry wrote: At least in bxt (with decoupled mmio), it prevents a warning while capturing the reg state: [ ] WARNING: assert_rpm_wakelock_held.part.4+0x1e/0x20 [i915] [ ] RPM wakelock ref not held

Re: [Intel-gfx] [PATCH] drm/i915: Extend rpm wakelock during i915_handle_error()

2017-03-14 Thread Michel Thierry
. Reported-by: Antonio Argenziano Signed-off-by: Chris Wilson Cc: Michel Thierry --- drivers/gpu/drm/i915/i915_irq.c | 25 ++--- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/drivers/gpu/drm/i915/i915_irq.c b/drivers/gpu/drm/i915/i915_irq.c index

[Intel-gfx] [PATCH v5 18/18] drm/i915: Watchdog timeout: Export media reset count from GuC to debugfs

2017-03-24 Thread Michel Thierry
, provide a simple debugfs entry to see the number of times media reset has happened. Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_debugfs.c | 28 drivers/gpu/drm/i915/intel_guc_fwif.h | 18 ++ 2 files changed, 46 insertions(+) diff --git a

[Intel-gfx] [PATCH v5 15/18] drm/i915: Watchdog timeout: IRQ handler for gen8+

2017-03-24 Thread Michel Thierry
he counter is different between render and non-render engines. v2: Move irq handler to tasklet, arm watchdog for a 2nd time to check against false-positives. Signed-off-by: Tomas Elf Signed-off-by: Ian Lister Signed-off-by: Arun Siluvery Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/

[Intel-gfx] [PATCH v5 14/18] drm/i915: Watchdog timeout: Pass GuC shared data structure during param load

2017-03-24 Thread Michel Thierry
For watchdog / media reset, the firmware must know the address of the shared data page (the first page of the default context). This information should be in DWORD 9 of the GUC_CTL structure. Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/intel_guc_fwif.h | 2 +- drivers/gpu/drm/i915

[Intel-gfx] [PATCH v5 04/18] drm/i915/tdr: Modify error handler for per engine hang recovery

2017-03-24 Thread Michel Thierry
Mika Kuoppala Signed-off-by: Ian Lister Signed-off-by: Tomas Elf Signed-off-by: Arun Siluvery Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_drv.c | 49 +++- drivers/gpu/drm/i915/i915_drv.h | 7 +++- drivers/gpu/drm

[Intel-gfx] [PATCH v5 12/18] drm/i915/guc: Provide register list to be saved/restored during engine reset

2017-03-24 Thread Michel Thierry
is is the minimal set of registers identified for things to work as expected but if we see any new issues, this register list can be expanded. Signed-off-by: Arun Siluvery Signed-off-by: Jeff McGee Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_guc_submission.c

[Intel-gfx] [PATCH v5 06/18] drm/i915: Skip reset request if there is one already

2017-03-24 Thread Michel Thierry
unnecessary. To avoid this we check if the engine is already prepared, if so we just exit from that point. Cc: Chris Wilson Signed-off-by: Mika Kuoppala Signed-off-by: Arun Siluvery Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/intel_uncore.c | 9 +++-- 1 file changed, 7 insertions

[Intel-gfx] [PATCH v5 08/18] drm/i915/tdr: Export per-engine reset count info to debugfs

2017-03-24 Thread Michel Thierry
engine count in i915_engine_info too (Chris). Cc: Chris Wilson Cc: Mika Kuoppala Signed-off-by: Arun Siluvery Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_debugfs.c | 21 + 1 file changed, 21 insertions(+) diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b

[Intel-gfx] [PATCH v5 09/18] drm/i915/tdr: Enable Engine reset and recovery support

2017-03-24 Thread Michel Thierry
From: Arun Siluvery This feature is made available only from Gen8, for previous gen devices driver uses legacy full gpu reset. Cc: Chris Wilson Cc: Mika Kuoppala Signed-off-by: Tomas Elf Signed-off-by: Arun Siluvery Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_params.c | 4

[Intel-gfx] [PATCH v5 02/18] drm/i915: Rename gen8_(un)request_engine_reset to gen8_(un)request_reset_engine

2017-03-24 Thread Michel Thierry
As all other functions related to resetting engines are using reset_engine. Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/intel_uncore.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/i915/intel_uncore.c b/drivers/gpu/drm/i915

[Intel-gfx] [PATCH v5 16/18] drm/i915: Watchdog timeout: Ringbuffer command emission for gen8+

2017-03-24 Thread Michel Thierry
of combined start_watchdog, bb_start and stop_watchdog to avoid any error after emitting bb_start. Signed-off-by: Tomas Elf Signed-off-by: Ian Lister Signed-off-by: Arun Siluvery Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_gem_context.h | 4 ++ drivers/gpu/drm/i915/intel_lrc.c

[Intel-gfx] [PATCH v5 17/18] drm/i915: Watchdog timeout: DRM kernel interface to set the timeout

2017-03-24 Thread Michel Thierry
updated to be per context engine. Check for u32 overflow. Capture ctx threshold value in error state. Signed-off-by: Tomas Elf Signed-off-by: Arun Siluvery Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_drv.h | 1 + drivers/gpu/drm/i915/i915_gem_cont

[Intel-gfx] [PATCH v5 10/18] drm/i915: Add engine reset count in get-reset-stats ioctl

2017-03-24 Thread Michel Thierry
it is deemed useful, it can be extended to report each engine separately. v2: s/engine_reset/reset_engine/, use union in uapi to not break compatibility. Cc: Chris Wilson Cc: Mika Kuoppala Cc: mesa-...@lists.freedesktop.org Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915

[Intel-gfx] [PATCH v5 05/18] drm/i915/tdr: Add support for per engine reset recovery

2017-03-24 Thread Michel Thierry
i915_gem_reset_engine (Chris). v4: Rebase, modify i915_gem_reset_prepare to use a ring mask and reuse the function for reset_engine. Cc: Chris Wilson Cc: Mika Kuoppala Signed-off-by: Tomas Elf Signed-off-by: Arun Siluvery Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_drv.c | 88

[Intel-gfx] [PATCH v5 03/18] drm/i915: Update i915.reset to handle engine resets

2017-03-24 Thread Michel Thierry
From: Arun Siluvery In preparation for engine reset work update this parameter to handle more than one type of reset. Default at the moment is still full gpu reset. Cc: Chris Wilson Cc: Mika Kuoppala Signed-off-by: Arun Siluvery Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915

[Intel-gfx] [PATCH v5 00/18] Gen8+ engine-reset

2017-03-24 Thread Michel Thierry
ngine reset count to error state drm/i915/tdr: Export per-engine reset count info to debugfs drm/i915/tdr: Enable Engine reset and recovery support drm/i915/guc: Provide register list to be saved/restored during engine reset Michel Thierry (10): drm/i915: Fix stale comment

[Intel-gfx] [PATCH v5 01/18] drm/i915: Fix stale comment about I915_RESET_IN_PROGRESS flag

2017-03-24 Thread Michel Thierry
It has been replaced by I915_RESET_BACKOFF / I915_RESET_HANDOFF. Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_drv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h index e8250bb79d12

[Intel-gfx] [PATCH v5 07/18] drm/i915/tdr: Add engine reset count to error state

2017-03-24 Thread Michel Thierry
. v2: s/engine_reset/reset_engine/ (Chris) Define count as unsigned int (Tvrtko) Cc: Chris Wilson Cc: Mika Kuoppala Signed-off-by: Arun Siluvery Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_drv.c | 2 ++ drivers/gpu/drm/i915/i915_drv.h | 8 drivers/gpu/drm

[Intel-gfx] [PATCH v5 11/18] drm/i915/selftests: reset engine self tests

2017-03-24 Thread Michel Thierry
Check that we can reset specific engines, also check the fallback to full reset if something didn't work. Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/selftests/intel_hangcheck.c | 144 +++ 1 file changed, 144 insertions(+) diff --git a/drivers/gpu/drm

[Intel-gfx] [PATCH v5 13/18] drm/i915/guc: Add support for reset engine using GuC commands

2017-03-24 Thread Michel Thierry
requests are pending so after resetting a engine, pending workloads/requests are resubmitted again. Signed-off-by: Arun Siluvery Signed-off-by: Jeff McGee Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_drv.c| 43 +- drivers/gpu/drm/i915/i915_drv.h

Re: [Intel-gfx] [PATCH v5 02/18] drm/i915: Rename gen8_(un)request_engine_reset to gen8_(un)request_reset_engine

2017-03-27 Thread Michel Thierry
On 25/03/17 02:01, Chris Wilson wrote: On Fri, Mar 24, 2017 at 06:29:54PM -0700, Michel Thierry wrote: As all other functions related to resetting engines are using reset_engine. However, we should aim to clear any confusion between this and our requests. Maybe gen8_reset_engine_start and

Re: [Intel-gfx] [PATCH v5 15/18] drm/i915: Watchdog timeout: IRQ handler for gen8+

2017-03-27 Thread Michel Thierry
On 25/03/17 02:26, Chris Wilson wrote: On Fri, Mar 24, 2017 at 06:30:07PM -0700, Michel Thierry wrote: diff --git a/drivers/gpu/drm/i915/i915_irq.c b/drivers/gpu/drm/i915/i915_irq.c index 87e76ef589b1..d484cbc561eb 100644 --- a/drivers/gpu/drm/i915/i915_irq.c +++ b/drivers/gpu/drm/i915

Re: [Intel-gfx] [PATCH v5 17/18] drm/i915: Watchdog timeout: DRM kernel interface to set the timeout

2017-03-27 Thread Michel Thierry
On 25/03/17 02:38, Chris Wilson wrote: On Fri, Mar 24, 2017 at 06:30:09PM -0700, Michel Thierry wrote: Final enablement patch for GPU hang detection using watchdog timeout. Using the gem_context_setparam ioctl, users can specify the desired timeout value in microseconds, and the driver will do

Re: [Intel-gfx] [PATCH 6/9] drm/i915/tdr: Add engine reset count to error state

2016-12-19 Thread Michel Thierry
On 19/12/16 00:27, Tvrtko Ursulin wrote: On 16/12/2016 20:20, Michel Thierry wrote: From: Arun Siluvery @@ -937,6 +937,7 @@ struct drm_i915_error_state { enum intel_engine_hangcheck_action hangcheck_action; struct i915_address_space *vm; int num_requests

Re: [Intel-gfx] [PATCH 4/9] drm/i915/tdr: Add support for per engine reset recovery

2017-01-05 Thread Michel Thierry
On 19/12/16 01:51, Chris Wilson wrote: On Sun, Dec 18, 2016 at 09:02:33PM -0800, Michel Thierry wrote: On 12/16/2016 12:45 PM, Chris Wilson wrote: On Fri, Dec 16, 2016 at 12:20:05PM -0800, Michel Thierry wrote: From: Arun Siluvery This change implements support for per-engine reset as an

[Intel-gfx] [PATCH 09/10] drm/i915/tdr: Enable Engine reset and recovery support

2017-01-11 Thread Michel Thierry
From: Arun Siluvery This feature is made available only from Gen8, for previous gen devices driver uses legacy full gpu reset. Cc: Chris Wilson Cc: Mika Kuoppala Signed-off-by: Tomas Elf Signed-off-by: Arun Siluvery Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_params.c | 4

[Intel-gfx] [PATCH 05/10] drm/i915/tdr: Add support for per engine reset recovery

2017-01-11 Thread Michel Thierry
i915_gem_reset_engine (Chris). Cc: Chris Wilson Cc: Mika Kuoppala Signed-off-by: Tomas Elf Signed-off-by: Arun Siluvery Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_drv.c | 69 +++-- drivers/gpu/drm/i915/i915_drv.h | 3 ++ drivers/gpu/drm/i915

[Intel-gfx] [PATCH 06/10] drm/i915: Skip reset request if there is one already

2017-01-11 Thread Michel Thierry
unnecessary. To avoid this we check if the engine is already prepared, if so we just exit from that point. Cc: Chris Wilson Signed-off-by: Mika Kuoppala Signed-off-by: Arun Siluvery Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/intel_uncore.c | 9 +++-- 1 file changed, 7 insertions

[Intel-gfx] [PATCH v4 00/10] Execlist based engine-reset (v4)

2017-01-11 Thread Michel Thierry
: Enable Engine reset and recovery support Michel Thierry (3): drm/i915: Keep i915_handle_error kerneldoc parameters together drm/i915: Update i915_reset parameter for kerneldoc drm/i915: Add engine reset count in get-reset-stats ioctl Mika Kuoppala (1): drm/i915: Skip reset request if there

[Intel-gfx] [PATCH 07/10] drm/i915/tdr: Add engine reset count to error state

2017-01-11 Thread Michel Thierry
. v2: s/engine_reset/reset_engine/ (Chris) Define count as unsigned int (Tvrtko) Cc: Chris Wilson Cc: Mika Kuoppala Signed-off-by: Arun Siluvery Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_drv.c | 1 + drivers/gpu/drm/i915/i915_drv.h | 8 drivers/gpu/drm

[Intel-gfx] [PATCH 01/10] drm/i915: Keep i915_handle_error kerneldoc parameters together

2017-01-11 Thread Michel Thierry
And before the function description. Tidy up from commit 14bb2c11796d70b ("drm/i915: Fix a buch of kerneldoc warnings"), all others kerneldoc blocks look ok. Cc: Tvrtko Ursulin Reviewed-by: Chris Wilson Reviewed-by: Tvrtko Ursulin Signed-off-by: Michel Thierry --- drivers/gp

[Intel-gfx] [PATCH 03/10] drm/i915: Update i915.reset to handle engine resets

2017-01-11 Thread Michel Thierry
From: Arun Siluvery In preparation for engine reset work update this parameter to handle more than one type of reset. Default at the moment is still full gpu reset. Cc: Chris Wilson Cc: Mika Kuoppala Signed-off-by: Arun Siluvery Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915

[Intel-gfx] [PATCH 08/10] drm/i915/tdr: Export per-engine reset count info to debugfs

2017-01-11 Thread Michel Thierry
engine count in i915_engine_info too (Chris). Cc: Chris Wilson Cc: Mika Kuoppala Signed-off-by: Arun Siluvery Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_debugfs.c | 21 + 1 file changed, 21 insertions(+) diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b

[Intel-gfx] [PATCH 02/10] drm/i915: Update i915_reset parameter for kerneldoc

2017-01-11 Thread Michel Thierry
Since commit c033666a94b57 ("drm/i915: Store a i915 backpointer from engine, and use it") i915_reset receives dev_priv, but the kerneldoc was not updated. Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_drv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) di

[Intel-gfx] [PATCH 10/10] drm/i915: Add engine reset count in get-reset-stats ioctl

2017-01-11 Thread Michel Thierry
it is deemed useful, it can be extended to report each engine separately. v2: s/engine_reset/reset_engine/. Cc: Chris Wilson Cc: Mika Kuoppala Cc: mesa-...@lists.freedesktop.org Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_gem_context.c | 14 +++--- include/uapi/drm

[Intel-gfx] [PATCH 04/10] drm/i915/tdr: Modify error handler for per engine hang recovery

2017-01-11 Thread Michel Thierry
Chris) Handle reset as 2 level resets, by first going to engine only and fall backing to full/chip reset as needed, i.e. reset_engine will need the struct_mutex. Cc: Chris Wilson Cc: Mika Kuoppala Signed-off-by: Ian Lister Signed-off-by: Tomas Elf Signed-off-by: Arun Siluvery Signed-off-by: M

Re: [Intel-gfx] [PATCH v4 00/10] Execlist based engine-reset (v4)

2017-01-12 Thread Michel Thierry
On 11/01/17 23:30, Chris Wilson wrote: I'm sorry to do this, but there is a regression fix for gen3 required first that makes this more complicated. https://cgit.freedesktop.org/~ickle/linux-2.6/commit/?h=prescheduler&id=de399a0a6baae97910796d81d8b9324db3fdd77c https://cgit.freedesktop.org/~ick

[Intel-gfx] [PATCH] drm/i915: Implement WaDisableFenceDestinationToSLM:bdw

2014-06-04 Thread michel . thierry
From: Michel Thierry HDC_CHICKEN0 bit 14 (Fence Destination To SLM Disable) must be programmed by software to 1h (Disable) to work around a LSLM unit issue. WaDisableFenceDestinationToSLM is only needed for BDW E,F step. Issue: APDEV-3096 Signed-off-by: Michel Thierry --- drivers/gpu/drm

Re: [Intel-gfx] [PATCH 2/2] drm/i915/gen8: Apply Per-context workarounds using W/A batch buffers

2015-03-02 Thread Michel Thierry
On 25/02/15 17:54, Arun Siluvery wrote: Some of the workarounds are to be applied during context save but before restore and some at the end of context save/restore but before executing the instructions in the ring. Workaround batch buffers are created for this purpose as they cannot be applied

[Intel-gfx] [PATCH 1/5] drm/i915: page table generalizations

2015-03-16 Thread Michel Thierry
No functional changes, but will improve code clarity and removed some duplicated defines. Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_gem_gtt.c | 160 ++-- drivers/gpu/drm/i915/i915_gem_gtt.h | 28 --- 2 files changed, 96 insertions(+), 92

[Intel-gfx] [PATCH 5/5] drm/i915: Initialize all contexts

2015-03-16 Thread Michel Thierry
refore, we also must reinitialize. v2: to->ppgtt is only valid in full ppgtt. v3: Rebased. v4: Make post PDP update clearer. Signed-off-by: Ben Widawsky Signed-off-by: Michel Thierry (v2+) --- drivers/gpu/drm/i915/i915_gem_context.c | 28 +++- 1 file changed, 19 insertions(+

[Intel-gfx] [PATCH 2/5] drm/i915: Extract context switch skip and add pd load logic

2015-03-16 Thread Michel Thierry
l) v3: Add missing pd load logic. v4: Add warning in case pd_load_pre & pd_load_post are true, and add missing trace_switch_mm. Cleaned up pd_load conditions. Add more information about when is pd_load_post needed. (Mika) Signed-off-by: Ben Widawsky Signed-off-by: Michel Thierry (v2+) --- driver

[Intel-gfx] [PATCH 3/5] drm/i915: Track GEN6 page table usage

2015-03-16 Thread Michel Thierry
ise bitmap allocation here (gen6_alloc_va_range) and fix incorrect write_page_range in i915_gem_restore_gtt_mappings (Mika). Cc: Daniel Vetter Cc: Mika Kuoppala Signed-off-by: Ben Widawsky Signed-off-by: Michel Thierry (v3+) --- drivers/gpu/drm/i915/i915_gem.c | 9 ++ drivers/gpu/drm/i915/i915

[Intel-gfx] [PATCH 4/5] drm/i915: Track page table reload need

2015-03-16 Thread Michel Thierry
to i915_hw_ppgtt. Fixes when neither ctx->ppgtt and aliasing_ppgtt exist. v5: Removed references to teardown_va_range. v6: Updated needs_pd_load_pre/post. Signed-off-by: Ben Widawsky Signed-off-by: Michel Thierry (v2+) --- drivers/gpu/drm/i915/i915_gem_context.c| 26

[Intel-gfx] [PATCH 0/5] Gen6/7 PPGTT dynamic page alloc prep work

2015-03-16 Thread Michel Thierry
ld help to clean some of the code. Ben Widawsky (4): drm/i915: Extract context switch skip and add pd load logic drm/i915: Track GEN6 page table usage drm/i915: Track page table reload need drm/i915: Initialize all contexts Michel Thierry (1): drm/i915: page table generalizations drive

Re: [Intel-gfx] [PATCH 01/12] drm/i915/bdw: Make pdp allocation more dynamic

2015-03-18 Thread Michel Thierry
On 3/3/2015 11:48 AM, akash goel wrote: On Fri, Feb 20, 2015 at 11:15 PM, Michel Thierry wrote: From: Ben Widawsky This transitional patch doesn't do much for the existing code. However, it should make upcoming patches to use the full 48b address space a bit easier to swallow. The patch

Re: [Intel-gfx] [PATCH 02/12] drm/i915/bdw: Abstract PDP usage

2015-03-18 Thread Michel Thierry
On 3/3/2015 12:16 PM, akash goel wrote: On Fri, Feb 20, 2015 at 11:15 PM, Michel Thierry wrote: From: Ben Widawsky Up until now, ppgtt->pdp has always been the root of our page tables. Legacy 32b addresses acted like it had 1 PDP with 4 PDPEs. In preparation for 4 level page tables, we n

Re: [Intel-gfx] [PATCH 04/12] drm/i915/bdw: Add ppgtt info for dynamic pages

2015-03-18 Thread Michel Thierry
On 3/3/2015 12:23 PM, akash goel wrote: On Fri, Feb 20, 2015 at 11:15 PM, Michel Thierry wrote: From: Ben Widawsky Note that there is no gen8 ppgtt debug_dump function yet. Signed-off-by: Ben Widawsky Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_debugfs.c | 19

Re: [Intel-gfx] [PATCH 4/5] drm/i915: Track page table reload need

2015-03-19 Thread Michel Thierry
On 3/19/2015 9:01 AM, Mika Kuoppala wrote: Michel Thierry writes: From: Ben Widawsky This patch was formerly known as, "Force pd restore when PDEs change, gen6-7." I had to change the name because it is needed for GEN8 too. The real issue this is trying to solve is when a new

[Intel-gfx] [PATCH] drm/i915: Track page table reload need

2015-03-19 Thread Michel Thierry
Signed-off-by: Ben Widawsky Signed-off-by: Michel Thierry (v2+) --- drivers/gpu/drm/i915/i915_gem.c| 4 drivers/gpu/drm/i915/i915_gem_context.c| 26 -- drivers/gpu/drm/i915/i915_gem_execbuffer.c | 7 +++ drivers/gpu/drm/i915/i915_gem_gtt.c

[Intel-gfx] [PATCH] drm/i915: Do not leak objects after capturing error state

2015-03-19 Thread Michel Thierry
bjects are allocated in i915_gem_capture_buffers, but not released in i915_error_state_free: - error->active_bo_count - error->pinned_bo - error->pinned_bo_count - error->active_bo[vm_count] (allocated in i915_gem_capture_vm). Signed-off-by: Michel Thierry --- drivers/gpu/drm

Re: [Intel-gfx] [PATCH 3/5] drm/i915: Track GEN6 page table usage

2015-03-19 Thread Michel Thierry
On 3/19/2015 4:13 PM, Daniel Vetter wrote: On Mon, Mar 16, 2015 at 04:00:56PM +, Michel Thierry wrote: +static inline uint32_t i915_pte_count(uint64_t addr, size_t length, + uint32_t pde_shift) +{ + const uint64_t mask = ~((1 << pde_shif

Re: [Intel-gfx] [PATCH] drm/i915: Do not leak objects after capturing error state

2015-03-19 Thread Michel Thierry
On 3/19/2015 5:18 PM, Chris Wilson wrote: On Thu, Mar 19, 2015 at 05:11:17PM +, Michel Thierry wrote: diff --git a/drivers/gpu/drm/i915/i915_gpu_error.c b/drivers/gpu/drm/i915/i915_gpu_error.c index bbf25d0..18f7a2a 100644 --- a/drivers/gpu/drm/i915/i915_gpu_error.c +++ b/drivers/gpu/drm

[Intel-gfx] [PATCH v2] drm/i915: Do not leak objects after capturing error state

2015-03-20 Thread Michel Thierry
e introduced by commit 95f5301dd880da2dea2c9a9c29750064536d426a Author: Ben Widawsky Date: Wed Jul 31 17:00:15 2013 -0700 drm/i915: Update error capture for VMs v2: Reuse iterator and add culprit commit details (Chris) Cc: Chris Wilson Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_gpu_error.c | 7 +++ 1 file

Re: [Intel-gfx] [PATCH] drm/i915: Add fault address to error state for gen8 and gen9

2015-03-24 Thread Michel Thierry
lle) Signed-off-by: Mika Kuoppala --- drivers/gpu/drm/i915/i915_drv.h | 2 ++ drivers/gpu/drm/i915/i915_gpu_error.c | 10 ++ drivers/gpu/drm/i915/i915_reg.h | 3 +++ 3 files changed, 15 insertions(+) Thanks for noticing that last typo... Reviewed-by: Michel Thie

[Intel-gfx] [PATCH 1/5] drm/i915: Prevent out of range pt in gen6_for_each_pde

2015-03-24 Thread Michel Thierry
Found by static analysis tool, this was harmless as the pt was not used out of scope though. Introduced by commit 678d96fbb3b5995a2fdff2bca5e1ab4a40b7e968 ("drm/i915: Track GEN6 page table usage"). Cc: Mika Kuoppala Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_gem

[Intel-gfx] [PATCH 0/5] Finish gen6/7 ppgtt dynamic page allocations

2015-03-24 Thread Michel Thierry
The first 2 patches are fixes from the previous patchset, reported by static analysis tools, while the last 2 patches complete the required work for gen6/7. I've also started changing the authorship of the patches as suggested by Daniel. Michel Thierry (5): drm/i915: Prevent out of range

[Intel-gfx] [PATCH 5/5] drm/i915: Add dynamic page trace events

2015-03-24 Thread Michel Thierry
Traces for page directories and tables allocation and map. v2: Removed references to teardown. v3: bitmap_scnprintf has been deprecated. v4: Replace bitmap_scnprintf with scnprintf correctly, and get right range lengths. (Mika) Cc: Mika Kuoppala Signed-off-by: Michel Thierry --- drivers/gpu

[Intel-gfx] [PATCH 2/5] drm/i915: i915_dma_map_single returns positive error codes

2015-03-24 Thread Michel Thierry
i915_dma_map_single relies on dma_mapping_error, which returns positive error codes. Found by static checker. Introduced by commit 678d96fbb3b5995a2fdff2bca5e1ab4a40b7e968 ("drm/i915: Track GEN6 page table usage"). Cc: Dan Carpenter Cc: Mika Kuoppala Signed-off-by: Michel Thierry --

[Intel-gfx] [PATCH 4/5] drm/i915: Finish gen6/7 dynamic page table allocation

2015-03-24 Thread Michel Thierry
d alloc_pt_scratch becomes redundant. Initialize scratch_pt and pt. (Mika) v10: Clean up aliasing ppgtt init error path and prevent leaking the ppgtt obj when init fails. (Mika) Updated commit author. (Daniel) Cc: Mika Kuoppala Signed-off-by: Ben Widawsky Signed-off-by: Michel Thierry (v4+) --- dr

[Intel-gfx] [PATCH 3/5] drm/i915: Remove unnecessary gen6_ppgtt_unmap_pages

2015-03-24 Thread Michel Thierry
We are already unmapping them in gen6_ppgtt_free. This function became redundant since commit 06fda602dbca9c59d87db7da71192e4b54c9f5ff ("drm/i915: Create page table allocators"). Cc: Mika Kuoppala Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_gem_gtt.c | 11 -

Re: [Intel-gfx] [PATCH 2/5] drm/i915: i915_dma_map_single returns positive error codes

2015-03-24 Thread Michel Thierry
On 3/24/2015 4:03 PM, Dan Carpenter wrote: On Tue, Mar 24, 2015 at 06:57:13PM +0300, Dan Carpenter wrote: diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c index 645c363..79ade6f 100644 --- a/drivers/gpu/drm/i915/i915_gem_gtt.c +++ b/drivers/gpu/drm/i915/i91

[Intel-gfx] [PATCH v2] drm/i915: Fix i915_dma_map_single positive error code

2015-03-24 Thread Michel Thierry
Carpenter Cc: Mika Kuoppala Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_gem_gtt.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c index 645c363..6bb31c8 100644 --- a/drivers/gp

[Intel-gfx] [PATCH v3] drm/i915: Fix i915_dma_map_single positive error code

2015-03-24 Thread Michel Thierry
3: Missing reported-by tag (Daniel) Reported-by: Dan Carpenter Cc: Dan Carpenter Cc: Mika Kuoppala Cc: Daniel Vetter Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_gem_gtt.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/d

Re: [Intel-gfx] [PATCH 1/3] tools/intel_error_decode: Add ERROR decodings for gen8

2015-03-25 Thread Michel Thierry
se 7: return print_ivb_error(reg, devid); case 6: return print_snb_error(reg); } -- 1.9.1 Looks good (I don't expect to see these PASID errors soon). Reviewed-by: Michel Thierry ___ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/intel-gfx

Re: [Intel-gfx] [PATCH 2/3] tools/intel_error_decode: Add decodings for FAULT_REG

2015-03-25 Thread Michel Thierry
("Source ID %d\n", reg >> 3 & 0xff); +} + #define MAX_RINGS 10 /* I really hope this never... */ uint32_t head[MAX_RINGS]; int head_ndx = 0; @@ -520,6 +558,10 @@ read_data_file(FILE *file) if (matched == 2) print_f

Re: [Intel-gfx] [PATCH 3/3] tools/intel_error_decode: Add gen8+ fault data encodings

2015-03-25 Thread Michel Thierry
print_fault_reg(devid, reg); + matched = sscanf(line, " FAULT_TLB_DATA: 0x%08x 0x%08x\n", ®, ®2); + if (matched == 2) + print_fault_data(devid, reg, reg2); + continue;

Re: [Intel-gfx] [PATCH] drm/i915: fix simple_return.cocci warnings

2015-03-27 Thread Michel Thierry
/coccinelle/misc/simple_return.cocci CC: Michel Thierry Signed-off-by: Fengguang Wu --- i915_gem_gtt.c |8 +--- 1 file changed, 1 insertion(+), 7 deletions(-) --- a/drivers/gpu/drm/i915/i915_gem_gtt.c +++ b/drivers/gpu/drm/i915/i915_gem_gtt.c @@ -1344,13 +1344,7 @@ err_out: static

[Intel-gfx] [PATCH 04/13] drm/i915/gen8: Add dynamic allocation macros and helper functions

2015-04-08 Thread Michel Thierry
/page_table/. v7: Renamed commit to match what it does now (it was "Use dynamic allocation idioms on free"). v8: Prevent (harmless) out of range access in gen8_for_each_pde and gen8_for_each_pdpe_e. Signed-off-by: Ben Widawsky Signed-off-by: Michel Thierry (v2+) --- drivers/gp

[Intel-gfx] [PATCH 06/13] drm/i915/gen8: pagetable allocation rework

2015-04-08 Thread Michel Thierry
: Initialize all page tables, including the extra ones from systems with less than 4GB of memory. (Mika) Cc: Mika Kuoppala Signed-off-by: Ben Widawsky Signed-off-by: Michel Thierry (v2+) --- drivers/gpu/drm/i915/i915_gem_gtt.c | 83 ++--- 1 file changed, 59 insertions

[Intel-gfx] [PATCH 07/13] drm/i915/gen8: Update pdp switch and point unused PDPs to scratch page

2015-04-08 Thread Michel Thierry
awsky Signed-off-by: Michel Thierry (v2+) --- drivers/gpu/drm/i915/i915_gem_gtt.c | 32 +--- drivers/gpu/drm/i915/i915_gem_gtt.h | 1 + 2 files changed, 22 insertions(+), 11 deletions(-) diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm

[Intel-gfx] [PATCH 03/13] drm/i915/gen8: Initialize page tables

2015-04-08 Thread Michel Thierry
) Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_gem_gtt.c | 22 +- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c index 8e47caf..cd28e343 100644 --- a/drivers/gpu/drm/i915

[Intel-gfx] [PATCH 01/13] drm/i915: Remove _entry from PPGTT page structures

2015-04-08 Thread Michel Thierry
i915_page_directory/ s/struct i915_page_directory_pointer_entry/struct i915_page_directory_pointer/ Suggested-by: Mika Kuoppala Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_gem_gtt.c | 56 ++--- drivers/gpu/drm/i915/i915_gem_gtt.h | 16 +-- drivers/gpu

[Intel-gfx] [PATCH 00/13] gen8 ppgtt dynamic page allocations

2015-04-08 Thread Michel Thierry
ce address range in these systems. Michel Thierry (13): drm/i915: Remove _entry from PPGTT page structures drm/i915: Remove unnecessary gen8_ppgtt_unmap_pages drm/i915/gen8: Initialize page tables drm/i915/gen8: Add dynamic allocation macros and helper functions drm/i915/gen8: page director

[Intel-gfx] [PATCH 12/13] drm/i915/gen8: Dynamic page table allocations

2015-04-08 Thread Michel Thierry
ft broken until it was updated to handle the init case without any PDP. v12: Do not overallocate new_pts bitmap, make alloc_gen8_temp_bitmaps static and don't abuse of inline functions. (Mika) Cc: Mika Kuoppala Signed-off-by: Ben Widawsky Signed-off-by: Michel Thierry (v2+) --- driver

[Intel-gfx] [PATCH 13/13] drm/i915: Use complete address space in true PPGTT

2015-04-08 Thread Michel Thierry
True PPGTT is capable of having a full address space, even if the system has less allocated memory. Note that aliasing PPGTT always aliases the GGTT and thus should remain of the same size. Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_gem_gtt.c | 4 +--- 1 file changed, 1

[Intel-gfx] [PATCH 11/13] drm/i915/gen8: begin bitmap tracking

2015-04-08 Thread Michel Thierry
ables/page_table/. v5: Rebased after page table generalizations. Signed-off-by: Ben Widawsky Signed-off-by: Michel Thierry (v2+) --- drivers/gpu/drm/i915/i915_gem_gtt.c | 59 + drivers/gpu/drm/i915/i915_gem_gtt.h | 7 + 2 files changed, 54 insertions(+), 12 dele

[Intel-gfx] [PATCH 09/13] drm/i915: Extract PPGTT param from page_directory alloc

2015-04-08 Thread Michel Thierry
This will be useful for when we move to 48b addressing, and the PDP isn't the root of the page table structure. v2: Rebase after changes for Gen8+ systems with less than 4GB of memory. v3: Rebase after Mika's code review. Signed-off-by: Ben Widawsky Signed-off-by: Michel Th

[Intel-gfx] [PATCH 10/13] drm/i915/gen8: Split out mappings

2015-04-08 Thread Michel Thierry
ll PDPs in GEN8+ systems with less than 4GB of memory, and update populate_lr_context to handle this new case (proper tracking will be added later in the patch series). v6: Assign lrc page directory pointer addresses using a macro. (Mika) Cc: Mika Kuoppala Signed-off-by: Ben Widawsky Signed-off-

[Intel-gfx] [PATCH 02/13] drm/i915: Remove unnecessary gen8_ppgtt_unmap_pages

2015-04-08 Thread Michel Thierry
We are already unmapping them in gen8_ppgtt_free. This function became redundant since commit 06fda602dbca9c59d87db7da71192e4b54c9f5ff ("drm/i915: Create page table allocators"). Cc: Mika Kuoppala Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_gem_

[Intel-gfx] [PATCH 08/13] drm/i915: num_pd_pages/num_pd_entries isn't useful

2015-04-08 Thread Michel Thierry
allocating all page directories in GEN8+ systems with less than 4GB of memory. Updated gen6_for_all_pdes. v6: Prevent (harmless) out of range access in gen6_for_all_pdes. Signed-off-by: Ben Widawsky Signed-off-by: Michel Thierry (v2+) --- drivers/gpu/drm/i915/i915_debugfs.c | 2 -- drivers/gpu

[Intel-gfx] [PATCH 05/13] drm/i915/gen8: page directories rework allocation

2015-04-08 Thread Michel Thierry
: Initialize also the extra PDs from systems with less than 4GB of memory. (Mika) Cc: Mika Kuoppala Signed-off-by: Ben Widawsky Signed-off-by: Michel Thierry (v2+) --- drivers/gpu/drm/i915/i915_gem_gtt.c | 100 ++-- 1 file changed, 85 insertions(+), 15 deletions(-) diff

[Intel-gfx] [PATCH v2] drm/i915: Workaround to avoid lite restore with HEAD==TAIL

2015-04-14 Thread Michel Thierry
ote about sampling request->tail in commit message (Chris). Cc: Chris Wilson Signed-off-by: Thomas Daniel Signed-off-by: Michel Thierry --- drivers/gpu/drm/i915/i915_gem.c | 15 ++- drivers/gpu/drm/i915/intel_lrc.c | 27 ++- 2 files changed, 40 insertions

[Intel-gfx] [PATCH] igt/gem_ctx_exec: Add lrc lite restore subtest

2015-04-14 Thread Michel Thierry
Exercise lite-restore (re-submit a context that is currently running), by queueing several small batchbuffers. This test helps to validate WaIdleLiteRestore. Signed-off-by: Michel Thierry --- tests/gem_ctx_exec.c | 30 +- 1 file changed, 29 insertions(+), 1 deletion

Re: [Intel-gfx] [RFC 00/38] PPGTT dynamic page allocations

2014-11-04 Thread Michel Thierry
On 11/4/2014 12:54 PM, Daniel Vetter wrote: On Tue, Oct 07, 2014 at 06:10:56PM +0100, Michel Thierry wrote: This is based on the first 55 patches of Ben's 48b addressing work, taking into consideration the latest changes in (mainly aliasing) ppgtt rules. Because of these changes in the

Re: [Intel-gfx] [PATCH v2 1/2] drm/i915: Initialize bdw workarounds in logical ring mode too

2014-11-05 Thread Michel Thierry
On 11/4/2014 7:23 PM, Rodrigo Vivi wrote: These patches got listed to -collector but got a huge conflict. If it is still relevant please rebase it. Also my bikeshed is to findo better names to help on differentiate them at least. On Wed, Sep 24, 2014 at 5:02 AM, Michel Thierry wrote

Re: [Intel-gfx] [PATCH] drm/i915: Initialize workarounds in logical ring mode too

2014-11-11 Thread Michel Thierry
On 11/10/2014 4:38 PM, Mika Kuoppala wrote: Arun Siluvery writes: From: Michel Thierry Following the legacy ring submission example, update the ring->init_context() hook to support the execlist submission mode. v2: update to use the new workaround macros and cleanup unused code. This ta

[Intel-gfx] [PATCH v3] drm/i915: Initialize workarounds in logical ring mode too

2014-11-11 Thread Michel Thierry
ing deferred context creation. v3: Split init_context (emit) in legacy/lrc modes. For lrc, get the ringbuf from the context. (Mika/Daniel). Issue: VIZ-4092 Issue: GMIN-3475 Change-Id: Ie3d093b2542ab0e2a44b90460533e2f979788d6c Cc: Deepak S Cc: Mika Kuoppala Cc: Daniel Vetter Signed-off-by: Michel Thie

<    1   2   3   4   5   6   7   8   9   10   >