* [PATCH v1 1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines
@ 2018-10-31 14:24 Tomasz Lis
2018-10-31 14:24 ` [PATCH v1 2/2] drm/i915/icl: Record the valid VDBoxes with SFC capability Tomasz Lis
` (5 more replies)
0 siblings, 6 replies; 9+ messages in thread
From: Tomasz Lis @ 2018-10-31 14:24 UTC (permalink / raw)
To: intel-gfx; +Cc: Michel Thierry
From: Oscar Mateo <oscar.mateo@intel.com>
SFC (Scaler & Format Converter) units are shared between VD and VEBoxes.
They also happen to have separate reset bits. So, whenever we want to reset
one or more of the media engines, we have to make sure the SFCs do not
change owner in the process and, if this owner happens to be one of the
engines being reset, we need to reset the SFC as well.
This happens in 4 steps:
1) Tell the engine that a software reset is going to happen. The engine
will then try to force lock the SFC (if currently locked, it will
remain so; if currently unlocked, it will ignore this and all new lock
requests).
2) Poll the ack bit to make sure the hardware has received the forced
lock from the driver. Once this bit is set, it indicates SFC status
(lock or unlock) will not change anymore (until we tell the engine it
is safe to unlock again).
3) Check the usage bit to see if the SFC has ended up being locked to
the engine we want to reset. If this is the case, we have to reset
the SFC as well.
4) Unlock all the SFCs once the reset sequence is completed.
Obviously, if we are resetting the whole GPU, we don't have to worry
about all of this.
BSpec: 10989
BSpec: 10990
BSpec: 10954
BSpec: 10955
BSpec: 10956
BSpec: 19212
Signed-off-by: Tomasz Lis <tomasz.lis@intel.com>
Signed-off-by: Oscar Mateo <oscar.mateo@intel.com>
Signed-off-by: Michel Thierry <michel.thierry@intel.com>
Cc: Michel Thierry <michel.thierry@intel.com>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
---
drivers/gpu/drm/i915/i915_reg.h | 18 +++++++
drivers/gpu/drm/i915/intel_uncore.c | 105 ++++++++++++++++++++++++++++++++++--
2 files changed, 119 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h
index 8d089ef..7b4dffa 100644
--- a/drivers/gpu/drm/i915/i915_reg.h
+++ b/drivers/gpu/drm/i915/i915_reg.h
@@ -330,6 +330,24 @@ static inline bool i915_mmio_reg_valid(i915_reg_t reg)
#define GEN11_GRDOM_MEDIA4 (1 << 8)
#define GEN11_GRDOM_VECS (1 << 13)
#define GEN11_GRDOM_VECS2 (1 << 14)
+#define GEN11_GRDOM_SFC0 (1 << 17)
+#define GEN11_GRDOM_SFC1 (1 << 18)
+
+#define GEN11_VCS_SFC_RESET_BIT(instance) (GEN11_GRDOM_SFC0 << ((instance) >> 1))
+#define GEN11_VECS_SFC_RESET_BIT(instance) (GEN11_GRDOM_SFC0 << (instance))
+
+#define GEN11_VCS_SFC_FORCED_LOCK(engine) _MMIO((engine)->mmio_base + 0x88C)
+#define GEN11_VCS_SFC_FORCED_LOCK_BIT (1 << 0)
+#define GEN11_VCS_SFC_LOCK_STATUS(engine) _MMIO((engine)->mmio_base + 0x890)
+#define GEN11_VCS_SFC_USAGE_BIT (1 << 0)
+#define GEN11_VCS_SFC_LOCK_ACK_BIT (1 << 1)
+
+#define GEN11_VECS_SFC_FORCED_LOCK(engine) _MMIO((engine)->mmio_base + 0x201C)
+#define GEN11_VECS_SFC_FORCED_LOCK_BIT (1 << 0)
+#define GEN11_VECS_SFC_LOCK_ACK(engine) _MMIO((engine)->mmio_base + 0x2018)
+#define GEN11_VECS_SFC_LOCK_ACK_BIT (1 << 0)
+#define GEN11_VECS_SFC_USAGE(engine) _MMIO((engine)->mmio_base + 0x2014)
+#define GEN11_VECS_SFC_USAGE_BIT (1 << 0)
#define RING_PP_DIR_BASE(engine) _MMIO((engine)->mmio_base + 0x228)
#define RING_PP_DIR_BASE_READ(engine) _MMIO((engine)->mmio_base + 0x518)
diff --git a/drivers/gpu/drm/i915/intel_uncore.c b/drivers/gpu/drm/i915/intel_uncore.c
index 9289515..481e70e 100644
--- a/drivers/gpu/drm/i915/intel_uncore.c
+++ b/drivers/gpu/drm/i915/intel_uncore.c
@@ -1931,6 +1931,95 @@ static int gen6_reset_engines(struct drm_i915_private *dev_priv,
return gen6_hw_domain_reset(dev_priv, hw_mask);
}
+static u32 gen11_lock_sfc(struct drm_i915_private *dev_priv,
+ struct intel_engine_cs *engine)
+{
+ u8 vdbox_sfc_access = INTEL_INFO(dev_priv)->vdbox_sfc_access;
+ i915_reg_t sfc_forced_lock;
+ u32 sfc_forced_lock_bit;
+ i915_reg_t sfc_forced_lock_ack;
+ u32 sfc_forced_lock_ack_bit;
+ i915_reg_t sfc_usage;
+ u32 sfc_usage_bit;
+ u32 sfc_reset_bit;
+
+ switch (engine->class) {
+ case VIDEO_DECODE_CLASS:
+ if ((BIT(engine->instance) & vdbox_sfc_access) == 0)
+ return 0;
+ sfc_forced_lock = GEN11_VCS_SFC_FORCED_LOCK(engine);
+ sfc_forced_lock_bit = GEN11_VCS_SFC_FORCED_LOCK_BIT;
+ sfc_forced_lock_ack = GEN11_VCS_SFC_LOCK_STATUS(engine);
+ sfc_forced_lock_ack_bit = GEN11_VCS_SFC_LOCK_ACK_BIT;
+ sfc_usage = GEN11_VCS_SFC_LOCK_STATUS(engine);
+ sfc_usage_bit = GEN11_VCS_SFC_USAGE_BIT;
+ sfc_reset_bit = GEN11_VCS_SFC_RESET_BIT(engine->instance);
+ break;
+ case VIDEO_ENHANCEMENT_CLASS:
+ sfc_forced_lock = GEN11_VECS_SFC_FORCED_LOCK(engine);
+ sfc_forced_lock_bit = GEN11_VECS_SFC_FORCED_LOCK_BIT;
+ sfc_forced_lock_ack = GEN11_VECS_SFC_LOCK_ACK(engine);
+ sfc_forced_lock_ack_bit = GEN11_VECS_SFC_LOCK_ACK_BIT;
+ sfc_usage = GEN11_VECS_SFC_USAGE(engine);
+ sfc_usage_bit = GEN11_VECS_SFC_USAGE_BIT;
+ sfc_reset_bit = GEN11_VECS_SFC_RESET_BIT(engine->instance);
+ break;
+ default:
+ return 0;
+ }
+
+ /*
+ * Tell the engine that a software reset is going to happen. The engine
+ * will then try to force lock the SFC (if currently locked, it will
+ * remain so until we tell the engine it is safe to unlock; if currently
+ * unlocked, it will ignore this and all new lock requests). If SFC
+ * ends up being locked to the engine we want to reset, we have to reset
+ * it as well (we will unlock it once the reset sequence is completed).
+ */
+ I915_WRITE(sfc_forced_lock, I915_READ(sfc_forced_lock) |
+ sfc_forced_lock_bit);
+
+ if (intel_wait_for_register(dev_priv,
+ sfc_forced_lock_ack,
+ sfc_forced_lock_ack_bit,
+ sfc_forced_lock_ack_bit,
+ 500)) {
+ DRM_DEBUG_DRIVER("Wait for SFC forced lock ack failed\n");
+ return 0;
+ }
+
+ if ((I915_READ(sfc_usage) & sfc_usage_bit) == sfc_usage_bit)
+ return sfc_reset_bit;
+
+ return 0;
+}
+
+static void gen11_unlock_sfc(struct drm_i915_private *dev_priv,
+ struct intel_engine_cs *engine)
+{
+ u8 vdbox_sfc_access = INTEL_INFO(dev_priv)->vdbox_sfc_access;
+ i915_reg_t sfc_forced_lock;
+ u32 sfc_forced_lock_bit;
+
+ switch (engine->class) {
+ case VIDEO_DECODE_CLASS:
+ if ((BIT(engine->instance) & vdbox_sfc_access) == 0)
+ return;
+ sfc_forced_lock = GEN11_VCS_SFC_FORCED_LOCK(engine);
+ sfc_forced_lock_bit = GEN11_VCS_SFC_FORCED_LOCK_BIT;
+ break;
+ case VIDEO_ENHANCEMENT_CLASS:
+ sfc_forced_lock = GEN11_VECS_SFC_FORCED_LOCK(engine);
+ sfc_forced_lock_bit = GEN11_VECS_SFC_FORCED_LOCK_BIT;
+ break;
+ default:
+ return;
+ }
+
+ I915_WRITE(sfc_forced_lock, (I915_READ(sfc_forced_lock) &
+ ~sfc_forced_lock_bit));
+}
+
/**
* gen11_reset_engines - reset individual engines
* @dev_priv: i915 device
@@ -1959,20 +2048,28 @@ static int gen11_reset_engines(struct drm_i915_private *dev_priv,
[VECS2] = GEN11_GRDOM_VECS2,
};
u32 hw_mask;
+ unsigned int tmp;
+ int ret;
BUILD_BUG_ON(VECS2 + 1 != I915_NUM_ENGINES);
if (engine_mask == ALL_ENGINES) {
hw_mask = GEN11_GRDOM_FULL;
} else {
- unsigned int tmp;
-
hw_mask = 0;
- for_each_engine_masked(engine, dev_priv, engine_mask, tmp)
+ for_each_engine_masked(engine, dev_priv, engine_mask, tmp) {
hw_mask |= hw_engine_mask[engine->id];
+ hw_mask |= gen11_lock_sfc(dev_priv, engine);
+ }
}
- return gen6_hw_domain_reset(dev_priv, hw_mask);
+ ret = gen6_hw_domain_reset(dev_priv, hw_mask);
+
+ if (engine_mask != ALL_ENGINES)
+ for_each_engine_masked(engine, dev_priv, engine_mask, tmp)
+ gen11_unlock_sfc(dev_priv, engine);
+
+ return ret;
}
/**
--
2.7.4
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH v1 2/2] drm/i915/icl: Record the valid VDBoxes with SFC capability
2018-10-31 14:24 [PATCH v1 1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines Tomasz Lis
@ 2018-10-31 14:24 ` Tomasz Lis
2018-11-01 10:21 ` Mika Kuoppala
2018-10-31 14:25 ` [PATCH v1 1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines Chris Wilson
` (4 subsequent siblings)
5 siblings, 1 reply; 9+ messages in thread
From: Tomasz Lis @ 2018-10-31 14:24 UTC (permalink / raw)
To: intel-gfx; +Cc: Michel Thierry
From: Oscar Mateo <oscar.mateo@intel.com>
In Gen11, only even numbered "logical" VDBoxes are hooked up to an SFC
(Scaler & Format Converter) unit. We will use this information to decide
when the SFC units need to be reset.
BSpec: 20189
Signed-off-by: Tomasz Lis <tomasz.lis@intel.com>
Signed-off-by: Oscar Mateo <oscar.mateo@intel.com>
Signed-off-by: Michel Thierry <michel.thierry@intel.com>
Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Cc: Michel Thierry <michel.thierry@intel.com>
Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
---
drivers/gpu/drm/i915/intel_device_info.c | 9 +++++++++
drivers/gpu/drm/i915/intel_device_info.h | 3 +++
2 files changed, 12 insertions(+)
diff --git a/drivers/gpu/drm/i915/intel_device_info.c b/drivers/gpu/drm/i915/intel_device_info.c
index 89ed3a8..e2454a7 100644
--- a/drivers/gpu/drm/i915/intel_device_info.c
+++ b/drivers/gpu/drm/i915/intel_device_info.c
@@ -881,6 +881,7 @@ void intel_device_info_init_mmio(struct drm_i915_private *dev_priv)
{
struct intel_device_info *info = mkwrite_device_info(dev_priv);
u32 media_fuse;
+ uint logical_vdbox = 0;
unsigned int i;
if (INTEL_GEN(dev_priv) < 11)
@@ -900,7 +901,15 @@ void intel_device_info_init_mmio(struct drm_i915_private *dev_priv)
if (!(BIT(i) & info->vdbox_enable)) {
info->ring_mask &= ~ENGINE_MASK(_VCS(i));
DRM_DEBUG_DRIVER("vcs%u fused off\n", i);
+ continue;
}
+
+ /*
+ * In Gen11, only even numbered logical VDBOXes are
+ * hooked up to an SFC (Scaler & Format Converter) unit.
+ */
+ if (logical_vdbox++ % 2 == 0)
+ info->vdbox_sfc_access |= BIT(i);
}
DRM_DEBUG_DRIVER("vebox enable: %04x\n", info->vebox_enable);
diff --git a/drivers/gpu/drm/i915/intel_device_info.h b/drivers/gpu/drm/i915/intel_device_info.h
index b4c2c4e..1eda80f 100644
--- a/drivers/gpu/drm/i915/intel_device_info.h
+++ b/drivers/gpu/drm/i915/intel_device_info.h
@@ -189,6 +189,9 @@ struct intel_device_info {
u8 vdbox_enable;
u8 vebox_enable;
+ /* Media engine access to SFC per instance */
+ u8 vdbox_sfc_access;
+
struct color_luts {
u16 degamma_lut_size;
u16 gamma_lut_size;
--
2.7.4
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH v1 1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines
2018-10-31 14:24 [PATCH v1 1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines Tomasz Lis
2018-10-31 14:24 ` [PATCH v1 2/2] drm/i915/icl: Record the valid VDBoxes with SFC capability Tomasz Lis
@ 2018-10-31 14:25 ` Chris Wilson
2018-10-31 14:27 ` Chris Wilson
2018-10-31 14:39 ` ✗ Fi.CI.SPARSE: warning for series starting with [v1,1/2] " Patchwork
` (3 subsequent siblings)
5 siblings, 1 reply; 9+ messages in thread
From: Chris Wilson @ 2018-10-31 14:25 UTC (permalink / raw)
To: Tomasz Lis, intel-gfx; +Cc: Michel Thierry
Quoting Tomasz Lis (2018-10-31 14:24:13)
> From: Oscar Mateo <oscar.mateo@intel.com>
>
> SFC (Scaler & Format Converter) units are shared between VD and VEBoxes.
> They also happen to have separate reset bits. So, whenever we want to reset
> one or more of the media engines, we have to make sure the SFCs do not
> change owner in the process and, if this owner happens to be one of the
> engines being reset, we need to reset the SFC as well.
>
> This happens in 4 steps:
>
> 1) Tell the engine that a software reset is going to happen. The engine
> will then try to force lock the SFC (if currently locked, it will
> remain so; if currently unlocked, it will ignore this and all new lock
> requests).
>
> 2) Poll the ack bit to make sure the hardware has received the forced
> lock from the driver. Once this bit is set, it indicates SFC status
> (lock or unlock) will not change anymore (until we tell the engine it
> is safe to unlock again).
>
> 3) Check the usage bit to see if the SFC has ended up being locked to
> the engine we want to reset. If this is the case, we have to reset
> the SFC as well.
>
> 4) Unlock all the SFCs once the reset sequence is completed.
>
> Obviously, if we are resetting the whole GPU, we don't have to worry
> about all of this.
>
> BSpec: 10989
> BSpec: 10990
> BSpec: 10954
> BSpec: 10955
> BSpec: 10956
> BSpec: 19212
>
> Signed-off-by: Tomasz Lis <tomasz.lis@intel.com>
> Signed-off-by: Oscar Mateo <oscar.mateo@intel.com>
> Signed-off-by: Michel Thierry <michel.thierry@intel.com>
> Cc: Michel Thierry <michel.thierry@intel.com>
> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
> ---
> drivers/gpu/drm/i915/i915_reg.h | 18 +++++++
> drivers/gpu/drm/i915/intel_uncore.c | 105 ++++++++++++++++++++++++++++++++++--
> 2 files changed, 119 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h
> index 8d089ef..7b4dffa 100644
> --- a/drivers/gpu/drm/i915/i915_reg.h
> +++ b/drivers/gpu/drm/i915/i915_reg.h
> @@ -330,6 +330,24 @@ static inline bool i915_mmio_reg_valid(i915_reg_t reg)
> #define GEN11_GRDOM_MEDIA4 (1 << 8)
> #define GEN11_GRDOM_VECS (1 << 13)
> #define GEN11_GRDOM_VECS2 (1 << 14)
> +#define GEN11_GRDOM_SFC0 (1 << 17)
> +#define GEN11_GRDOM_SFC1 (1 << 18)
> +
> +#define GEN11_VCS_SFC_RESET_BIT(instance) (GEN11_GRDOM_SFC0 << ((instance) >> 1))
> +#define GEN11_VECS_SFC_RESET_BIT(instance) (GEN11_GRDOM_SFC0 << (instance))
> +
> +#define GEN11_VCS_SFC_FORCED_LOCK(engine) _MMIO((engine)->mmio_base + 0x88C)
> +#define GEN11_VCS_SFC_FORCED_LOCK_BIT (1 << 0)
> +#define GEN11_VCS_SFC_LOCK_STATUS(engine) _MMIO((engine)->mmio_base + 0x890)
> +#define GEN11_VCS_SFC_USAGE_BIT (1 << 0)
> +#define GEN11_VCS_SFC_LOCK_ACK_BIT (1 << 1)
> +
> +#define GEN11_VECS_SFC_FORCED_LOCK(engine) _MMIO((engine)->mmio_base + 0x201C)
> +#define GEN11_VECS_SFC_FORCED_LOCK_BIT (1 << 0)
> +#define GEN11_VECS_SFC_LOCK_ACK(engine) _MMIO((engine)->mmio_base + 0x2018)
> +#define GEN11_VECS_SFC_LOCK_ACK_BIT (1 << 0)
> +#define GEN11_VECS_SFC_USAGE(engine) _MMIO((engine)->mmio_base + 0x2014)
> +#define GEN11_VECS_SFC_USAGE_BIT (1 << 0)
>
> #define RING_PP_DIR_BASE(engine) _MMIO((engine)->mmio_base + 0x228)
> #define RING_PP_DIR_BASE_READ(engine) _MMIO((engine)->mmio_base + 0x518)
> diff --git a/drivers/gpu/drm/i915/intel_uncore.c b/drivers/gpu/drm/i915/intel_uncore.c
> index 9289515..481e70e 100644
> --- a/drivers/gpu/drm/i915/intel_uncore.c
> +++ b/drivers/gpu/drm/i915/intel_uncore.c
> @@ -1931,6 +1931,95 @@ static int gen6_reset_engines(struct drm_i915_private *dev_priv,
> return gen6_hw_domain_reset(dev_priv, hw_mask);
> }
>
> +static u32 gen11_lock_sfc(struct drm_i915_private *dev_priv,
> + struct intel_engine_cs *engine)
> +{
> + u8 vdbox_sfc_access = INTEL_INFO(dev_priv)->vdbox_sfc_access;
> + i915_reg_t sfc_forced_lock;
> + u32 sfc_forced_lock_bit;
> + i915_reg_t sfc_forced_lock_ack;
> + u32 sfc_forced_lock_ack_bit;
> + i915_reg_t sfc_usage;
> + u32 sfc_usage_bit;
> + u32 sfc_reset_bit;
> +
> + switch (engine->class) {
> + case VIDEO_DECODE_CLASS:
> + if ((BIT(engine->instance) & vdbox_sfc_access) == 0)
> + return 0;
> + sfc_forced_lock = GEN11_VCS_SFC_FORCED_LOCK(engine);
> + sfc_forced_lock_bit = GEN11_VCS_SFC_FORCED_LOCK_BIT;
> + sfc_forced_lock_ack = GEN11_VCS_SFC_LOCK_STATUS(engine);
> + sfc_forced_lock_ack_bit = GEN11_VCS_SFC_LOCK_ACK_BIT;
> + sfc_usage = GEN11_VCS_SFC_LOCK_STATUS(engine);
> + sfc_usage_bit = GEN11_VCS_SFC_USAGE_BIT;
> + sfc_reset_bit = GEN11_VCS_SFC_RESET_BIT(engine->instance);
> + break;
> + case VIDEO_ENHANCEMENT_CLASS:
> + sfc_forced_lock = GEN11_VECS_SFC_FORCED_LOCK(engine);
> + sfc_forced_lock_bit = GEN11_VECS_SFC_FORCED_LOCK_BIT;
> + sfc_forced_lock_ack = GEN11_VECS_SFC_LOCK_ACK(engine);
> + sfc_forced_lock_ack_bit = GEN11_VECS_SFC_LOCK_ACK_BIT;
> + sfc_usage = GEN11_VECS_SFC_USAGE(engine);
> + sfc_usage_bit = GEN11_VECS_SFC_USAGE_BIT;
> + sfc_reset_bit = GEN11_VECS_SFC_RESET_BIT(engine->instance);
> + break;
> + default:
> + return 0;
> + }
> +
> + /*
> + * Tell the engine that a software reset is going to happen. The engine
> + * will then try to force lock the SFC (if currently locked, it will
> + * remain so until we tell the engine it is safe to unlock; if currently
> + * unlocked, it will ignore this and all new lock requests). If SFC
> + * ends up being locked to the engine we want to reset, we have to reset
> + * it as well (we will unlock it once the reset sequence is completed).
> + */
> + I915_WRITE(sfc_forced_lock, I915_READ(sfc_forced_lock) |
> + sfc_forced_lock_bit);
> +
> + if (intel_wait_for_register(dev_priv,
> + sfc_forced_lock_ack,
> + sfc_forced_lock_ack_bit,
> + sfc_forced_lock_ack_bit,
> + 500)) {
Sleeping is not allowed.
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v1 1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines
2018-10-31 14:25 ` [PATCH v1 1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines Chris Wilson
@ 2018-10-31 14:27 ` Chris Wilson
0 siblings, 0 replies; 9+ messages in thread
From: Chris Wilson @ 2018-10-31 14:27 UTC (permalink / raw)
To: Tomasz Lis, intel-gfx; +Cc: Michel Thierry
Quoting Chris Wilson (2018-10-31 14:25:40)
> Quoting Tomasz Lis (2018-10-31 14:24:13)
> > From: Oscar Mateo <oscar.mateo@intel.com>
> >
> > SFC (Scaler & Format Converter) units are shared between VD and VEBoxes.
> > They also happen to have separate reset bits. So, whenever we want to reset
> > one or more of the media engines, we have to make sure the SFCs do not
> > change owner in the process and, if this owner happens to be one of the
> > engines being reset, we need to reset the SFC as well.
> >
> > This happens in 4 steps:
> >
> > 1) Tell the engine that a software reset is going to happen. The engine
> > will then try to force lock the SFC (if currently locked, it will
> > remain so; if currently unlocked, it will ignore this and all new lock
> > requests).
> >
> > 2) Poll the ack bit to make sure the hardware has received the forced
> > lock from the driver. Once this bit is set, it indicates SFC status
> > (lock or unlock) will not change anymore (until we tell the engine it
> > is safe to unlock again).
> >
> > 3) Check the usage bit to see if the SFC has ended up being locked to
> > the engine we want to reset. If this is the case, we have to reset
> > the SFC as well.
> >
> > 4) Unlock all the SFCs once the reset sequence is completed.
> >
> > Obviously, if we are resetting the whole GPU, we don't have to worry
> > about all of this.
> >
> > BSpec: 10989
> > BSpec: 10990
> > BSpec: 10954
> > BSpec: 10955
> > BSpec: 10956
> > BSpec: 19212
> >
> > Signed-off-by: Tomasz Lis <tomasz.lis@intel.com>
> > Signed-off-by: Oscar Mateo <oscar.mateo@intel.com>
> > Signed-off-by: Michel Thierry <michel.thierry@intel.com>
> > Cc: Michel Thierry <michel.thierry@intel.com>
> > Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> > Cc: Chris Wilson <chris@chris-wilson.co.uk>
> > Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
> > ---
> > drivers/gpu/drm/i915/i915_reg.h | 18 +++++++
> > drivers/gpu/drm/i915/intel_uncore.c | 105 ++++++++++++++++++++++++++++++++++--
> > 2 files changed, 119 insertions(+), 4 deletions(-)
> >
> > diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h
> > index 8d089ef..7b4dffa 100644
> > --- a/drivers/gpu/drm/i915/i915_reg.h
> > +++ b/drivers/gpu/drm/i915/i915_reg.h
> > @@ -330,6 +330,24 @@ static inline bool i915_mmio_reg_valid(i915_reg_t reg)
> > #define GEN11_GRDOM_MEDIA4 (1 << 8)
> > #define GEN11_GRDOM_VECS (1 << 13)
> > #define GEN11_GRDOM_VECS2 (1 << 14)
> > +#define GEN11_GRDOM_SFC0 (1 << 17)
> > +#define GEN11_GRDOM_SFC1 (1 << 18)
> > +
> > +#define GEN11_VCS_SFC_RESET_BIT(instance) (GEN11_GRDOM_SFC0 << ((instance) >> 1))
> > +#define GEN11_VECS_SFC_RESET_BIT(instance) (GEN11_GRDOM_SFC0 << (instance))
> > +
> > +#define GEN11_VCS_SFC_FORCED_LOCK(engine) _MMIO((engine)->mmio_base + 0x88C)
> > +#define GEN11_VCS_SFC_FORCED_LOCK_BIT (1 << 0)
> > +#define GEN11_VCS_SFC_LOCK_STATUS(engine) _MMIO((engine)->mmio_base + 0x890)
> > +#define GEN11_VCS_SFC_USAGE_BIT (1 << 0)
> > +#define GEN11_VCS_SFC_LOCK_ACK_BIT (1 << 1)
> > +
> > +#define GEN11_VECS_SFC_FORCED_LOCK(engine) _MMIO((engine)->mmio_base + 0x201C)
> > +#define GEN11_VECS_SFC_FORCED_LOCK_BIT (1 << 0)
> > +#define GEN11_VECS_SFC_LOCK_ACK(engine) _MMIO((engine)->mmio_base + 0x2018)
> > +#define GEN11_VECS_SFC_LOCK_ACK_BIT (1 << 0)
> > +#define GEN11_VECS_SFC_USAGE(engine) _MMIO((engine)->mmio_base + 0x2014)
> > +#define GEN11_VECS_SFC_USAGE_BIT (1 << 0)
> >
> > #define RING_PP_DIR_BASE(engine) _MMIO((engine)->mmio_base + 0x228)
> > #define RING_PP_DIR_BASE_READ(engine) _MMIO((engine)->mmio_base + 0x518)
> > diff --git a/drivers/gpu/drm/i915/intel_uncore.c b/drivers/gpu/drm/i915/intel_uncore.c
> > index 9289515..481e70e 100644
> > --- a/drivers/gpu/drm/i915/intel_uncore.c
> > +++ b/drivers/gpu/drm/i915/intel_uncore.c
> > @@ -1931,6 +1931,95 @@ static int gen6_reset_engines(struct drm_i915_private *dev_priv,
> > return gen6_hw_domain_reset(dev_priv, hw_mask);
> > }
> >
> > +static u32 gen11_lock_sfc(struct drm_i915_private *dev_priv,
> > + struct intel_engine_cs *engine)
> > +{
> > + u8 vdbox_sfc_access = INTEL_INFO(dev_priv)->vdbox_sfc_access;
> > + i915_reg_t sfc_forced_lock;
> > + u32 sfc_forced_lock_bit;
> > + i915_reg_t sfc_forced_lock_ack;
> > + u32 sfc_forced_lock_ack_bit;
> > + i915_reg_t sfc_usage;
> > + u32 sfc_usage_bit;
> > + u32 sfc_reset_bit;
> > +
> > + switch (engine->class) {
> > + case VIDEO_DECODE_CLASS:
> > + if ((BIT(engine->instance) & vdbox_sfc_access) == 0)
> > + return 0;
> > + sfc_forced_lock = GEN11_VCS_SFC_FORCED_LOCK(engine);
> > + sfc_forced_lock_bit = GEN11_VCS_SFC_FORCED_LOCK_BIT;
> > + sfc_forced_lock_ack = GEN11_VCS_SFC_LOCK_STATUS(engine);
> > + sfc_forced_lock_ack_bit = GEN11_VCS_SFC_LOCK_ACK_BIT;
> > + sfc_usage = GEN11_VCS_SFC_LOCK_STATUS(engine);
> > + sfc_usage_bit = GEN11_VCS_SFC_USAGE_BIT;
> > + sfc_reset_bit = GEN11_VCS_SFC_RESET_BIT(engine->instance);
> > + break;
> > + case VIDEO_ENHANCEMENT_CLASS:
> > + sfc_forced_lock = GEN11_VECS_SFC_FORCED_LOCK(engine);
> > + sfc_forced_lock_bit = GEN11_VECS_SFC_FORCED_LOCK_BIT;
> > + sfc_forced_lock_ack = GEN11_VECS_SFC_LOCK_ACK(engine);
> > + sfc_forced_lock_ack_bit = GEN11_VECS_SFC_LOCK_ACK_BIT;
> > + sfc_usage = GEN11_VECS_SFC_USAGE(engine);
> > + sfc_usage_bit = GEN11_VECS_SFC_USAGE_BIT;
> > + sfc_reset_bit = GEN11_VECS_SFC_RESET_BIT(engine->instance);
> > + break;
> > + default:
> > + return 0;
> > + }
> > +
> > + /*
> > + * Tell the engine that a software reset is going to happen. The engine
> > + * will then try to force lock the SFC (if currently locked, it will
> > + * remain so until we tell the engine it is safe to unlock; if currently
> > + * unlocked, it will ignore this and all new lock requests). If SFC
> > + * ends up being locked to the engine we want to reset, we have to reset
> > + * it as well (we will unlock it once the reset sequence is completed).
> > + */
> > + I915_WRITE(sfc_forced_lock, I915_READ(sfc_forced_lock) |
> > + sfc_forced_lock_bit);
> > +
> > + if (intel_wait_for_register(dev_priv,
> > + sfc_forced_lock_ack,
> > + sfc_forced_lock_ack_bit,
> > + sfc_forced_lock_ack_bit,
> > + 500)) {
>
> Sleeping is not allowed.
I guess you really should review the selftests first.
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 9+ messages in thread
* ✗ Fi.CI.SPARSE: warning for series starting with [v1,1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines
2018-10-31 14:24 [PATCH v1 1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines Tomasz Lis
2018-10-31 14:24 ` [PATCH v1 2/2] drm/i915/icl: Record the valid VDBoxes with SFC capability Tomasz Lis
2018-10-31 14:25 ` [PATCH v1 1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines Chris Wilson
@ 2018-10-31 14:39 ` Patchwork
2018-10-31 14:55 ` ✓ Fi.CI.BAT: success " Patchwork
` (2 subsequent siblings)
5 siblings, 0 replies; 9+ messages in thread
From: Patchwork @ 2018-10-31 14:39 UTC (permalink / raw)
To: Tomasz Lis; +Cc: intel-gfx
== Series Details ==
Series: series starting with [v1,1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines
URL : https://patchwork.freedesktop.org/series/51816/
State : warning
== Summary ==
$ dim sparse origin/drm-tip
Sparse version: v0.5.2
Commit: drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines
+ ^~~~~~~~~~~~~~~~
+ ^~~~~~~~~~~~~~~~
-drivers/gpu/drm/i915/gvt/gtt.c:757:9: expected void [noderef] <asn:4>**slot
-drivers/gpu/drm/i915/gvt/gtt.c:757:9: expected void **slot
-drivers/gpu/drm/i915/gvt/gtt.c:757:9: expected void **slot
-drivers/gpu/drm/i915/gvt/gtt.c:757:9: expected void **slot
-drivers/gpu/drm/i915/gvt/gtt.c:757:9: got void [noderef] <asn:4>**
-drivers/gpu/drm/i915/gvt/gtt.c:757:9: got void [noderef] <asn:4>**
-drivers/gpu/drm/i915/gvt/gtt.c:757:9: got void [noderef] <asn:4>**
-drivers/gpu/drm/i915/gvt/gtt.c:757:9: got void **slot
-drivers/gpu/drm/i915/gvt/gtt.c:757:9: warning: incorrect type in argument 1 (different address spaces)
-drivers/gpu/drm/i915/gvt/gtt.c:757:9: warning: incorrect type in assignment (different address spaces)
-drivers/gpu/drm/i915/gvt/gtt.c:757:9: warning: incorrect type in assignment (different address spaces)
-drivers/gpu/drm/i915/gvt/gtt.c:757:9: warning: incorrect type in assignment (different address spaces)
-drivers/gpu/drm/i915/gvt/gtt.c:758:45: expected void [noderef] <asn:4>**slot
-drivers/gpu/drm/i915/gvt/gtt.c:758:45: got void **slot
-drivers/gpu/drm/i915/gvt/gtt.c:758:45: warning: incorrect type in argument 1 (different address spaces)
-drivers/gpu/drm/i915/gvt/mmio.c:282:23: warning: memcpy with byte count of 279040
-drivers/gpu/drm/i915/gvt/mmio.c:283:23: warning: memcpy with byte count of 279040
-drivers/gpu/drm/i915/gvt/vgpu.c:196:48: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/gvt/vgpu.c:196:48: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/gvt/vgpu.c:196:48: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/gvt/vgpu.c:196:48: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/gvt/vgpu.c:196:48: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/gvt/vgpu.c:196:48: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/gvt/vgpu.c:196:48: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/gvt/vgpu.c:196:48: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/gvt/vgpu.c:196:48: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/gvt/vgpu.c:196:48: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/gvt/vgpu.c:196:48: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/gvt/vgpu.c:196:48: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/gvt/vgpu.c:196:48: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/gvt/vgpu.c:196:48: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_drv.h:3699:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_drv.h:3699:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_drv.h:3699:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_drv.h:3699:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_drv.h:3699:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_gpu_error.c:963:21: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_gpu_error.c:963:21: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/i915_perf.c:2665:17: warning: too many warnings
-drivers/gpu/drm/i915/intel_ddi.c:696:24: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_ddi.c:698:24: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp_aux_backlight.c:157:21: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp_aux_backlight.c:157:21: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp_aux_backlight.c:157:21: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp_aux_backlight.c:157:21: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp_aux_backlight.c:157:21: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp_aux_backlight.c:157:21: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp_aux_backlight.c:157:21: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:1467:39: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:1467:39: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:1467:39: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:1467:39: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:1467:39: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:1467:39: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:1467:39: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:1467:39: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:1867:23: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:1867:23: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:210:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:210:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:210:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:210:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:210:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:210:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:210:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:210:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:210:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:210:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:210:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:210:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:210:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:210:16: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:387:30: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:387:30: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:478:28: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:478:28: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5482:30: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5856:31: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5885:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5885:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5885:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5885:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5886:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5886:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5886:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5886:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5887:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5887:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5887:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5887:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5888:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5888:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5888:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5888:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5889:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5889:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5889:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dp.c:5889:9: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dsi_vbt.c:534:25: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dsi_vbt.c:534:25: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dsi_vbt.c:535:26: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dsi_vbt.c:535:26: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dsi_vbt.c:670:26: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dsi_vbt.c:670:26: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dsi_vbt.c:712:25: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dsi_vbt.c:712:25: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dsi_vbt.c:744:37: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_dsi_vbt.c:744:37: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_hdmi.c:1489:34: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_hdmi.c:1489:34: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_hdmi.c:1506:42: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_hdmi.c:1506:42: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_hdmi.c:1510:42: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_hdmi.c:1510:42: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_hdmi.c:1513:42: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_i2c.c:443:31: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_i2c.c:445:31: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_i2c.c:445:31: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_i2c.c:507:23: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_i2c.c:507:23: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1473:15: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1473:15: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1473:15: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1473:15: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1473:15: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1473:15: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1473:15: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1512:34: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1512:34: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1512:34: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1512:34: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1512:34: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1512:34: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1512:34: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1512:34: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1512:34: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1512:34: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1512:34: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1512:34: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1512:34: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1512:34: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1542:34: warning: expression using sizeof(void)
-drivers/gpu/drm/i915/intel_panel.c:1542:34: warning: expre
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 9+ messages in thread
* ✓ Fi.CI.BAT: success for series starting with [v1,1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines
2018-10-31 14:24 [PATCH v1 1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines Tomasz Lis
` (2 preceding siblings ...)
2018-10-31 14:39 ` ✗ Fi.CI.SPARSE: warning for series starting with [v1,1/2] " Patchwork
@ 2018-10-31 14:55 ` Patchwork
2018-10-31 19:57 ` ✓ Fi.CI.IGT: " Patchwork
2018-11-01 10:22 ` [PATCH v1 1/2] " Mika Kuoppala
5 siblings, 0 replies; 9+ messages in thread
From: Patchwork @ 2018-10-31 14:55 UTC (permalink / raw)
To: Tomasz Lis; +Cc: intel-gfx
== Series Details ==
Series: series starting with [v1,1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines
URL : https://patchwork.freedesktop.org/series/51816/
State : success
== Summary ==
= CI Bug Log - changes from CI_DRM_5062 -> Patchwork_10668 =
== Summary - WARNING ==
Minor unknown changes coming with Patchwork_10668 need to be verified
manually.
If you think the reported changes have nothing to do with the changes
introduced in Patchwork_10668, please notify your bug team to allow them
to document this new failure mode, which will reduce false positives in CI.
External URL: https://patchwork.freedesktop.org/api/1.0/series/51816/revisions/1/mbox/
== Possible new issues ==
Here are the unknown changes that may have been introduced in Patchwork_10668:
=== IGT changes ===
==== Warnings ====
igt@drv_selftest@live_guc:
fi-icl-u: PASS -> SKIP +2
== Known issues ==
Here are the changes found in Patchwork_10668 that come from known issues:
=== IGT changes ===
==== Issues hit ====
igt@gem_exec_suspend@basic-s3:
fi-blb-e6850: PASS -> INCOMPLETE (fdo#107718)
igt@kms_frontbuffer_tracking@basic:
fi-byt-clapper: PASS -> FAIL (fdo#103167)
igt@kms_pipe_crc_basic@read-crc-pipe-a:
fi-byt-clapper: PASS -> FAIL (fdo#107362)
==== Possible fixes ====
igt@kms_chamelium@common-hpd-after-suspend:
fi-skl-6700k2: INCOMPLETE (fdo#105524, fdo#104108, k.org#199541) -> PASS
igt@kms_flip@basic-flip-vs-dpms:
fi-skl-6700hq: DMESG-WARN (fdo#105998) -> PASS
igt@kms_pipe_crc_basic@read-crc-pipe-b:
fi-byt-clapper: FAIL (fdo#107362) -> PASS
==== Warnings ====
igt@drv_selftest@live_contexts:
fi-icl-u: DMESG-FAIL (fdo#108569) -> INCOMPLETE (fdo#108315)
fdo#103167 https://bugs.freedesktop.org/show_bug.cgi?id=103167
fdo#104108 https://bugs.freedesktop.org/show_bug.cgi?id=104108
fdo#105524 https://bugs.freedesktop.org/show_bug.cgi?id=105524
fdo#105998 https://bugs.freedesktop.org/show_bug.cgi?id=105998
fdo#107362 https://bugs.freedesktop.org/show_bug.cgi?id=107362
fdo#107718 https://bugs.freedesktop.org/show_bug.cgi?id=107718
fdo#108315 https://bugs.freedesktop.org/show_bug.cgi?id=108315
fdo#108569 https://bugs.freedesktop.org/show_bug.cgi?id=108569
k.org#199541 https://bugzilla.kernel.org/show_bug.cgi?id=199541
== Participating hosts (49 -> 43) ==
Missing (6): fi-kbl-soraka fi-ilk-m540 fi-hsw-4200u fi-byt-squawks fi-bsw-cyan fi-ctg-p8600
== Build changes ==
* Linux: CI_DRM_5062 -> Patchwork_10668
CI_DRM_5062: 3aa71a0d803ee01605f9a3026ddd989a591a73c6 @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_4703: f882a542a3eb24e78e51aa6410a3a67c0efb4e97 @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
Patchwork_10668: b897392b2c865b32eae213d3e1eb8d6ee6b586e5 @ git://anongit.freedesktop.org/gfx-ci/linux
== Linux commits ==
b897392b2c86 drm/i915/icl: Record the valid VDBoxes with SFC capability
5f82fce36fcf drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_10668/issues.html
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 9+ messages in thread
* ✓ Fi.CI.IGT: success for series starting with [v1,1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines
2018-10-31 14:24 [PATCH v1 1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines Tomasz Lis
` (3 preceding siblings ...)
2018-10-31 14:55 ` ✓ Fi.CI.BAT: success " Patchwork
@ 2018-10-31 19:57 ` Patchwork
2018-11-01 10:22 ` [PATCH v1 1/2] " Mika Kuoppala
5 siblings, 0 replies; 9+ messages in thread
From: Patchwork @ 2018-10-31 19:57 UTC (permalink / raw)
To: Tomasz Lis; +Cc: intel-gfx
== Series Details ==
Series: series starting with [v1,1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines
URL : https://patchwork.freedesktop.org/series/51816/
State : success
== Summary ==
= CI Bug Log - changes from CI_DRM_5062_full -> Patchwork_10668_full =
== Summary - WARNING ==
Minor unknown changes coming with Patchwork_10668_full need to be verified
manually.
If you think the reported changes have nothing to do with the changes
introduced in Patchwork_10668_full, please notify your bug team to allow them
to document this new failure mode, which will reduce false positives in CI.
== Possible new issues ==
Here are the unknown changes that may have been introduced in Patchwork_10668_full:
=== IGT changes ===
==== Warnings ====
igt@pm_rc6_residency@rc6-accuracy:
shard-kbl: PASS -> SKIP
== Known issues ==
Here are the changes found in Patchwork_10668_full that come from known issues:
=== IGT changes ===
==== Issues hit ====
igt@gem_exec_faulting_reloc@normal:
shard-glk: PASS -> DMESG-WARN (fdo#106538, fdo#105763) +1
igt@gem_exec_schedule@pi-ringfull-bsd:
shard-skl: NOTRUN -> FAIL (fdo#103158)
igt@gem_exec_whisper@normal:
shard-skl: NOTRUN -> TIMEOUT (fdo#108592)
igt@kms_available_modes_crc@available_mode_test_crc:
shard-apl: PASS -> FAIL (fdo#106641)
igt@kms_busy@extended-modeset-hang-newfb-with-reset-render-b:
shard-skl: NOTRUN -> DMESG-WARN (fdo#107956)
igt@kms_busy@extended-pageflip-modeset-hang-oldfb-render-a:
shard-snb: NOTRUN -> DMESG-WARN (fdo#107956) +1
igt@kms_cursor_crc@cursor-256x85-random:
shard-apl: PASS -> FAIL (fdo#103232) +3
igt@kms_cursor_crc@cursor-64x64-sliding:
shard-glk: PASS -> FAIL (fdo#103232) +3
igt@kms_cursor_legacy@2x-nonblocking-modeset-vs-cursor-atomic:
shard-glk: NOTRUN -> FAIL (fdo#105454, fdo#106509)
igt@kms_frontbuffer_tracking@fbc-1p-pri-indfb-multidraw:
shard-glk: PASS -> FAIL (fdo#103167) +1
igt@kms_frontbuffer_tracking@fbc-1p-primscrn-spr-indfb-draw-mmap-gtt:
shard-apl: PASS -> FAIL (fdo#103167) +2
igt@kms_plane_alpha_blend@pipe-a-alpha-transparant-fb:
shard-apl: NOTRUN -> FAIL (fdo#108145)
igt@kms_plane_alpha_blend@pipe-c-alpha-basic:
shard-glk: NOTRUN -> FAIL (fdo#108145)
igt@kms_plane_alpha_blend@pipe-c-constant-alpha-mid:
shard-kbl: PASS -> DMESG-WARN (fdo#105345, fdo#103313)
igt@pm_rpm@gem-execbuf-stress-extra-wait:
shard-skl: NOTRUN -> INCOMPLETE (fdo#107803, fdo#107807)
igt@pm_rpm@legacy-planes-dpms:
shard-skl: PASS -> INCOMPLETE (fdo#105959, fdo#107807)
==== Possible fixes ====
igt@gem_ppgtt@blt-vs-render-ctx0:
shard-kbl: INCOMPLETE (fdo#106887, fdo#103665, fdo#106023) -> PASS
igt@kms_color@pipe-b-degamma:
shard-apl: FAIL (fdo#104782) -> PASS
igt@kms_cursor_crc@cursor-256x256-suspend:
shard-apl: FAIL (fdo#103232, fdo#103191) -> PASS
igt@kms_cursor_crc@cursor-256x85-random:
shard-glk: FAIL (fdo#103232) -> PASS
igt@kms_cursor_crc@cursor-64x21-random:
shard-apl: FAIL (fdo#103232) -> PASS +3
igt@kms_cursor_legacy@cursorb-vs-flipb-toggle:
shard-glk: DMESG-WARN (fdo#106538, fdo#105763) -> PASS
igt@kms_frontbuffer_tracking@fbc-1p-primscrn-spr-indfb-draw-mmap-cpu:
shard-apl: FAIL (fdo#103167) -> PASS
igt@kms_plane_alpha_blend@pipe-c-alpha-7efc:
shard-apl: FAIL (fdo#108145) -> PASS
igt@kms_plane_multiple@atomic-pipe-a-tiling-yf:
shard-apl: FAIL (fdo#103166) -> PASS +1
fdo#103158 https://bugs.freedesktop.org/show_bug.cgi?id=103158
fdo#103166 https://bugs.freedesktop.org/show_bug.cgi?id=103166
fdo#103167 https://bugs.freedesktop.org/show_bug.cgi?id=103167
fdo#103191 https://bugs.freedesktop.org/show_bug.cgi?id=103191
fdo#103232 https://bugs.freedesktop.org/show_bug.cgi?id=103232
fdo#103313 https://bugs.freedesktop.org/show_bug.cgi?id=103313
fdo#103665 https://bugs.freedesktop.org/show_bug.cgi?id=103665
fdo#104782 https://bugs.freedesktop.org/show_bug.cgi?id=104782
fdo#105345 https://bugs.freedesktop.org/show_bug.cgi?id=105345
fdo#105454 https://bugs.freedesktop.org/show_bug.cgi?id=105454
fdo#105763 https://bugs.freedesktop.org/show_bug.cgi?id=105763
fdo#105959 https://bugs.freedesktop.org/show_bug.cgi?id=105959
fdo#106023 https://bugs.freedesktop.org/show_bug.cgi?id=106023
fdo#106509 https://bugs.freedesktop.org/show_bug.cgi?id=106509
fdo#106538 https://bugs.freedesktop.org/show_bug.cgi?id=106538
fdo#106641 https://bugs.freedesktop.org/show_bug.cgi?id=106641
fdo#106887 https://bugs.freedesktop.org/show_bug.cgi?id=106887
fdo#107803 https://bugs.freedesktop.org/show_bug.cgi?id=107803
fdo#107807 https://bugs.freedesktop.org/show_bug.cgi?id=107807
fdo#107956 https://bugs.freedesktop.org/show_bug.cgi?id=107956
fdo#108145 https://bugs.freedesktop.org/show_bug.cgi?id=108145
fdo#108592 https://bugs.freedesktop.org/show_bug.cgi?id=108592
== Participating hosts (6 -> 6) ==
No changes in participating hosts
== Build changes ==
* Linux: CI_DRM_5062 -> Patchwork_10668
CI_DRM_5062: 3aa71a0d803ee01605f9a3026ddd989a591a73c6 @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_4703: f882a542a3eb24e78e51aa6410a3a67c0efb4e97 @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
Patchwork_10668: b897392b2c865b32eae213d3e1eb8d6ee6b586e5 @ git://anongit.freedesktop.org/gfx-ci/linux
piglit_4509: fdc5a4ca11124ab8413c7988896eec4c97336694 @ git://anongit.freedesktop.org/piglit
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_10668/shards.html
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v1 2/2] drm/i915/icl: Record the valid VDBoxes with SFC capability
2018-10-31 14:24 ` [PATCH v1 2/2] drm/i915/icl: Record the valid VDBoxes with SFC capability Tomasz Lis
@ 2018-11-01 10:21 ` Mika Kuoppala
0 siblings, 0 replies; 9+ messages in thread
From: Mika Kuoppala @ 2018-11-01 10:21 UTC (permalink / raw)
To: Tomasz Lis, intel-gfx; +Cc: Michel Thierry
Tomasz Lis <tomasz.lis@intel.com> writes:
> From: Oscar Mateo <oscar.mateo@intel.com>
>
> In Gen11, only even numbered "logical" VDBoxes are hooked up to an SFC
> (Scaler & Format Converter) unit. We will use this information to decide
> when the SFC units need to be reset.
>
> BSpec: 20189
>
> Signed-off-by: Tomasz Lis <tomasz.lis@intel.com>
> Signed-off-by: Oscar Mateo <oscar.mateo@intel.com>
> Signed-off-by: Michel Thierry <michel.thierry@intel.com>
> Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
> Cc: Michel Thierry <michel.thierry@intel.com>
> Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
> ---
> drivers/gpu/drm/i915/intel_device_info.c | 9 +++++++++
> drivers/gpu/drm/i915/intel_device_info.h | 3 +++
> 2 files changed, 12 insertions(+)
>
> diff --git a/drivers/gpu/drm/i915/intel_device_info.c b/drivers/gpu/drm/i915/intel_device_info.c
> index 89ed3a8..e2454a7 100644
> --- a/drivers/gpu/drm/i915/intel_device_info.c
> +++ b/drivers/gpu/drm/i915/intel_device_info.c
> @@ -881,6 +881,7 @@ void intel_device_info_init_mmio(struct drm_i915_private *dev_priv)
> {
> struct intel_device_info *info = mkwrite_device_info(dev_priv);
> u32 media_fuse;
> + uint logical_vdbox = 0;
> unsigned int i;
we do not use uints.
unsigned int i, logical_vdbox = 0;
>
> if (INTEL_GEN(dev_priv) < 11)
> @@ -900,7 +901,15 @@ void intel_device_info_init_mmio(struct drm_i915_private *dev_priv)
> if (!(BIT(i) & info->vdbox_enable)) {
> info->ring_mask &= ~ENGINE_MASK(_VCS(i));
> DRM_DEBUG_DRIVER("vcs%u fused off\n", i);
> + continue;
> }
This becomes more readable with:
if (info->vdbox_enable & BIT(i)) {
} else {
}
Thanks,
-Mika
> +
> + /*
> + * In Gen11, only even numbered logical VDBOXes are
> + * hooked up to an SFC (Scaler & Format Converter) unit.
> + */
> + if (logical_vdbox++ % 2 == 0)
> + info->vdbox_sfc_access |= BIT(i);
> }
>
> DRM_DEBUG_DRIVER("vebox enable: %04x\n", info->vebox_enable);
> diff --git a/drivers/gpu/drm/i915/intel_device_info.h b/drivers/gpu/drm/i915/intel_device_info.h
> index b4c2c4e..1eda80f 100644
> --- a/drivers/gpu/drm/i915/intel_device_info.h
> +++ b/drivers/gpu/drm/i915/intel_device_info.h
> @@ -189,6 +189,9 @@ struct intel_device_info {
> u8 vdbox_enable;
> u8 vebox_enable;
>
> + /* Media engine access to SFC per instance */
> + u8 vdbox_sfc_access;
> +
> struct color_luts {
> u16 degamma_lut_size;
> u16 gamma_lut_size;
> --
> 2.7.4
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v1 1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines
2018-10-31 14:24 [PATCH v1 1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines Tomasz Lis
` (4 preceding siblings ...)
2018-10-31 19:57 ` ✓ Fi.CI.IGT: " Patchwork
@ 2018-11-01 10:22 ` Mika Kuoppala
5 siblings, 0 replies; 9+ messages in thread
From: Mika Kuoppala @ 2018-11-01 10:22 UTC (permalink / raw)
To: Tomasz Lis, intel-gfx; +Cc: Michel Thierry
Tomasz Lis <tomasz.lis@intel.com> writes:
> From: Oscar Mateo <oscar.mateo@intel.com>
>
> SFC (Scaler & Format Converter) units are shared between VD and VEBoxes.
> They also happen to have separate reset bits. So, whenever we want to reset
> one or more of the media engines, we have to make sure the SFCs do not
> change owner in the process and, if this owner happens to be one of the
> engines being reset, we need to reset the SFC as well.
>
> This happens in 4 steps:
>
> 1) Tell the engine that a software reset is going to happen. The engine
> will then try to force lock the SFC (if currently locked, it will
> remain so; if currently unlocked, it will ignore this and all new lock
> requests).
>
> 2) Poll the ack bit to make sure the hardware has received the forced
> lock from the driver. Once this bit is set, it indicates SFC status
> (lock or unlock) will not change anymore (until we tell the engine it
> is safe to unlock again).
>
> 3) Check the usage bit to see if the SFC has ended up being locked to
> the engine we want to reset. If this is the case, we have to reset
> the SFC as well.
>
> 4) Unlock all the SFCs once the reset sequence is completed.
>
> Obviously, if we are resetting the whole GPU, we don't have to worry
> about all of this.
>
> BSpec: 10989
> BSpec: 10990
> BSpec: 10954
> BSpec: 10955
> BSpec: 10956
> BSpec: 19212
>
> Signed-off-by: Tomasz Lis <tomasz.lis@intel.com>
> Signed-off-by: Oscar Mateo <oscar.mateo@intel.com>
> Signed-off-by: Michel Thierry <michel.thierry@intel.com>
> Cc: Michel Thierry <michel.thierry@intel.com>
> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
> ---
> drivers/gpu/drm/i915/i915_reg.h | 18 +++++++
> drivers/gpu/drm/i915/intel_uncore.c | 105 ++++++++++++++++++++++++++++++++++--
> 2 files changed, 119 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h
> index 8d089ef..7b4dffa 100644
> --- a/drivers/gpu/drm/i915/i915_reg.h
> +++ b/drivers/gpu/drm/i915/i915_reg.h
> @@ -330,6 +330,24 @@ static inline bool i915_mmio_reg_valid(i915_reg_t reg)
> #define GEN11_GRDOM_MEDIA4 (1 << 8)
> #define GEN11_GRDOM_VECS (1 << 13)
> #define GEN11_GRDOM_VECS2 (1 << 14)
> +#define GEN11_GRDOM_SFC0 (1 << 17)
> +#define GEN11_GRDOM_SFC1 (1 << 18)
> +
> +#define GEN11_VCS_SFC_RESET_BIT(instance) (GEN11_GRDOM_SFC0 << ((instance) >> 1))
> +#define GEN11_VECS_SFC_RESET_BIT(instance) (GEN11_GRDOM_SFC0 << (instance))
> +
> +#define GEN11_VCS_SFC_FORCED_LOCK(engine) _MMIO((engine)->mmio_base + 0x88C)
> +#define GEN11_VCS_SFC_FORCED_LOCK_BIT (1 << 0)
> +#define GEN11_VCS_SFC_LOCK_STATUS(engine) _MMIO((engine)->mmio_base + 0x890)
> +#define GEN11_VCS_SFC_USAGE_BIT (1 << 0)
> +#define GEN11_VCS_SFC_LOCK_ACK_BIT (1 << 1)
> +
> +#define GEN11_VECS_SFC_FORCED_LOCK(engine) _MMIO((engine)->mmio_base + 0x201C)
> +#define GEN11_VECS_SFC_FORCED_LOCK_BIT (1 << 0)
> +#define GEN11_VECS_SFC_LOCK_ACK(engine) _MMIO((engine)->mmio_base + 0x2018)
> +#define GEN11_VECS_SFC_LOCK_ACK_BIT (1 << 0)
> +#define GEN11_VECS_SFC_USAGE(engine) _MMIO((engine)->mmio_base + 0x2014)
> +#define GEN11_VECS_SFC_USAGE_BIT (1 << 0)
>
> #define RING_PP_DIR_BASE(engine) _MMIO((engine)->mmio_base + 0x228)
> #define RING_PP_DIR_BASE_READ(engine) _MMIO((engine)->mmio_base + 0x518)
> diff --git a/drivers/gpu/drm/i915/intel_uncore.c b/drivers/gpu/drm/i915/intel_uncore.c
> index 9289515..481e70e 100644
> --- a/drivers/gpu/drm/i915/intel_uncore.c
> +++ b/drivers/gpu/drm/i915/intel_uncore.c
> @@ -1931,6 +1931,95 @@ static int gen6_reset_engines(struct drm_i915_private *dev_priv,
> return gen6_hw_domain_reset(dev_priv, hw_mask);
> }
>
> +static u32 gen11_lock_sfc(struct drm_i915_private *dev_priv,
> + struct intel_engine_cs *engine)
> +{
> + u8 vdbox_sfc_access = INTEL_INFO(dev_priv)->vdbox_sfc_access;
> + i915_reg_t sfc_forced_lock;
> + u32 sfc_forced_lock_bit;
> + i915_reg_t sfc_forced_lock_ack;
> + u32 sfc_forced_lock_ack_bit;
> + i915_reg_t sfc_usage;
> + u32 sfc_usage_bit;
> + u32 sfc_reset_bit;
> +
You can save many lines here by grouping by type.
-Mika
> + switch (engine->class) {
> + case VIDEO_DECODE_CLASS:
> + if ((BIT(engine->instance) & vdbox_sfc_access) == 0)
> + return 0;
> + sfc_forced_lock = GEN11_VCS_SFC_FORCED_LOCK(engine);
> + sfc_forced_lock_bit = GEN11_VCS_SFC_FORCED_LOCK_BIT;
> + sfc_forced_lock_ack = GEN11_VCS_SFC_LOCK_STATUS(engine);
> + sfc_forced_lock_ack_bit = GEN11_VCS_SFC_LOCK_ACK_BIT;
> + sfc_usage = GEN11_VCS_SFC_LOCK_STATUS(engine);
> + sfc_usage_bit = GEN11_VCS_SFC_USAGE_BIT;
> + sfc_reset_bit = GEN11_VCS_SFC_RESET_BIT(engine->instance);
> + break;
> + case VIDEO_ENHANCEMENT_CLASS:
> + sfc_forced_lock = GEN11_VECS_SFC_FORCED_LOCK(engine);
> + sfc_forced_lock_bit = GEN11_VECS_SFC_FORCED_LOCK_BIT;
> + sfc_forced_lock_ack = GEN11_VECS_SFC_LOCK_ACK(engine);
> + sfc_forced_lock_ack_bit = GEN11_VECS_SFC_LOCK_ACK_BIT;
> + sfc_usage = GEN11_VECS_SFC_USAGE(engine);
> + sfc_usage_bit = GEN11_VECS_SFC_USAGE_BIT;
> + sfc_reset_bit = GEN11_VECS_SFC_RESET_BIT(engine->instance);
> + break;
> + default:
> + return 0;
> + }
> +
> + /*
> + * Tell the engine that a software reset is going to happen. The engine
> + * will then try to force lock the SFC (if currently locked, it will
> + * remain so until we tell the engine it is safe to unlock; if currently
> + * unlocked, it will ignore this and all new lock requests). If SFC
> + * ends up being locked to the engine we want to reset, we have to reset
> + * it as well (we will unlock it once the reset sequence is completed).
> + */
> + I915_WRITE(sfc_forced_lock, I915_READ(sfc_forced_lock) |
> + sfc_forced_lock_bit);
> +
> + if (intel_wait_for_register(dev_priv,
> + sfc_forced_lock_ack,
> + sfc_forced_lock_ack_bit,
> + sfc_forced_lock_ack_bit,
> + 500)) {
> + DRM_DEBUG_DRIVER("Wait for SFC forced lock ack failed\n");
> + return 0;
> + }
> +
> + if ((I915_READ(sfc_usage) & sfc_usage_bit) == sfc_usage_bit)
> + return sfc_reset_bit;
> +
> + return 0;
> +}
> +
> +static void gen11_unlock_sfc(struct drm_i915_private *dev_priv,
> + struct intel_engine_cs *engine)
> +{
> + u8 vdbox_sfc_access = INTEL_INFO(dev_priv)->vdbox_sfc_access;
> + i915_reg_t sfc_forced_lock;
> + u32 sfc_forced_lock_bit;
> +
> + switch (engine->class) {
> + case VIDEO_DECODE_CLASS:
> + if ((BIT(engine->instance) & vdbox_sfc_access) == 0)
> + return;
> + sfc_forced_lock = GEN11_VCS_SFC_FORCED_LOCK(engine);
> + sfc_forced_lock_bit = GEN11_VCS_SFC_FORCED_LOCK_BIT;
> + break;
> + case VIDEO_ENHANCEMENT_CLASS:
> + sfc_forced_lock = GEN11_VECS_SFC_FORCED_LOCK(engine);
> + sfc_forced_lock_bit = GEN11_VECS_SFC_FORCED_LOCK_BIT;
> + break;
> + default:
> + return;
> + }
> +
> + I915_WRITE(sfc_forced_lock, (I915_READ(sfc_forced_lock) &
> + ~sfc_forced_lock_bit));
> +}
> +
> /**
> * gen11_reset_engines - reset individual engines
> * @dev_priv: i915 device
> @@ -1959,20 +2048,28 @@ static int gen11_reset_engines(struct drm_i915_private *dev_priv,
> [VECS2] = GEN11_GRDOM_VECS2,
> };
> u32 hw_mask;
> + unsigned int tmp;
> + int ret;
>
> BUILD_BUG_ON(VECS2 + 1 != I915_NUM_ENGINES);
>
> if (engine_mask == ALL_ENGINES) {
> hw_mask = GEN11_GRDOM_FULL;
> } else {
> - unsigned int tmp;
> -
> hw_mask = 0;
> - for_each_engine_masked(engine, dev_priv, engine_mask, tmp)
> + for_each_engine_masked(engine, dev_priv, engine_mask, tmp) {
> hw_mask |= hw_engine_mask[engine->id];
> + hw_mask |= gen11_lock_sfc(dev_priv, engine);
> + }
> }
>
> - return gen6_hw_domain_reset(dev_priv, hw_mask);
> + ret = gen6_hw_domain_reset(dev_priv, hw_mask);
> +
> + if (engine_mask != ALL_ENGINES)
> + for_each_engine_masked(engine, dev_priv, engine_mask, tmp)
> + gen11_unlock_sfc(dev_priv, engine);
> +
> + return ret;
> }
>
> /**
> --
> 2.7.4
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2018-11-01 10:23 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-31 14:24 [PATCH v1 1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines Tomasz Lis
2018-10-31 14:24 ` [PATCH v1 2/2] drm/i915/icl: Record the valid VDBoxes with SFC capability Tomasz Lis
2018-11-01 10:21 ` Mika Kuoppala
2018-10-31 14:25 ` [PATCH v1 1/2] drm/i915/icl: Mind the SFC units when resetting VD or VEBox engines Chris Wilson
2018-10-31 14:27 ` Chris Wilson
2018-10-31 14:39 ` ✗ Fi.CI.SPARSE: warning for series starting with [v1,1/2] " Patchwork
2018-10-31 14:55 ` ✓ Fi.CI.BAT: success " Patchwork
2018-10-31 19:57 ` ✓ Fi.CI.IGT: " Patchwork
2018-11-01 10:22 ` [PATCH v1 1/2] " Mika Kuoppala
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.