Re: [PATCH 2/7] drm/i915: move I915_IDLE_ENGINES_TIMEOUT next to its only user

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 20 Jan 2023, Rodrigo Vivi <rodrigo.vivi@xxxxxxxxx> wrote:
> On Wed, Jan 18, 2023 at 03:15:33PM +0200, Jani Nikula wrote:
>> Declutter i915_drv.h. If there's ever a need to use this in more than
>> one place, we can figure out a better spot then. For now, this seems
>> easiest.
>
> why don't we get rid of the single use macro instead?

I thought it had self-documenting value as-is.

In any case, I merged this already, so follow-ups welcome. ;)

BR,
Jani.


>
>> 
>> Signed-off-by: Jani Nikula <jani.nikula@xxxxxxxxx>
>> ---
>>  drivers/gpu/drm/i915/i915_debugfs.c | 3 +++
>>  drivers/gpu/drm/i915/i915_drv.h     | 2 --
>>  2 files changed, 3 insertions(+), 2 deletions(-)
>> 
>> diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c
>> index a356ca490159..51ba9a8369c5 100644
>> --- a/drivers/gpu/drm/i915/i915_debugfs.c
>> +++ b/drivers/gpu/drm/i915/i915_debugfs.c
>> @@ -648,6 +648,9 @@ i915_drop_caches_get(void *data, u64 *val)
>>  
>>  	return 0;
>>  }
>> +
>> +#define I915_IDLE_ENGINES_TIMEOUT (200) /* in ms */
>> +
>>  static int
>>  gt_drop_caches(struct intel_gt *gt, u64 val)
>>  {
>> diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
>> index 8377173e8de5..343e3e568774 100644
>> --- a/drivers/gpu/drm/i915/i915_drv.h
>> +++ b/drivers/gpu/drm/i915/i915_drv.h
>> @@ -194,8 +194,6 @@ struct i915_gem_mm {
>>  	u32 shrink_count;
>>  };
>>  
>> -#define I915_IDLE_ENGINES_TIMEOUT (200) /* in ms */
>> -
>>  #define HAS_HW_SAGV_WM(i915) (DISPLAY_VER(i915) >= 13 && !IS_DGFX(i915))
>>  
>>  struct i915_virtual_gpu {
>> -- 
>> 2.34.1
>> 

-- 
Jani Nikula, Intel Open Source Graphics Center



[Index of Archives]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux