[Intel-gfx] [PATCH v2 1/3] drm/i915/guc: Update to use firmware v49.0.1

2020-10-13 Thread John . C . Harrison
From: John Harrison The latest GuC firmware includes a number of interface changes that require driver updates to match. * Starting from Gen11, the ID to be provided to GuC needs to contain the engine class in bits [0..2] and the instance in bits [3..6]. NOTE: this patch breaks pointer dere

[Intel-gfx] [PATCH v2 3/3] drm/i915/guc: Clear pointers on free

2020-10-13 Thread John . C . Harrison
From: John Harrison Clear out some pointers when objects have been de-allocated. This makes it much easier to track down use-after-free type issues. Signed-off-by: John Harrison --- drivers/gpu/drm/i915/gt/uc/intel_guc_ads.c | 1 + drivers/gpu/drm/i915/gt/uc/intel_guc_ct.c | 1 + 2 files chan

[Intel-gfx] [PATCH CI v2 4/4] CI: turn on GuC/HuC auto mode by default

2020-10-15 Thread John . C . Harrison
From: John Harrison Enable Guc/HuC loading by default for Gen11+ platforms in order to get a CI run. --- drivers/gpu/drm/i915/i915_params.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/i915_params.h b/drivers/gpu/drm/i915/i915_params.h index 330c03e2b

[Intel-gfx] [PATCH CI v2 0/4] drm/i915/guc: Update to GuC v49

2020-10-15 Thread John . C . Harrison
From: John Harrison Update to the latest GuC firmware v2: Rebase to newer tree, updated a commit message (review feedback from Daniele) and dropped the patch to enable GuC/HuC loading by default as apparently this is not allowed. Signed-off-by: John Harrison John Harrison (4): drm/i915/guc

[Intel-gfx] [PATCH CI v2 3/4] drm/i915/guc: Clear pointers on free

2020-10-15 Thread John . C . Harrison
From: John Harrison Clear out some pointers when objects have been de-allocated. This makes it much easier to track down use-after-free type issues. Signed-off-by: John Harrison Reviewed-by: Daniele Ceraolo Spurio --- drivers/gpu/drm/i915/gt/uc/intel_guc_ads.c | 1 + drivers/gpu/drm/i915/gt/u

[Intel-gfx] [PATCH CI v2 2/4] drm/i915/guc: Improved reporting when GuC fails to load

2020-10-15 Thread John . C . Harrison
From: John Harrison Rather than just saying 'GuC failed to load: -110', actually print out the GuC status register and break it down into the individual fields. Signed-off-by: John Harrison Reviewed-by: Daniele Ceraolo Spurio --- drivers/gpu/drm/i915/gt/uc/intel_guc_fw.c | 31

[Intel-gfx] [PATCH CI v2 1/4] drm/i915/guc: Update to use firmware v49.0.1

2020-10-15 Thread John . C . Harrison
From: John Harrison The latest GuC firmware includes a number of interface changes that require driver updates to match. * Starting from Gen11, the ID to be provided to GuC needs to contain the engine class in bits [0..2] and the instance in bits [3..6]. NOTE: this patch breaks pointer dere

[Intel-gfx] [PATCH v3 3/3] drm/i915/guc: Clear pointers on free

2020-10-28 Thread John . C . Harrison
From: John Harrison Clear out some pointers when objects have been de-allocated. This makes it much easier to track down use-after-free type issues. Signed-off-by: John Harrison Reviewed-by: Daniele Ceraolo Spurio --- drivers/gpu/drm/i915/gt/uc/intel_guc_ads.c | 1 + drivers/gpu/drm/i915/gt/u

[Intel-gfx] [PATCH v3 0/3] drm/i915/guc: Update to GuC v49

2020-10-28 Thread John . C . Harrison
From: John Harrison Update to the latest GuC firmware v2: Rebase to newer tree, updated a commit message (review feedback from Daniele) and dropped the patch to enable GuC/HuC loading by default as apparently this is not allowed. v3: Rebase to drm-intel-gt-next which is apparently missing the p

[Intel-gfx] [PATCH v3 2/3] drm/i915/guc: Improved reporting when GuC fails to load

2020-10-28 Thread John . C . Harrison
From: John Harrison Rather than just saying 'GuC failed to load: -110', actually print out the GuC status register and break it down into the individual fields. Signed-off-by: John Harrison Reviewed-by: Daniele Ceraolo Spurio --- drivers/gpu/drm/i915/gt/uc/intel_guc_fw.c | 31

[Intel-gfx] [PATCH v3 1/3] drm/i915/guc: Update to use firmware v49.0.1

2020-10-28 Thread John . C . Harrison
From: John Harrison The latest GuC firmware includes a number of interface changes that require driver updates to match. * Starting from Gen11, the ID to be provided to GuC needs to contain the engine class in bits [0..2] and the instance in bits [3..6]. NOTE: this patch breaks pointer dere

[Intel-gfx] [PATCH] drm/i915: Correct location of Wa_1408615072

2020-07-10 Thread John . C . Harrison
From: John Harrison The above workaround was added as an engine workaround not a GT workaround. Moved it to the correct location. Signed-off-by: John Harrison --- drivers/gpu/drm/i915/gt/intel_workarounds.c | 10 ++ 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/drivers/

[Intel-gfx] [CI] PR for new v45.0.0 GuC binaries

2020-08-06 Thread John . C . Harrison
The following changes since commit 2b823fc2568fc354551a63c37f5f5490d70a53d1: linux-firmware: Update AMD SEV firmware (2020-07-21 09:07:20 -0400) are available in the Git repository at: git://anongit.freedesktop.org/drm/drm-firmware guc_v45 for you to fetch changes up to c82f39064bd5c70a18c6

[Intel-gfx] [PATCH 0/2] drm/i915/guc: Update to GuC v45

2020-08-07 Thread John . C . Harrison
From: John Harrison Update to the latest GuC firmware and enable by default. Signed-off-by: John Harrison Daniele Ceraolo Spurio (1): drm/i915/uc: turn on GuC/HuC auto mode by default John Harrison (1): drm/i915/guc: Update to GuC v45.0.0 drivers/gpu/drm/i915/gt/intel_engine_cs.c|

[Intel-gfx] [PATCH 2/2] drm/i915/uc: turn on GuC/HuC auto mode by default

2020-08-07 Thread John . C . Harrison
From: Daniele Ceraolo Spurio This will enable HuC loading for Gen11+ by default if the binaries are available on the system. GuC submission still requires explicit enabling by the user. Signed-off-by: Daniele Ceraolo Spurio --- drivers/gpu/drm/i915/i915_params.h | 2 +- 1 file changed, 1 inser

[Intel-gfx] [PATCH 1/2] drm/i915/guc: Update to GuC v45.0.0

2020-08-07 Thread John . C . Harrison
From: John Harrison Update to the latest GuC firmware. This includes some significant changes to the interface. Signed-off-by: John Harrison Author: Daniele Ceraolo Spurio Author: John Harrison Author: Matthew Brost Author: Michal Wajdeczko Author: Michel Thierry Author: Oscar Mateo Autho

[Intel-gfx] [CI] PR for new v49.0.1 GuC binaries

2020-09-15 Thread John . C . Harrison
The following changes since commit d5f9eea5a251d43412b07f5295d03e97b89ac4a5: wl18xx: update firmware file 8.9.0.0.83 (2020-09-01 08:07:59 -0400) are available in the Git repository at: ssh://git.freedesktop.org/git/drm/drm-firmware guc_v49 for you to fetch changes up to a5beba43fb3a2b91f4b9

[Intel-gfx] [PATCH 04/12] drm/i915/guc: Remove GUC_CTL_CTXINFO init param

2020-09-16 Thread John . C . Harrison
From: Matthew Brost The new GuC interface has removed GUC_CTL_CTXINFO from initialization params. Cc: John Harrison Signed-off-by: Matthew Brost --- drivers/gpu/drm/i915/gt/uc/intel_guc.c | 18 -- drivers/gpu/drm/i915/gt/uc/intel_guc_fwif.h | 15 +-- 2 files c

[Intel-gfx] [PATCH 03/12] drm/i915/guc: Setup private_data pointer in GuC ADS

2020-09-16 Thread John . C . Harrison
From: Matthew Brost The new GuC requires the additional data structure and associated 'private_data' pointer to be setup. This is basically a scratch area of memory that the GuC owns. The size is read from the CSS header. Cc: John Harrison Signed-off-by: Matthew Brost --- drivers/gpu/drm/i915

[Intel-gfx] [PATCH 01/12] drm/i915/guc: New GuC IDs based on engine class and instance

2020-09-16 Thread John . C . Harrison
From: Michal Wajdeczko Starting from Gen11, the ID to be provided to GuC needs to contain the engine class in bits [0..2] and the instance in bits [3..6]. NOTE: this patch breaks pointer dereferences in some existing GuC functions that use the guc_id to dereference arrays but these functions are

[Intel-gfx] [PATCH 11/12] drm/i915/guc: Clear pointers on free

2020-09-16 Thread John . C . Harrison
From: John Harrison Was hitting null pointers and similar issues when running various module load/unload and inject failure type tests. So clear those pointers down when the objects have been de-allocated. Signed-off-by: John Harrison --- drivers/gpu/drm/i915/gt/uc/intel_guc_ads.c | 1 + drive

[Intel-gfx] [PATCH 06/12] drm/i915/guc: ADS changes for GuC v42

2020-09-16 Thread John . C . Harrison
From: John Harrison The ADS layout changes significantly with GuC firmware v42. This patch updates the shared structure (but does not fill in the new tables, that comes later as part of the GuC submission support). It also adds better documentation of the layout. Signed-off-by: John Harrison --

[Intel-gfx] [PATCH 05/12] drm/i915/guc: Kill guc_ads.reg_state_buffer

2020-09-16 Thread John . C . Harrison
From: Michal Wajdeczko Starting GuC firmware version 40.0 reg_state_buffer is maintained internally by the GuC as part of "private data". Signed-off-by: Michal Wajdeczko --- drivers/gpu/drm/i915/gt/uc/intel_guc_ads.c | 2 -- drivers/gpu/drm/i915/gt/uc/intel_guc_fwif.h | 2 +- 2 files changed,

[Intel-gfx] [PATCH 00/12] drm/i915/guc: Update to GuC v49

2020-09-16 Thread John . C . Harrison
From: John Harrison Update to the latest GuC firmware and enable by default. Signed-off-by: John Harrison Daniele Ceraolo Spurio (1): drm/i915/uc: turn on GuC/HuC auto mode by default John Harrison (5): drm/i915/guc: ADS changes for GuC v42 drm/i915/guc: Increased engine classes in ADS

[Intel-gfx] [PATCH 07/12] drm/i915/guc: Setup doorbells data in ADS

2020-09-16 Thread John . C . Harrison
From: Michal Wajdeczko While i915 does not use GuC doorbells, the firmware requires that some initialisation is done. Signed-off-by: Michal Wajdeczko Cc: Daniele Ceraolo Spurio --- drivers/gpu/drm/i915/gt/uc/intel_guc_ads.c | 9 + drivers/gpu/drm/i915/gt/uc/intel_guc_fwif.h | 2 +- d

[Intel-gfx] [PATCH 08/12] drm/i915/guc: Increased engine classes in ADS

2020-09-16 Thread John . C . Harrison
From: John Harrison GuC v46 partially increased the number of engine classes supported in the ADS. GuC v48 then finished the change off by cleaning up the per class engine mask fields. Signed-off-by: John Harrison --- drivers/gpu/drm/i915/gt/uc/intel_guc_ads.c | 16 +--- drivers/g

[Intel-gfx] [PATCH 02/12] drm/i915/guc: Support logical engine mapping table in ADS

2020-09-16 Thread John . C . Harrison
From: Matthew Brost The new GuC FW introduces a physical to logical engine mapping table in the GuC additional data structures which needs to be configured in order for the firmware to load. This patch initializes the table with a 1 to 1 mapping. Signed-off-by: Matthew Brost CC: John Harrison

[Intel-gfx] [PATCH 12/12] drm/i915/uc: turn on GuC/HuC auto mode by default

2020-09-16 Thread John . C . Harrison
From: Daniele Ceraolo Spurio This will enable HuC loading for Gen11+ by default if the binaries are available on the system. GuC submission still requires explicit enabling by the user. Signed-off-by: Daniele Ceraolo Spurio Cc: Michal Wajdeczko --- drivers/gpu/drm/i915/i915_params.h | 2 +- 1

[Intel-gfx] [PATCH 09/12] drm/i915/guc: Update firmware to v49.0.1

2020-09-16 Thread John . C . Harrison
From: John Harrison Note that the GuC major version jumped from 35 to 40. This is because the v40 firmware included a significant re-write of the API. The 'new GuC API' patch series is required to make use of command submission with this new GuC firmware. Versions 36 through 39 are reserved for u

[Intel-gfx] [PATCH 10/12] drm/i915/guc: Improved reporting when GuC fails to load

2020-09-16 Thread John . C . Harrison
From: John Harrison Rather than just saying 'GuC failed to load: -110', actually print out the GuC status register and break it down into the individual fields. Signed-off-by: John Harrison --- drivers/gpu/drm/i915/gt/uc/intel_guc_fw.c | 27 ++- 1 file changed, 22 insertion

[Intel-gfx] [CI] PR for new v49.0.1 GuC binaries

2020-09-18 Thread John . C . Harrison
The following changes since commit d5f9eea5a251d43412b07f5295d03e97b89ac4a5: wl18xx: update firmware file 8.9.0.0.83 (2020-09-01 08:07:59 -0400) are available in the Git repository at: git://anongit.freedesktop.org/drm/drm-firmware guc_v49 for you to fetch changes up to a5beba43fb3a2b91f4b9

[Intel-gfx] [PATCH 4/4] drm/i915/uc: turn on GuC/HuC auto mode by default

2020-09-21 Thread John . C . Harrison
From: Daniele Ceraolo Spurio This will enable HuC loading for Gen11+ by default if the binaries are available on the system. GuC submission still requires explicit enabling by the user. Signed-off-by: Daniele Ceraolo Spurio Cc: Michal Wajdeczko --- drivers/gpu/drm/i915/i915_params.h | 2 +- 1

[Intel-gfx] [PATCH 3/4] drm/i915/guc: Clear pointers on free

2020-09-21 Thread John . C . Harrison
From: John Harrison Was hitting null pointers and similar issues when running various module load/unload and inject failure type tests. So clear those pointers down when the objects have been de-allocated. Signed-off-by: John Harrison --- drivers/gpu/drm/i915/gt/uc/intel_guc_ads.c | 1 + drive

[Intel-gfx] [PATCH 2/4] drm/i915/guc: Improved reporting when GuC fails to load

2020-09-21 Thread John . C . Harrison
From: John Harrison Rather than just saying 'GuC failed to load: -110', actually print out the GuC status register and break it down into the individual fields. Signed-off-by: John Harrison --- drivers/gpu/drm/i915/gt/uc/intel_guc_fw.c | 27 ++- 1 file changed, 22 insertion

[Intel-gfx] [PATCH 1/4] drm/i915/guc: Update to use firmware v49.0.1

2020-09-21 Thread John . C . Harrison
From: John Harrison The latest GuC firmware includes a number of interface changes that require driver updates to match. * Starting from Gen11, the ID to be provided to GuC needs to contain the engine class in bits [0..2] and the instance in bits [3..6]. NOTE: this patch breaks pointer dere

[Intel-gfx] [PATCH 0/4] drm/i915/guc: Update to GuC v49

2020-09-21 Thread John . C . Harrison
From: John Harrison Update to the latest GuC firmware and enable by default. Signed-off-by: John Harrison Daniele Ceraolo Spurio (1): drm/i915/uc: turn on GuC/HuC auto mode by default John Harrison (3): drm/i915/guc: Update to use firmware v49.0.1 drm/i915/guc: Improved reporting when

[Intel-gfx] [PATCH 0/4] drm/i915/guc: Update to GuC v49

2020-09-25 Thread John . C . Harrison
From: John Harrison Update to the latest GuC firmware and enable by default. Signed-off-by: John Harrison Daniele Ceraolo Spurio (1): drm/i915/uc: turn on GuC/HuC auto mode by default John Harrison (3): drm/i915/guc: Update to use firmware v49.0.1 drm/i915/guc: Improved reporting when

[Intel-gfx] [PATCH 3/4] drm/i915/guc: Clear pointers on free

2020-09-25 Thread John . C . Harrison
From: John Harrison Was hitting null pointers and similar issues when running various module load/unload and inject failure type tests. So clear those pointers down when the objects have been de-allocated. Signed-off-by: John Harrison --- drivers/gpu/drm/i915/gt/uc/intel_guc_ads.c | 1 + drive

[Intel-gfx] [PATCH 2/4] drm/i915/guc: Improved reporting when GuC fails to load

2020-09-25 Thread John . C . Harrison
From: John Harrison Rather than just saying 'GuC failed to load: -110', actually print out the GuC status register and break it down into the individual fields. Signed-off-by: John Harrison --- drivers/gpu/drm/i915/gt/uc/intel_guc_fw.c | 31 --- 1 file changed, 22 insertion

[Intel-gfx] [PATCH 4/4] drm/i915/uc: turn on GuC/HuC auto mode by default

2020-09-25 Thread John . C . Harrison
From: Daniele Ceraolo Spurio This will enable HuC loading for Gen11+ by default if the binaries are available on the system. GuC submission still requires explicit enabling by the user. Signed-off-by: Daniele Ceraolo Spurio Cc: Michal Wajdeczko --- drivers/gpu/drm/i915/i915_params.h | 2 +- 1

[Intel-gfx] [PATCH 1/4] drm/i915/guc: Update to use firmware v49.0.1

2020-09-25 Thread John . C . Harrison
From: John Harrison The latest GuC firmware includes a number of interface changes that require driver updates to match. * Starting from Gen11, the ID to be provided to GuC needs to contain the engine class in bits [0..2] and the instance in bits [3..6]. NOTE: this patch breaks pointer dere

[Intel-gfx] [PATCH v9 4/6] drm/i915: Interrupt driven fences

2016-06-01 Thread John . C . Harrison
From: John Harrison The intended usage model for struct fence is that the signalled status should be set on demand rather than polled. That is, there should not be a need for a 'signaled' function to be called everytime the status is queried. Instead, 'something' should be done to enable a signal

[Intel-gfx] [PATCH v9 2/6] drm/i915: Convert requests to use struct fence

2016-06-01 Thread John . C . Harrison
From: John Harrison There is a construct in the linux kernel called 'struct fence' that is intended to keep track of work that is executed on hardware. I.e. it solves the basic problem that the drivers 'struct drm_i915_gem_request' is trying to address. The request structure does quite a lot more

[Intel-gfx] [PATCH v9 3/6] drm/i915: Removed now redundant parameter to i915_gem_request_completed()

2016-06-01 Thread John . C . Harrison
From: John Harrison The change to the implementation of i915_gem_request_completed() means that the lazy coherency flag is no longer used. This can now be removed to simplify the interface. v6: Updated to newer nightly and resolved conflicts. v7: Updated to newer nightly (lots of ring -> engine

[Intel-gfx] [PATCH v9 6/6] drm/i915: Cache last IRQ seqno to reduce IRQ overhead

2016-06-01 Thread John . C . Harrison
From: John Harrison The notify function can be called many times without the seqno changing. Some are to prevent races due to the requirement of not enabling interrupts until requested. However, when interrupts are enabled the IRQ handler can be called multiple times without the ring's seqno valu

[Intel-gfx] [PATCH v9 0/6] Convert requests to use struct fence

2016-06-01 Thread John . C . Harrison
From: John Harrison There is a construct in the linux kernel called 'struct fence' that is intended to keep track of work that is executed on hardware. I.e. it solves the basic problem that the drivers 'struct drm_i915_gem_request' is trying to address. The request structure does quite a lot more

[Intel-gfx] [PATCH v9 5/6] drm/i915: Updated request structure tracing

2016-06-01 Thread John . C . Harrison
From: John Harrison Added the '_complete' trace event which occurs when a fence/request is signaled as complete. Also moved the notify event from the IRQ handler code to inside the notify function itself. v3: Added the current ring seqno to the notify trace point. v5: Line wrapping to keep the

[Intel-gfx] [PATCH v9 1/6] drm/i915: Add per context timelines for fence objects

2016-06-01 Thread John . C . Harrison
From: John Harrison The purpose of this patch series is to convert the requst structure to use fence objects for the underlying completion tracking. The fence object requires a sequence number. The ultimate aim is to use the same sequence number as for the request itself (or rather, to remove the

[Intel-gfx] [PATCH v10 0/6] Convert requests to use struct fence

2016-06-16 Thread John . C . Harrison
From: John Harrison There is a construct in the linux kernel called 'struct fence' that is intended to keep track of work that is executed on hardware. I.e. it solves the basic problem that the drivers 'struct drm_i915_gem_request' is trying to address. The request structure does quite a lot more

[Intel-gfx] [PATCH v10 6/6] drm/i915: Cache last IRQ seqno to reduce IRQ overhead

2016-06-16 Thread John . C . Harrison
From: John Harrison The notify function can be called many times without the seqno changing. Some are to prevent races due to the requirement of not enabling interrupts until requested. However, when interrupts are enabled the IRQ handler can be called multiple times without the ring's seqno valu

[Intel-gfx] [PATCH v10 5/6] drm/i915: Updated request structure tracing

2016-06-16 Thread John . C . Harrison
From: John Harrison Added the '_complete' trace event which occurs when a fence/request is signaled as complete. Also moved the notify event from the IRQ handler code to inside the notify function itself. v3: Added the current ring seqno to the notify trace point. v5: Line wrapping to keep the

[Intel-gfx] [PATCH v10 2/6] drm/i915: Convert requests to use struct fence

2016-06-16 Thread John . C . Harrison
From: John Harrison There is a construct in the linux kernel called 'struct fence' that is intended to keep track of work that is executed on hardware. I.e. it solves the basic problem that the drivers 'struct drm_i915_gem_request' is trying to address. The request structure does quite a lot more

[Intel-gfx] [PATCH v10 1/6] drm/i915: Add per context timelines for fence objects

2016-06-16 Thread John . C . Harrison
From: John Harrison The purpose of this patch series is to convert the requst structure to use fence objects for the underlying completion tracking. The fence object requires a sequence number. The ultimate aim is to use the same sequence number as for the request itself (or rather, to remove the

[Intel-gfx] [PATCH v10 4/6] drm/i915: Interrupt driven fences

2016-06-16 Thread John . C . Harrison
From: John Harrison The intended usage model for struct fence is that the signalled status should be set on demand rather than polled. That is, there should not be a need for a 'signaled' function to be called everytime the status is queried. Instead, 'something' should be done to enable a signal

[Intel-gfx] [PATCH v10 3/6] drm/i915: Removed now redundant parameter to i915_gem_request_completed()

2016-06-16 Thread John . C . Harrison
From: John Harrison The change to the implementation of i915_gem_request_completed() means that the lazy coherency flag is no longer used. This can now be removed to simplify the interface. v6: Updated to newer nightly and resolved conflicts. v7: Updated to newer nightly (lots of ring -> engine

[Intel-gfx] [PATCH v10b 4/6] drm/i915: Interrupt driven fences

2016-06-17 Thread John . C . Harrison
From: John Harrison The intended usage model for struct fence is that the signalled status should be set on demand rather than polled. That is, there should not be a need for a 'signaled' function to be called everytime the status is queried. Instead, 'something' should be done to enable a signal

[Intel-gfx] [PATCH v10b 5/6] drm/i915: Updated request structure tracing

2016-06-17 Thread John . C . Harrison
From: John Harrison Added the '_complete' trace event which occurs when a fence/request is signaled as complete. Also moved the notify event from the IRQ handler code to inside the notify function itself. v3: Added the current ring seqno to the notify trace point. v5: Line wrapping to keep the

[Intel-gfx] [RFC 06/12] drm/i915: Add per context timelines to fence object

2015-11-23 Thread John . C . Harrison
From: John Harrison The fence object used inside the request structure requires a sequence number. Although this is not used by the i915 driver itself, it could potentially be used by non-i915 code if the fence is passed outside of the driver. This is the intention as it allows external kernel dr

[Intel-gfx] [RFC 02/12] staging/android/sync: add sync_fence_create_dma

2015-11-23 Thread John . C . Harrison
From: Maarten Lankhorst This allows users of dma fences to create a android fence. v2: Added kerneldoc. (Tvrtko Ursulin). Signed-off-by: Maarten Lankhorst Signed-off-by: Tvrtko Ursulin Cc: Maarten Lankhorst Cc: Daniel Vetter Cc: Jesse Barnes Cc: de...@driverdev.osuosl.org Cc: Riley Andrews

[Intel-gfx] [RFC 07/12] drm/i915: Delay the freeing of requests until retire time

2015-11-23 Thread John . C . Harrison
From: John Harrison The request structure is reference counted. When the count reached zero, the request was immediately freed and all associated objects were unrefereced/unallocated. This meant that the driver mutex lock must be held at the point where the count reaches zero. This was fine while

[Intel-gfx] [RFC 08/12] drm/i915: Interrupt driven fences

2015-11-23 Thread John . C . Harrison
From: John Harrison The intended usage model for struct fence is that the signalled status should be set on demand rather than polled. That is, there should not be a need for a 'signaled' function to be called everytime the status is queried. Instead, 'something' should be done to enable a signal

[Intel-gfx] [RFC 03/12] staging/android/sync: Move sync framework out of staging

2015-11-23 Thread John . C . Harrison
From: John Harrison The sync framework is now used by the i915 driver. Therefore it can be moved out of staging and into the regular tree. Also, the public interfaces can actually be made public and exported. v3: New patch for series. Signed-off-by: John Harrison Signed-off-by: Geoff Miller -

[Intel-gfx] [RFC 09/12] drm/i915: Updated request structure tracing

2015-11-23 Thread John . C . Harrison
From: John Harrison Added the '_complete' trace event which occurs when a fence/request is signaled as complete. Also moved the notify event from the IRQ handler code to inside the notify function itself. v3: Added the current ring seqno to the notify trace point. For: VIZ-5190 Signed-off-by: J

[Intel-gfx] [RFC 01/12] staging/android/sync: Support sync points created from dma-fences

2015-11-23 Thread John . C . Harrison
From: Tvrtko Ursulin Debug output assumes all sync points are built on top of Android sync points and when we start creating them from dma-fences will NULL ptr deref unless taught about this. Signed-off-by: Tvrtko Ursulin Cc: Maarten Lankhorst Cc: de...@driverdev.osuosl.org Cc: Riley Andrews

[Intel-gfx] [RFC 00/12] Convert requests to use struct fence

2015-11-23 Thread John . C . Harrison
From: John Harrison There is a construct in the linux kernel called 'struct fence' that is intended to keep track of work that is executed on hardware. I.e. it solves the basic problem that the drivers 'struct drm_i915_gem_request' is trying to address. The request structure does quite a lot more

[Intel-gfx] [RFC 05/12] drm/i915: Removed now redudant parameter to i915_gem_request_completed()

2015-11-23 Thread John . C . Harrison
From: John Harrison The change to the implementation of i915_gem_request_completed() means that the lazy coherency flag is no longer used. This can now be removed to simplify the interface. For: VIZ-5190 Signed-off-by: John Harrison --- drivers/gpu/drm/i915/i915_debugfs.c | 2 +- drivers/gpu

[Intel-gfx] [RFC 04/12] drm/i915: Convert requests to use struct fence

2015-11-23 Thread John . C . Harrison
From: John Harrison There is a construct in the linux kernel called 'struct fence' that is intended to keep track of work that is executed on hardware. I.e. it solves the basic problem that the drivers 'struct drm_i915_gem_request' is trying to address. The request structure does quite a lot more

[Intel-gfx] [RFC 11/12] drm/i915: Add sync framework support to execbuff IOCTL

2015-11-23 Thread John . C . Harrison
From: John Harrison Various projects desire a mechanism for managing dependencies between work items asynchronously. This can also include work items across complete different and independent systems. For example, an application wants to retreive a frame from a video in device, using it for rende

[Intel-gfx] [RFC 12/12] drm/i915: Cache last IRQ seqno to reduce IRQ overhead

2015-11-23 Thread John . C . Harrison
From: John Harrison The notify function can be called many times without the seqno changing. A large number of duplicates are to prevent races due to the requirement of not enabling interrupts until requested. However, when interrupts are enabled the IRQ handle can be called multiple times withou

[Intel-gfx] [RFC 10/12] android/sync: Fix reversed sense of signaled fence

2015-11-23 Thread John . C . Harrison
From: Peter Lawthers In the 3.14 kernel, a signaled fence was indicated by the status field == 1. In 4.x, a status == 0 indicates signaled, status < 0 indicates error, and status > 0 indicates active. This patch wraps the check for a signaled fence in a function so that callers no longer needs t

[Intel-gfx] [PATCH 04/39] drm/i915: Prelude to splitting i915_gem_do_execbuffer in two

2015-11-23 Thread John . C . Harrison
From: John Harrison The scheduler decouples the submission of batch buffers to the driver with their submission to the hardware. This basically means splitting the execbuffer() function in half. This change rearranges some code ready for the split to occur. Change-Id: Icc9c8afaac18821f3eb8a151a4

[Intel-gfx] [PATCH 15/39] drm/i915: Keep the reserved space mechanism happy

2015-11-23 Thread John . C . Harrison
From: John Harrison Ring space is reserved when constructing a request to ensure that the subsequent 'add_request()' call cannot fail due to waiting for space on a busy or broken GPU. However, the scheduler jumps in to the middle of the execbuffer process between request creation and request subm

[Intel-gfx] [PATCH 13/39] drm/i915: Added deferred work handler for scheduler

2015-11-23 Thread John . C . Harrison
From: John Harrison The scheduler needs to do interrupt triggered work that is too complex to do in the interrupt handler. Thus it requires a deferred work handler to process such tasks asynchronously. v2: Updated to reduce mutex lock usage. The lock is now only held for the minimum time within

[Intel-gfx] [PATCH 08/39] drm/i915: Prepare retire_requests to handle out-of-order seqnos

2015-11-23 Thread John . C . Harrison
From: John Harrison A major point of the GPU scheduler is that it re-orders batch buffers after they have been submitted to the driver. This leads to requests completing out of order. In turn, this means that the retire processing can no longer assume that all completed entries are at the front o

[Intel-gfx] [PATCH 01/39] drm/i915: Add total count to context status debugfs output

2015-11-23 Thread John . C . Harrison
From: John Harrison When there are lots and lots and even more lots of contexts (e.g. when running with execlists) it is useful to be able to immediately see what the total context count is. Change-Id: If9726d4df86567100ecf53867b43f4753f08bf84 For: VIZ-1587 Signed-off-by: John Harrison --- dri

[Intel-gfx] [PATCH 11/39] drm/i915: Added scheduler hook when closing DRM file handles

2015-11-23 Thread John . C . Harrison
From: John Harrison The scheduler decouples the submission of batch buffers to the driver with submission of batch buffers to the hardware. Thus it is possible for an application to submit work, then close the DRM handle and free up all the resources that piece of work wishes to use before the wo

[Intel-gfx] [PATCH 03/39] drm/i915: Explicit power enable during deferred context initialisation

2015-11-23 Thread John . C . Harrison
From: John Harrison A later patch in this series re-organises the batch buffer submission code. Part of that is to reduce the scope of a pm_get/put pair. Specifically, they previously wrapped the entire submission path from the very start to the very end, now they only wrap the actual hardware su

[Intel-gfx] [PATCH 10/39] drm/i915: Force MMIO flips when scheduler enabled

2015-11-23 Thread John . C . Harrison
From: John Harrison Change-Id: Ice071af6d88306b0d1c53bdb651a1a3e20bdc1af For: VIZ-1587 Signed-off-by: John Harrison --- drivers/gpu/drm/i915/intel_display.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index

[Intel-gfx] [PATCH 12/39] drm/i915: Added scheduler hook into i915_gem_request_notify()

2015-11-23 Thread John . C . Harrison
From: John Harrison The scheduler needs to know when requests have completed so that it can keep its own internal state up to date and can submit new requests to the hardware from its queue. v2: Updated due to changes in request handling. The operation is now reversed from before. Rather than th

[Intel-gfx] [PATCH 21/39] drm/i915: Added a module parameter for allowing scheduler overrides

2015-11-23 Thread John . C . Harrison
From: John Harrison It can be useful to be able to disable certain features (e.g. the entire scheduler) via a module parameter for debugging purposes. A parameter has the advantage of not being a compile time switch but without implying that it can be changed dynamically at runtime. Change-Id: I

[Intel-gfx] [PATCH 02/39] drm/i915: Updating assorted register and status page definitions

2015-11-23 Thread John . C . Harrison
From: Dave Gordon Added various definitions that will be useful for the scheduler in general and pre-emptive context switching in particular. Change-Id: Ica805b94160426def51f5d520f5ce51c60864a98 For: VIZ-1587 Signed-off-by: Dave Gordon --- drivers/gpu/drm/i915/i915_reg.h | 30 +

[Intel-gfx] [PATCH 09/39] drm/i915: Disable hardware semaphores when GPU scheduler is enabled

2015-11-23 Thread John . C . Harrison
From: John Harrison Hardware sempahores require seqno values to be continuously incrementing. However, the scheduler's reordering of batch buffers means that the seqno values going through the hardware could be out of order. Thus semaphores can not be used. On the other hand, the scheduler super

[Intel-gfx] [PATCH 05/39] drm/i915: Split i915_dem_do_execbuffer() in half

2015-11-23 Thread John . C . Harrison
From: John Harrison Split the execbuffer() function in half. The first half collects and validates all the information requried to process the batch buffer. It also does all the object pinning, relocations, active list management, etc - basically anything that must be done upfront before the IOCT

[Intel-gfx] [PATCH 00/39] GPU scheduler for i915 driver

2015-11-23 Thread John . C . Harrison
From: John Harrison Implemented a batch buffer submission scheduler for the i915 DRM driver. The general theory of operation is that when batch buffers are submitted to the driver, the execbuffer() code assigns a unique seqno value and then packages up all the information required to execute the

[Intel-gfx] [PATCH 07/39] drm/i915: Start of GPU scheduler

2015-11-23 Thread John . C . Harrison
From: John Harrison Initial creation of scheduler source files. Note that this patch implements most of the scheduler functionality but does not hook it in to the driver yet. It also leaves the scheduler code in 'pass through' mode so that even when it is hooked in, it will not actually do very m

[Intel-gfx] [PATCH 24/39] drm/i915: Added immediate submission override to scheduler

2015-11-23 Thread John . C . Harrison
From: John Harrison To aid with debugging issues related to the scheduler, it can be useful to ensure that all batch buffers are submitted immediately rather than queued until later. This change adds an override flag via the module parameter to force instant submission. Change-Id: I7652df53e2d3c

[Intel-gfx] [PATCH 20/39] drm/i915: Added scheduler flush calls to ring throttle and idle functions

2015-11-23 Thread John . C . Harrison
From: John Harrison When requesting that all GPU work is completed, it is now necessary to get the scheduler involved in order to flush out work that queued and not yet submitted. v2: Updated to add support for flushing the scheduler queue by time stamp rather than just doing a blanket flush. C

[Intel-gfx] [PATCH 06/39] drm/i915: Re-instate request->uniq because it is extremely useful

2015-11-23 Thread John . C . Harrison
From: John Harrison The seqno value cannot always be used when debugging issues via trace points. This is because it can be reset back to start, especially during TDR type tests. Also, when the scheduler arrives the seqno is only valid while a given request is executing on the hardware. While the

[Intel-gfx] [PATCH 14/39] drm/i915: Redirect execbuffer_final() via scheduler

2015-11-23 Thread John . C . Harrison
From: John Harrison Updated the execbuffer() code to pass the packaged up batch buffer information to the scheduler rather than calling execbuffer_final() directly. The scheduler queue() code is currently a stub which simply chains on to _final() immediately. Change-Id: I2a19062a9e66845f2e886332

[Intel-gfx] [PATCH 23/39] drm/i915: Defer seqno allocation until actual hardware submission time

2015-11-23 Thread John . C . Harrison
From: John Harrison The seqno value is now only used for the final test for completion of a request. It is no longer used to track the request through the software stack. Thus it is no longer necessary to allocate the seqno immediately with the request. Instead, it can be done lazily and left unt

[Intel-gfx] [PATCH 26/39] drm/i915: Connecting execbuff fences to scheduler

2015-11-23 Thread John . C . Harrison
From: John Harrison The scheduler now supports sync framework fences being associated with batch buffers. The execbuff IOCTL allows such fences to be passed in from user land. This patch wires the two together so that the IOCTL no longer needs to stall on the fence immediately. Instead the stall

[Intel-gfx] [PATCH 30/39] drm/i915: Added debug state dump facilities to scheduler

2015-11-23 Thread John . C . Harrison
From: John Harrison When debugging batch buffer submission issues, it is useful to be able to see what the current state of the scheduler is. This change adds functions for decoding the internal scheduler state and reporting it. Change-Id: I0634168e3f3465ff023f5a673165c90b07e535b6 For: VIZ-1587

[Intel-gfx] [PATCH 34/39] drm/i915: Add scheduler support functions for TDR

2015-11-23 Thread John . C . Harrison
From: John Harrison Change-Id: I720463f01c4edd3579ce52e315a85e4d7874d7e5 For: VIZ-1587 Signed-off-by: John Harrison --- drivers/gpu/drm/i915/i915_scheduler.c | 31 +++ drivers/gpu/drm/i915/i915_scheduler.h | 1 + 2 files changed, 32 insertions(+) diff --git a/drive

[Intel-gfx] [PATCH 27/39] drm/i915: Added trace points to scheduler

2015-11-23 Thread John . C . Harrison
From: John Harrison Added trace points to the scheduler to track all the various events, node state transitions and other interesting things that occur. v2: Updated for new request completion tracking implementation. Change-Id: I9886390cfc7897bc1faf50a104bc651d8baed8a5 For: VIZ-1587 Signed-off-

[Intel-gfx] [PATCH 33/39] drm/i915: Added seqno values to scheduler status dump

2015-11-23 Thread John . C . Harrison
From: John Harrison It is useful to be able to see what seqnos have actually popped out of the hardware when viewing the scheduler status. Change-Id: Ie93e51c64328be2606b8b43440f6344d5f225426 For: VIZ-1587 Signed-off-by: John Harrison --- drivers/gpu/drm/i915/i915_scheduler.c | 10 ++

[Intel-gfx] [PATCH 38/39] drm/i915: Add scheduling priority to per-context parameters

2015-11-23 Thread John . C . Harrison
From: Dave Gordon Added an interface for user land applications/libraries/services to set their GPU scheduler priority. This extends the existing context parameter IOCTL interface to add a scheduler priority parameter. The range is +/-1023 with +ve numbers meaning higher priority. Only system pro

[Intel-gfx] [PATCH 32/39] drm/i915: Added scheduler statistic reporting to debugfs

2015-11-23 Thread John . C . Harrison
From: John Harrison It is useful for know what the scheduler is doing for both debugging and performance analysis purposes. This change adds a bunch of counters and such that keep track of various scheduler operations (batches submitted, completed, flush requests, etc.). The data can then be read

[Intel-gfx] [PATCH 31/39] drm/i915: Add early exit to execbuff_final() if insufficient ring space

2015-11-23 Thread John . C . Harrison
From: John Harrison One of the major purposes of the GPU scheduler is to avoid stalling the CPU when the GPU is busy and unable to accept more work. This change adds support to the ring submission code to allow a ring space check to be performed before attempting to submit a batch buffer to the h

[Intel-gfx] [PATCH 16/39] drm/i915: Added tracking/locking of batch buffer objects

2015-11-23 Thread John . C . Harrison
From: John Harrison The scheduler needs to track interdependencies between batch buffers. These are calculated by analysing the object lists of the buffers and looking for commonality. The scheduler also needs to keep those buffers locked long after the initial IOCTL call has returned to user lan

[Intel-gfx] [PATCH 37/39] drm/i915: Enable GPU scheduler by default

2015-11-23 Thread John . C . Harrison
From: John Harrison Now that all the scheduler patches have been applied, it is safe to enable. Change-Id: I128042e85a30fca765ce1eb46c837c62dee66089 For: VIZ-1587 Signed-off-by: John Harrison --- drivers/gpu/drm/i915/i915_params.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff

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