[Intel-xe] [PATCH 5/7] drm/xe/display: Move device info initialization to display

Lucas De Marchi lucas.demarchi at intel.com
Thu Mar 2 15:23:04 UTC 2023


On Thu, Mar 02, 2023 at 04:44:01PM +0200, Jani Nikula wrote:
>On Thu, 02 Mar 2023, Jani Nikula <jani.nikula at linux.intel.com> wrote:
>> On Wed, 01 Mar 2023, Lucas De Marchi <lucas.demarchi at intel.com> wrote:
>>> Instead of initializing the display info together with the platform in
>>> xe_pci.c, let the display part initialize it. The small disadvantage is
>>> that the description struct is not automatically mapped from the PCI ID,
>>> but just doing a switch on the platform, that should already be set
>>> during display initialization should be ok.
>>
>> Have we already given up on the idea that device info would be a pointer
>> to rodata?
>>
>> The thing that was always problematic for i915 was that it was all too
>> convenient to go fiddle with the device info runtime, based on some
>> arbitrary needs.
>>
>> ---
>>
>> That said, there's really no requirement that the struct pci_device_id
>> driver_data members in MODULE_DEVICE_TABLE() need to be pointers to some
>> device info structures, at all. The initialization of device info could
>> be done in completely different ways if we dropped that notion. The
>> current macro "inheritance" in both i915 and xe is absolutely horrible.
>>
>> Anyway, going to block the patch, just checking on the direction here.
>
>Sheesh, *NOT* going to. Sorry.

oh, ok. Thanks

Lucas De Marchi


More information about the Intel-xe mailing list