Re: [PATCH 1/2] drm/i915: Prepare for multiple GTs

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

 



Hi Dale,

thanks for looking into this patch,

> > +	/*
> > +	 * i915->gt[0] == &i915->gt0
> > +	 */
> > +#define I915_MAX_GT 4
> > +	struct intel_gt *gt[I915_MAX_GT];
> > +
> 
> 
> It would be nice if I915_MAX_GT was defined in a more basic header file so
> that the definition of I915_MAX_GT would be available without the necessity of
> including this heavier file i915_drv.h.  Maybe gt/intel_gt.h would be a good
> place, as that is where macro for_each_gt (a user of I915_MAX_GT) is defined.

I actually see I915_MAX_GT more suited for in drv.h as it is a
description for i915 rather than the GT singularly.

We should see the GT as a standalone elemnt not aware of the
overall properties of the entire GPU.

While for_each_gt() is more an utility from intel_gt.

Personally, I do not even like this define: I think the number
of the GTs should be read during startup and stored in
drm_i915_private or similar, but this is another discussion.

Thank you,
Andi



[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux