Re: [PATCH v4 4/6] drm/ssd130x: Replace positional ssd130x_spi_id[] initialization with C99

From: Andy Shevchenko

Date: Tue Aug 18 2026 - 04:41:18 EST


On Tue, Aug 18, 2026 at 11:06:24AM +0300, Amit Barzilai wrote:
> ssd130x_spi_id[] is initialized with positional initializers, which
> easily create easy-to-miss bugs when changing the members of the target
> struct (struct spi_device_id in this example).
>
> Change this to C99 initializers to guarantee each member is initialized
> with the correct value.

Reviewed-by: Andy Shevchenko <andriy.shevchenko@xxxxxxxxx>

...

> static const struct spi_device_id ssd130x_spi_id[] = {
> /* ssd130x family */
> + { .name = "sh1106", .driver_data = SH1106_ID },

Hmm... Is the comment correct for sh1106?

> /* ssd132x family */
> /* ssd133x family */

Overall, what do these comment bring us? Are those families have something in
common? Because the driver data is unique for each device, so I assume it's not
that compatible inside even the same families.

TL;DR: Perhaps simply drop those comments for once?

--
With Best Regards,
Andy Shevchenko