[PATCH v2 09/10] drm/ofdrm: Add per-model device function
Thomas Zimmermann
tzimmermann at suse.de
Wed Jul 27 18:33:27 AEST 2022
Hi
Am 26.07.22 um 21:22 schrieb Javier Martinez Canillas:
> Hello Michal,
>
> On 7/26/22 16:40, Michal Suchánek wrote:
>> Hello,
>>
>> On Tue, Jul 26, 2022 at 03:38:37PM +0200, Javier Martinez Canillas wrote:
>>> On 7/20/22 16:27, Thomas Zimmermann wrote:
>>>> Add a per-model device-function structure in preparation of adding
>>>> color-management support. Detection of the individual models has been
>>>> taken from fbdev's offb.
>>>>
>>>> Signed-off-by: Thomas Zimmermann <tzimmermann at suse.de>
>>>> ---
>>>
>>> Reviewed-by: Javier Martinez Canillas <javierm at redhat.com>
>>>
>>> [...]
>>>
>>>> +static bool is_avivo(__be32 vendor, __be32 device)
>>>> +{
>>>> + /* This will match most R5xx */
>>>> + return (vendor == 0x1002) &&
>>>> + ((device >= 0x7100 && device < 0x7800) || (device >= 0x9400));
>>>> +}
>>>
>>> Maybe add some constant macros to not have these magic numbers ?
>>
>> This is based on the existing fbdev implementation's magic numbers:
>>
>> drivers/video/fbdev/offb.c: ((*did >= 0x7100 && *did < 0x7800) ||
>>
>
> Ah, I see. Then we might have to go with the magic numbers...
>
>> Of course, it would be great if somebody knowledgeable could clarify
>> those.
Those are PCI ids. If I find them already defined, I'll use the macros
instead.
Best regards
Thomas
>>
>
> Indeed.
>
--
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Maxfeldstr. 5, 90409 Nürnberg, Germany
(HRB 36809, AG Nürnberg)
Geschäftsführer: Ivo Totev
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature
Type: application/pgp-signature
Size: 840 bytes
Desc: OpenPGP digital signature
URL: <http://lists.ozlabs.org/pipermail/linuxppc-dev/attachments/20220727/31395ea1/attachment.sig>
More information about the Linuxppc-dev
mailing list