Re: [PATCH v2 4/4] drm/panic: Add a qr_code panic screen

From: Miguel Ojeda
Date: Wed Jul 10 2024 - 05:01:54 EST


On Tue, Jul 9, 2024 at 5:10 PM Jocelyn Falempe <jfalempe@xxxxxxxxxx> wrote:
>
> I used to list all QR versions in an enum, but I find it a bit too much
> boilerplate to ensure the version is between 1 and 40.
> By transparent newtypes, you mean adding "#[repr(transparent)]" to a
> struct ?
> I don't plan to add more "version" usage, so probably not worth it.

Yeah, that is what I meant. It may not be worth it in that case -- it
is just something we should generally consider when we see "raw" types
appear in parameters that need extra documentation/preconditions, but
sometimes it simply does not make sense.

Thanks!

Cheers,
Miguel