[PATCH] drm/v3d: Fix perfmon build error/warning

Maxime Ripard mripard at redhat.com
Wed Jun 5 08:41:37 UTC 2024


Hi,

On Wed, Jun 05, 2024 at 08:19:34AM GMT, Iago Toral wrote:
> Thanks for looking at ixing this Tvrtko.
> 
> El mar, 04-06-2024 a las 17:02 +0100, Tvrtko Ursulin escribió:
> > From: Tvrtko Ursulin <tvrtko.ursulin at igalia.com>
> > 
> > Move static const array into the source file to fix the "defined but
> > not
> > used" errors.
> > 
> > The fix is perhaps not the prettiest due hand crafting the array
> > sizes
> > in v3d_performance_counters.h, but I did add some build time asserts
> > to
> > validate the counts look sensible, so hopefully it is good enough for
> > a
> > quick fix.
> > 
> 
> If we need this to go in ASAP I am fine with this patch as-is, so:
> 
> Reviewed-by: Iago Toral Quiroga <itoral at igalia.com>
> 
> With that said, if we are still in time for a bit of iteration may I
> suggest that instead of hard-coding the counters we instead add helper
> functions in drivers/gpu/drm/v3d/v3d_perfmon.c that call ARRAY_SIZE on
> the corresponding array based on v3d->ver? It is fine if we prefer to
> merge this as-is and do this change later as a follow-up patch.

This is blocking the merge from drm-misc-next into drm/next at the
moment, so I'm going to merge this patch as is so I can send the PR
tomorrow.

Your comment looks fine to me too, so feel free to send a follow-up
patch to refine what's done here :)

Thanks!
Maxime
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 273 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/dri-devel/attachments/20240605/5321c5f3/attachment.sig>


More information about the dri-devel mailing list