diff mbox series

[1/3] drm/i915: Remove early/pre-production Haswell code

Message ID 20231006083103.660153-2-tvrtko.ursulin@linux.intel.com (mailing list archive)
State New, archived
Headers show
Series Trim some pre-production code | expand

Commit Message

Tvrtko Ursulin Oct. 6, 2023, 8:31 a.m. UTC
From: Tvrtko Ursulin <tvrtko.ursulin@intel.com>

It is not our policy to keep pre-production hardware support for this long
so I guess this one was just forgotten.

Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
---
 drivers/gpu/drm/i915/i915_driver.c | 1 -
 drivers/gpu/drm/i915/i915_drv.h    | 2 --
 2 files changed, 3 deletions(-)

Comments

Andi Shyti Oct. 6, 2023, 10:39 a.m. UTC | #1
Hi Tvrtko,

On Fri, Oct 06, 2023 at 09:31:01AM +0100, Tvrtko Ursulin wrote:
> From: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> 
> It is not our policy to keep pre-production hardware support for this long
> so I guess this one was just forgotten.
> 
> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>

Reviewed-by: Andi Shyti <andi.shyti@linux.intel.com> 

Andi
Ville Syrjälä Oct. 6, 2023, 10:46 a.m. UTC | #2
On Fri, Oct 06, 2023 at 09:31:01AM +0100, Tvrtko Ursulin wrote:
> From: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> 
> It is not our policy to keep pre-production hardware support for this long
> so I guess this one was just forgotten.

This is about detecting pre-prod hw, not supporting it. I think keeping
the detection forever is a good idea since otherwise we may end up
mistakenly debugging pre-prod hw without even realizing it.

> 
> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> ---
>  drivers/gpu/drm/i915/i915_driver.c | 1 -
>  drivers/gpu/drm/i915/i915_drv.h    | 2 --
>  2 files changed, 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/i915_driver.c b/drivers/gpu/drm/i915/i915_driver.c
> index ccbb2834cde0..78a42c8a8509 100644
> --- a/drivers/gpu/drm/i915/i915_driver.c
> +++ b/drivers/gpu/drm/i915/i915_driver.c
> @@ -175,7 +175,6 @@ static void intel_detect_preproduction_hw(struct drm_i915_private *dev_priv)
>  {
>  	bool pre = false;
>  
> -	pre |= IS_HASWELL_EARLY_SDV(dev_priv);
>  	pre |= IS_SKYLAKE(dev_priv) && INTEL_REVID(dev_priv) < 0x6;
>  	pre |= IS_BROXTON(dev_priv) && INTEL_REVID(dev_priv) < 0xA;
>  	pre |= IS_KABYLAKE(dev_priv) && INTEL_REVID(dev_priv) < 0x1;
> diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
> index cb60fc9cf873..9d493ff1685a 100644
> --- a/drivers/gpu/drm/i915/i915_drv.h
> +++ b/drivers/gpu/drm/i915/i915_drv.h
> @@ -590,8 +590,6 @@ IS_SUBPLATFORM(const struct drm_i915_private *i915,
>  	IS_SUBPLATFORM(i915, INTEL_ALDERLAKE_P, INTEL_SUBPLATFORM_RPL)
>  #define IS_RAPTORLAKE_U(i915) \
>  	IS_SUBPLATFORM(i915, INTEL_ALDERLAKE_P, INTEL_SUBPLATFORM_RPLU)
> -#define IS_HASWELL_EARLY_SDV(i915) (IS_HASWELL(i915) && \
> -				    (INTEL_DEVID(i915) & 0xFF00) == 0x0C00)
>  #define IS_BROADWELL_ULT(i915) \
>  	IS_SUBPLATFORM(i915, INTEL_BROADWELL, INTEL_SUBPLATFORM_ULT)
>  #define IS_BROADWELL_ULX(i915) \
> -- 
> 2.39.2
Tvrtko Ursulin Oct. 6, 2023, 11:12 a.m. UTC | #3
On 06/10/2023 11:46, Ville Syrjälä wrote:
> On Fri, Oct 06, 2023 at 09:31:01AM +0100, Tvrtko Ursulin wrote:
>> From: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
>>
>> It is not our policy to keep pre-production hardware support for this long
>> so I guess this one was just forgotten.
> 
> This is about detecting pre-prod hw, not supporting it. I think keeping
> the detection forever is a good idea since otherwise we may end up
> mistakenly debugging pre-prod hw without even realizing it.

Hmm it was before my time, but surely HSW SDVs never left the company 
and you don't expect any internal systems to be using them after what 
10+ years?

Regards,

Tvrtko

>>
>> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
>> ---
>>   drivers/gpu/drm/i915/i915_driver.c | 1 -
>>   drivers/gpu/drm/i915/i915_drv.h    | 2 --
>>   2 files changed, 3 deletions(-)
>>
>> diff --git a/drivers/gpu/drm/i915/i915_driver.c b/drivers/gpu/drm/i915/i915_driver.c
>> index ccbb2834cde0..78a42c8a8509 100644
>> --- a/drivers/gpu/drm/i915/i915_driver.c
>> +++ b/drivers/gpu/drm/i915/i915_driver.c
>> @@ -175,7 +175,6 @@ static void intel_detect_preproduction_hw(struct drm_i915_private *dev_priv)
>>   {
>>   	bool pre = false;
>>   
>> -	pre |= IS_HASWELL_EARLY_SDV(dev_priv);
>>   	pre |= IS_SKYLAKE(dev_priv) && INTEL_REVID(dev_priv) < 0x6;
>>   	pre |= IS_BROXTON(dev_priv) && INTEL_REVID(dev_priv) < 0xA;
>>   	pre |= IS_KABYLAKE(dev_priv) && INTEL_REVID(dev_priv) < 0x1;
>> diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
>> index cb60fc9cf873..9d493ff1685a 100644
>> --- a/drivers/gpu/drm/i915/i915_drv.h
>> +++ b/drivers/gpu/drm/i915/i915_drv.h
>> @@ -590,8 +590,6 @@ IS_SUBPLATFORM(const struct drm_i915_private *i915,
>>   	IS_SUBPLATFORM(i915, INTEL_ALDERLAKE_P, INTEL_SUBPLATFORM_RPL)
>>   #define IS_RAPTORLAKE_U(i915) \
>>   	IS_SUBPLATFORM(i915, INTEL_ALDERLAKE_P, INTEL_SUBPLATFORM_RPLU)
>> -#define IS_HASWELL_EARLY_SDV(i915) (IS_HASWELL(i915) && \
>> -				    (INTEL_DEVID(i915) & 0xFF00) == 0x0C00)
>>   #define IS_BROADWELL_ULT(i915) \
>>   	IS_SUBPLATFORM(i915, INTEL_BROADWELL, INTEL_SUBPLATFORM_ULT)
>>   #define IS_BROADWELL_ULX(i915) \
>> -- 
>> 2.39.2
>
Zanoni, Paulo R Oct. 6, 2023, 3:44 p.m. UTC | #4
On Fri, 2023-10-06 at 09:31 +0100, Tvrtko Ursulin wrote:
> From: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> 
> It is not our policy to keep pre-production hardware support for this long
> so I guess this one was just forgotten.

Wouldn't it make sense to also remove the PCI IDs if they never made it
to the real production world*? Couldn't these IDs end up getting reused
for something else (maybe not even graphics) at some point in the
future?

*: I can't confirm this is the case.

> 
> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> ---
>  drivers/gpu/drm/i915/i915_driver.c | 1 -
>  drivers/gpu/drm/i915/i915_drv.h    | 2 --
>  2 files changed, 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/i915_driver.c b/drivers/gpu/drm/i915/i915_driver.c
> index ccbb2834cde0..78a42c8a8509 100644
> --- a/drivers/gpu/drm/i915/i915_driver.c
> +++ b/drivers/gpu/drm/i915/i915_driver.c
> @@ -175,7 +175,6 @@ static void intel_detect_preproduction_hw(struct drm_i915_private *dev_priv)
>  {
>  	bool pre = false;
>  
> -	pre |= IS_HASWELL_EARLY_SDV(dev_priv);
>  	pre |= IS_SKYLAKE(dev_priv) && INTEL_REVID(dev_priv) < 0x6;
>  	pre |= IS_BROXTON(dev_priv) && INTEL_REVID(dev_priv) < 0xA;
>  	pre |= IS_KABYLAKE(dev_priv) && INTEL_REVID(dev_priv) < 0x1;
> diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
> index cb60fc9cf873..9d493ff1685a 100644
> --- a/drivers/gpu/drm/i915/i915_drv.h
> +++ b/drivers/gpu/drm/i915/i915_drv.h
> @@ -590,8 +590,6 @@ IS_SUBPLATFORM(const struct drm_i915_private *i915,
>  	IS_SUBPLATFORM(i915, INTEL_ALDERLAKE_P, INTEL_SUBPLATFORM_RPL)
>  #define IS_RAPTORLAKE_U(i915) \
>  	IS_SUBPLATFORM(i915, INTEL_ALDERLAKE_P, INTEL_SUBPLATFORM_RPLU)
> -#define IS_HASWELL_EARLY_SDV(i915) (IS_HASWELL(i915) && \
> -				    (INTEL_DEVID(i915) & 0xFF00) == 0x0C00)
>  #define IS_BROADWELL_ULT(i915) \
>  	IS_SUBPLATFORM(i915, INTEL_BROADWELL, INTEL_SUBPLATFORM_ULT)
>  #define IS_BROADWELL_ULX(i915) \
Andrzej Hajda Oct. 6, 2023, 7:49 p.m. UTC | #5
On 06.10.2023 10:31, Tvrtko Ursulin wrote:
> From: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> 
> It is not our policy to keep pre-production hardware support for this long
> so I guess this one was just forgotten.
> 
> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>

Reviewed-by: Andrzej Hajda <andrzej.hajda@intel.com>

Regards
Andrzej

> ---
>   drivers/gpu/drm/i915/i915_driver.c | 1 -
>   drivers/gpu/drm/i915/i915_drv.h    | 2 --
>   2 files changed, 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/i915_driver.c b/drivers/gpu/drm/i915/i915_driver.c
> index ccbb2834cde0..78a42c8a8509 100644
> --- a/drivers/gpu/drm/i915/i915_driver.c
> +++ b/drivers/gpu/drm/i915/i915_driver.c
> @@ -175,7 +175,6 @@ static void intel_detect_preproduction_hw(struct drm_i915_private *dev_priv)
>   {
>   	bool pre = false;
>   
> -	pre |= IS_HASWELL_EARLY_SDV(dev_priv);
>   	pre |= IS_SKYLAKE(dev_priv) && INTEL_REVID(dev_priv) < 0x6;
>   	pre |= IS_BROXTON(dev_priv) && INTEL_REVID(dev_priv) < 0xA;
>   	pre |= IS_KABYLAKE(dev_priv) && INTEL_REVID(dev_priv) < 0x1;
> diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
> index cb60fc9cf873..9d493ff1685a 100644
> --- a/drivers/gpu/drm/i915/i915_drv.h
> +++ b/drivers/gpu/drm/i915/i915_drv.h
> @@ -590,8 +590,6 @@ IS_SUBPLATFORM(const struct drm_i915_private *i915,
>   	IS_SUBPLATFORM(i915, INTEL_ALDERLAKE_P, INTEL_SUBPLATFORM_RPL)
>   #define IS_RAPTORLAKE_U(i915) \
>   	IS_SUBPLATFORM(i915, INTEL_ALDERLAKE_P, INTEL_SUBPLATFORM_RPLU)
> -#define IS_HASWELL_EARLY_SDV(i915) (IS_HASWELL(i915) && \
> -				    (INTEL_DEVID(i915) & 0xFF00) == 0x0C00)
>   #define IS_BROADWELL_ULT(i915) \
>   	IS_SUBPLATFORM(i915, INTEL_BROADWELL, INTEL_SUBPLATFORM_ULT)
>   #define IS_BROADWELL_ULX(i915) \
diff mbox series

Patch

diff --git a/drivers/gpu/drm/i915/i915_driver.c b/drivers/gpu/drm/i915/i915_driver.c
index ccbb2834cde0..78a42c8a8509 100644
--- a/drivers/gpu/drm/i915/i915_driver.c
+++ b/drivers/gpu/drm/i915/i915_driver.c
@@ -175,7 +175,6 @@  static void intel_detect_preproduction_hw(struct drm_i915_private *dev_priv)
 {
 	bool pre = false;
 
-	pre |= IS_HASWELL_EARLY_SDV(dev_priv);
 	pre |= IS_SKYLAKE(dev_priv) && INTEL_REVID(dev_priv) < 0x6;
 	pre |= IS_BROXTON(dev_priv) && INTEL_REVID(dev_priv) < 0xA;
 	pre |= IS_KABYLAKE(dev_priv) && INTEL_REVID(dev_priv) < 0x1;
diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
index cb60fc9cf873..9d493ff1685a 100644
--- a/drivers/gpu/drm/i915/i915_drv.h
+++ b/drivers/gpu/drm/i915/i915_drv.h
@@ -590,8 +590,6 @@  IS_SUBPLATFORM(const struct drm_i915_private *i915,
 	IS_SUBPLATFORM(i915, INTEL_ALDERLAKE_P, INTEL_SUBPLATFORM_RPL)
 #define IS_RAPTORLAKE_U(i915) \
 	IS_SUBPLATFORM(i915, INTEL_ALDERLAKE_P, INTEL_SUBPLATFORM_RPLU)
-#define IS_HASWELL_EARLY_SDV(i915) (IS_HASWELL(i915) && \
-				    (INTEL_DEVID(i915) & 0xFF00) == 0x0C00)
 #define IS_BROADWELL_ULT(i915) \
 	IS_SUBPLATFORM(i915, INTEL_BROADWELL, INTEL_SUBPLATFORM_ULT)
 #define IS_BROADWELL_ULX(i915) \