[PATCH 4/5] drm/xe: Rename internal vram helper function

Jani Nikula jani.nikula at linux.intel.com
Wed May 29 18:01:57 UTC 2024


On Wed, 29 May 2024, Lucas De Marchi <lucas.demarchi at intel.com> wrote:
> I very much prefer dropping the prefix for static functions.  If there's
> a clash with a global one, either a) you're including too much b) you
> should use a better name or c) the global one could use a better
> name....

I think all of the a), b), and c) evaluate to true. ;D

But sadly a) and c) are often out of your control, a) due to recursively
transitive includes that end up including the world, and c) simply
because you can't fix the world.

Case in point, commit 35b22649eb41 ("drm/xe: Fix END redefinition").

But then you just fix it, and move on.

> IMO platform prefixes and double underscores that i915 uses are also
> bad:  a compilation unit should abstract it with proper layer of
> separation, otherwise it made a bad abstraction.

No argument there. It's just a lot of legacy.


BR,
Jani.


-- 
Jani Nikula, Intel


More information about the Intel-xe mailing list