On Fri, 10 May 2024, Thomas Zimmermann <[email protected]> wrote:
> Am 10.05.24 um 14:17 schrieb Jani Nikula:
>>> +   /*
>>> +    * The adapter sends all-zeros if no monitor has been
>>> +    * connected. We consider anything else a connection.
>>> +    */
>>> +   return memcmp(no_edid, hdr, 8) != 0;
>> Nitpick, this works, but you can drop the no_edid buf by using:
>>
>>      return memchr_inv(hdr, 0, sizeof(hdr));
>
> Makes sense to me. Thanks for reviewing.

Btw I wrote [1] because !memchr_inv() is a bit obscure.

BR,
Jani.


[1] https://lore.kernel.org/r/[email protected]


-- 
Jani Nikula, Intel

Reply via email to