[PATCH v4] drm/i915: split out display register macros to a separate file
Jani Nikula
jani.nikula at intel.com
Mon Jun 9 10:26:55 UTC 2025
On Fri, 06 Jun 2025, Lucas De Marchi <lucas.demarchi at intel.com> wrote:
> On Fri, Jun 06, 2025 at 01:22:56PM +0300, Jani Nikula wrote:
>>This is a scripted split of the display related register macros from
>>i915_reg.h to display/intel_display_regs.h. As a starting point, move
>>all the macros that are only used in display code (or GVT). If there are
>>users in core i915 code or soc/, or no users anywhere, keep the macros
>>in i915_reg.h. This is done in groups of macros separated by blank
>>lines, moving the comments along with the groups.
>>
>>Some manually picked macro groups are kept/moved regardless of the
>>heuristics above.
>>
>>This is obviously a very crude approach. It's not perfect. But there are
>>4.2k lines in i915_reg.h, and its refactoring has ground to a halt. This
>>is the big hammer that splits the file to two, and enables further
>>cleanup.
>>
>>Cc: Suraj Kandpal <suraj.kandpal at intel.com>
>>Cc: Ville Syrjälä <ville.syrjala at linux.intel.com>
>>Cc: Lucas De Marchi <lucas.demarchi at intel.com>
>>Signed-off-by: Jani Nikula <jani.nikula at intel.com>
>
> I skimmed over the registers and didn't spot non-display related ones.
> For the code move, there are a few unrelated changes due to sorting the
> includes, but that should be fine as it's easier to just sort the block.
>
> Changes in drivers/gpu/drm/i915/display/intel_display_regs.h indeed come
> verbatim from the other file, as colored by git show --color-moved.
>
> Reviewed-by: Lucas De Marchi <lucas.demarchi at intel.com>
>
> Let's get this in before it conflicts again.
Thanks for the review. It's not perfect, but I think it's good enough to
make forward progress. Pushed to din.
BR,
Jani.
--
Jani Nikula, Intel
More information about the Intel-xe
mailing list