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

Lucas De Marchi lucas.demarchi at intel.com
Wed May 29 20:03:04 UTC 2024


On Wed, May 29, 2024 at 09:01:57PM GMT, Jani Nikula wrote:
>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.

yes, and that is perfectly fine. That particular fix happened mostly
because we were out of tree and not trying to build to all possible
arches. Now that we are, we noticed the issue, fixed it and
moved on.

Lucas De Marchi

>
>> 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