]> git.ipfire.org Git - thirdparty/linux.git/commit
staging: iio: Use named initializers for struct i2c_device_id
authorUwe Kleine-König (The Capable Hub) <u.kleine-koenig@baylibre.com>
Tue, 19 May 2026 14:06:20 +0000 (16:06 +0200)
committerJonathan Cameron <jic23@kernel.org>
Sun, 31 May 2026 10:01:46 +0000 (11:01 +0100)
commitc4657858d43ada628e2f4eaf591c43efb3649933
treea37eefa669f1e6cda4e6a3e9c7c6d64f555f35ab
parentab233e4f9a9578faa30c1870f5436591d86c37b7
staging: iio: Use named initializers for struct i2c_device_id

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.

This patch doesn't modify the compiled arrays, only their representation
in source form benefits. The former was confirmed with x86 and arm64
builds.

Signed-off-by: Uwe Kleine-König (The Capable Hub) <u.kleine-koenig@baylibre.com>
Reviewed-by: Stepan Ionichev <sozdayvek@gmail.com>
Reviewed-by: Joshua Crofts <joshua.crofts1@gmail.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/staging/iio/addac/adt7316-i2c.c
drivers/staging/iio/impedance-analyzer/ad5933.c