mirror of
https://github.com/torvalds/linux.git
synced 2026-07-27 09:36:22 +02:00
platform: arm64 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. While touching all these arrays, unify usage of whitespace in the list terminator. Signed-off-by: Uwe Kleine-König (The Capable Hub) <u.kleine-koenig@baylibre.com> Reviewed-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org> Link: https://patch.msgid.link/20260519144341.1589034-2-u.kleine-koenig@baylibre.com Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
This commit is contained in:
parent
18a166d29a
commit
fbab18baaf
|
|
@ -532,7 +532,7 @@ static int aspire_ec_resume(struct device *dev)
|
|||
}
|
||||
|
||||
static const struct i2c_device_id aspire_ec_id[] = {
|
||||
{ "aspire1-ec", },
|
||||
{ .name = "aspire1-ec" },
|
||||
{ }
|
||||
};
|
||||
MODULE_DEVICE_TABLE(i2c, aspire_ec_id);
|
||||
|
|
|
|||
|
|
@ -795,7 +795,7 @@ static int gaokun_ec_probe(struct i2c_client *client)
|
|||
}
|
||||
|
||||
static const struct i2c_device_id gaokun_ec_id[] = {
|
||||
{ "gaokun-ec", },
|
||||
{ .name = "gaokun-ec" },
|
||||
{ }
|
||||
};
|
||||
MODULE_DEVICE_TABLE(i2c, gaokun_ec_id);
|
||||
|
|
|
|||
|
|
@ -637,8 +637,8 @@ static const struct of_device_id t14s_ec_of_match[] = {
|
|||
MODULE_DEVICE_TABLE(of, t14s_ec_of_match);
|
||||
|
||||
static const struct i2c_device_id t14s_ec_i2c_id_table[] = {
|
||||
{ "thinkpad-t14s-ec", },
|
||||
{}
|
||||
{ .name = "thinkpad-t14s-ec" },
|
||||
{ }
|
||||
};
|
||||
MODULE_DEVICE_TABLE(i2c, t14s_ec_i2c_id_table);
|
||||
|
||||
|
|
|
|||
|
|
@ -238,8 +238,8 @@ static const struct of_device_id yoga_c630_ec_of_match[] = {
|
|||
MODULE_DEVICE_TABLE(of, yoga_c630_ec_of_match);
|
||||
|
||||
static const struct i2c_device_id yoga_c630_ec_i2c_id_table[] = {
|
||||
{ "yoga-c630-ec", },
|
||||
{}
|
||||
{ .name = "yoga-c630-ec" },
|
||||
{ }
|
||||
};
|
||||
MODULE_DEVICE_TABLE(i2c, yoga_c630_ec_i2c_id_table);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user