Re: [PATCH] pwm: mc33xs2410: Initialize spi_device_id arrays using member names
Uwe Kleine-König <[email protected]>
| Newsgroups | org.kernel.vger.linux-pwm,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <akgndtvHVIBJ1549@monoceros> |
On Fri, Jun 19, 2026 at 06:14:10PM +0200, Uwe Kleine-König (The Capable Hub) wrote: > While being less compact, using named initializers allows to more easily > see which members of the structs are assigned which value without having > to lookup the declaration of the struct. And it's also more robust > against changes to the struct definition. > > The mentioned robustness is relevant for a planned change to struct > spi_device_id that replaces .driver_data by an anonymous union. > > This patch doesn't modify the compiled array, only its representation > in source form benefits. > > Signed-off-by: Uwe Kleine-König (The Capable Hub) <[email protected]> Applied to https://git.kernel.org/pub/scm/linux/kernel/git/ukleinek/linux.git pwm/for-next Best regards Uwe
signature.asc
(application/pgp-signature, 488 B)
-----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEP4GsaTp6HlmJrf7Tj4D7WH0S/k4FAmpIJ8IACgkQj4D7WH0S /k6c6Qf8CiX7Jd7IWInoHGLm8GD2JOerntfYVyoc3HGMd5J8Qrm3+1i8BVuN/0iL 9AxPxQcHODrr3EZDlG1w8qqD7n8tAeqNU6CT5ig2Xn6Xzt4KOMD0gePFLg0KQ4l8 n6xIbFddIb72iqtx5dX2EdlY/S0us59azVDDUd5bY8xvAsGwNuE4jtgWLLkNjv/R hWwWiI5ARluQDMarsye8agxlfpFdVXlRBYzmr4XQKVa5ZoZOZFUdUn3rjJFSQyTq +QxXfY+dEmkQ+kewYckPLS9jr+MXO7irOVnjETmotq3mcA2GpGxlcGRw5vCTA/Jn LJRIn/MpWFppRdwEM2rR9CpQPFwTLw== =O/DY -----END PGP SIGNATURE-----