[Intel-gfx] [PATCH] drm/i915: remove unused i915->active_pipes

Jani Nikula jani.nikula at intel.com
Mon Aug 30 10:07:31 UTC 2021


On Fri, 27 Aug 2021, Ville Syrjälä <ville.syrjala at linux.intel.com> wrote:
> On Thu, Aug 26, 2021 at 05:18:30PM +0300, Jani Nikula wrote:
>> Apparently the last reader of i915->active_pipes was removed with commit
>> ef79d62b5ce5 ("drm/i915: Encapsulate dbuf state handling harder"), and
>> now it's only ever written to. Remove it completely.
>> 
>> Cc: Stanislav Lisovskiy <stanislav.lisovskiy at intel.com>
>> Cc: Ville Syrjälä <ville.syrjala at linux.intel.com>
>> Signed-off-by: Jani Nikula <jani.nikula at intel.com>
>
> Reviewed-by: Ville Syrjälä <ville.syrjala at linux.intel.com>

Thanks, pushed.

BR,
Jani.


>
>> ---
>>  drivers/gpu/drm/i915/display/intel_display.c | 4 +---
>>  drivers/gpu/drm/i915/i915_drv.h              | 6 ------
>>  2 files changed, 1 insertion(+), 9 deletions(-)
>> 
>> diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_display.c
>> index fe5ad599c218..a692971b0209 100644
>> --- a/drivers/gpu/drm/i915/display/intel_display.c
>> +++ b/drivers/gpu/drm/i915/display/intel_display.c
>> @@ -3781,7 +3781,6 @@ static void intel_crtc_disable_noatomic(struct intel_crtc *crtc,
>>  
>>  	intel_display_power_put_all_in_set(dev_priv, &crtc->enabled_power_domains);
>>  
>> -	dev_priv->active_pipes &= ~BIT(pipe);
>>  	cdclk_state->min_cdclk[pipe] = 0;
>>  	cdclk_state->min_voltage_level[pipe] = 0;
>>  	cdclk_state->active_pipes &= ~BIT(pipe);
>> @@ -12351,8 +12350,7 @@ static void intel_modeset_readout_hw_state(struct drm_device *dev)
>>  			    enableddisabled(crtc_state->hw.active));
>>  	}
>>  
>> -	dev_priv->active_pipes = cdclk_state->active_pipes =
>> -		dbuf_state->active_pipes = active_pipes;
>> +	cdclk_state->active_pipes = dbuf_state->active_pipes = active_pipes;
>>  
>>  	readout_plane_state(dev_priv);
>>  
>> diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
>> index f64ba566fe8c..033031169d74 100644
>> --- a/drivers/gpu/drm/i915/i915_drv.h
>> +++ b/drivers/gpu/drm/i915/i915_drv.h
>> @@ -1015,12 +1015,6 @@ struct drm_i915_private {
>>  
>>  	struct list_head global_obj_list;
>>  
>> -	/*
>> -	 * For reading active_pipes holding any crtc lock is
>> -	 * sufficient, for writing must hold all of them.
>> -	 */
>> -	u8 active_pipes;
>> -
>>  	struct i915_wa_list gt_wa_list;
>>  
>>  	struct i915_frontbuffer_tracking fb_tracking;
>> -- 
>> 2.20.1

-- 
Jani Nikula, Intel Open Source Graphics Center


More information about the Intel-gfx mailing list