Re: [PATCH 2/5] drm/i915: replace IS_GEN<N> with IS_GEN(..., N)

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

 



On Thu, Nov 01, 2018 at 11:35:10AM +0000, Tvrtko Ursulin wrote:
> 
> On 01/11/2018 08:35, Lucas De Marchi wrote:
> > Now that IS_GEN can accept 1 or 2 parameters, replace the use
> > of IS_GEN<N> by passing N as argument. This was generated with:
> 
> [snip]
> 
> > diff --git a/drivers/gpu/drm/i915/gvt/vgpu.c b/drivers/gpu/drm/i915/gvt/vgpu.c
> > index c628be05fbfe..e1c860f80eb0 100644
> > --- a/drivers/gpu/drm/i915/gvt/vgpu.c
> > +++ b/drivers/gpu/drm/i915/gvt/vgpu.c
> > @@ -148,10 +148,10 @@ int intel_gvt_init_vgpu_types(struct intel_gvt *gvt)
> >   		gvt->types[i].avail_instance = min(low_avail / vgpu_types[i].low_mm,
> >   						   high_avail / vgpu_types[i].high_mm);
> > -		if (IS_GEN8(gvt->dev_priv))
> > +		if (IS_GEN(gvt->dev_priv, 8))
> 
> No strong feelings either way. Old way seems a bit more readable, but
> perhaps it is only familiarity.
> 
> How are the churn/conflict considerations given the huge (more than normal I
> think) number of current unmerged features?

That's why I thought it was important to give a working spatch together with the
patch, So it can be applied on the the in-flight changes. If we aren't converting
the current usages then I think there's little value in the change since it would
just add another way of doing the same thing.

Lucas De Marchi

> 
> Regards,
> 
> Tvrtko
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




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

  Powered by Linux