diff options
| author | Pawel Zalewski <pzalewski@thegoodpenguin.co.uk> | 2026-10-13 16:15:23 +0100 |
|---|---|---|
| committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2026-10-14 10:49:48 -0700 |
| commit | e7f8b63997e3dbbeb2f3f845a84ea6cc924f6c1e (patch) | |
| tree | 8cad6086aa2caf9ee13cc233dd7c6bc129f215b8 | |
| parent | 2e3600723a99f131d704ca0f1acf36dcf7af9dac (diff) | |
Input: misc - use named initializers for acpi_device_id
Use a designated initializer for the acpi_device_id fields which makes the
code more readable and consistent with how lists are initialized in the
rest of the kernel code base. Also drop explicitly setting fields to 0
where it is redundant.
Unify the list terminator to have a single space between the brackets and
no trailing comma.
Signed-off-by: Pawel Zalewski <pzalewski@thegoodpenguin.co.uk>
Link: https://patch.msgid.link/20261013-acpi-input-v1-2-53ad09ba82b7@thegoodpenguin.co.uk
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
| -rw-r--r-- | drivers/input/misc/atlas_btns.c | 4 | ||||
| -rw-r--r-- | drivers/input/misc/drv260x.c | 2 | ||||
| -rw-r--r-- | drivers/input/misc/soc_button_array.c | 12 |
3 files changed, 9 insertions, 9 deletions
diff --git a/drivers/input/misc/atlas_btns.c b/drivers/input/misc/atlas_btns.c index 5805a1a3bb05..e77e53ee9d41 100644 --- a/drivers/input/misc/atlas_btns.c +++ b/drivers/input/misc/atlas_btns.c @@ -128,8 +128,8 @@ static void atlas_acpi_button_remove(struct platform_device *pdev) } static const struct acpi_device_id atlas_device_ids[] = { - { "ASIM0000" }, - { "" } + { .id = "ASIM0000" }, + { } }; MODULE_DEVICE_TABLE(acpi, atlas_device_ids); diff --git a/drivers/input/misc/drv260x.c b/drivers/input/misc/drv260x.c index 6c5c4c53753b..8a3d74d65d63 100644 --- a/drivers/input/misc/drv260x.c +++ b/drivers/input/misc/drv260x.c @@ -640,7 +640,7 @@ MODULE_DEVICE_TABLE(i2c, drv260x_id); #ifdef CONFIG_ACPI static const struct acpi_device_id drv260x_acpi_match[] = { - { "DRV2604" }, + { .id = "DRV2604" }, { } }; MODULE_DEVICE_TABLE(acpi, drv260x_acpi_match); diff --git a/drivers/input/misc/soc_button_array.c b/drivers/input/misc/soc_button_array.c index b8cad415c62c..2a4f7dd95e99 100644 --- a/drivers/input/misc/soc_button_array.c +++ b/drivers/input/misc/soc_button_array.c @@ -596,14 +596,14 @@ static const struct soc_device_data soc_device_MSHW0040 = { }; static const struct acpi_device_id soc_button_acpi_match[] = { - { "PNP0C40", (unsigned long)&soc_device_PNP0C40 }, - { "INT33D3", (unsigned long)&soc_device_INT33D3 }, - { "ID9001", (unsigned long)&soc_device_INT33D3 }, - { "ACPI0011", 0 }, + { .id = "PNP0C40", .driver_data = (unsigned long)&soc_device_PNP0C40 }, + { .id = "INT33D3", .driver_data = (unsigned long)&soc_device_INT33D3 }, + { .id = "ID9001", .driver_data = (unsigned long)&soc_device_INT33D3 }, + { .id = "ACPI0011" }, /* Microsoft Surface Devices (3th, 5th and 6th generation) */ - { "MSHW0028", (unsigned long)&soc_device_MSHW0028 }, - { "MSHW0040", (unsigned long)&soc_device_MSHW0040 }, + { .id = "MSHW0028", .driver_data = (unsigned long)&soc_device_MSHW0028 }, + { .id = "MSHW0040", .driver_data = (unsigned long)&soc_device_MSHW0040 }, { } }; |
