[PATCH v2 09/12] misc: ibmvmc: Use named initializers for vio_device_id array
From: Uwe Kleine-König (The Capable Hub)
Date: Fri Jul 17 2026 - 10:58:36 EST
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.
While touching this array, also simplify the list terminator. This
change doesn't introduce differences to the compiled result.
Signed-off-by: Uwe Kleine-König (The Capable Hub) <u.kleine-koenig@xxxxxxxxxxxx>
---
drivers/misc/ibmvmc.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/misc/ibmvmc.c b/drivers/misc/ibmvmc.c
index beb18c34f20d..a1d4955db5f3 100644
--- a/drivers/misc/ibmvmc.c
+++ b/drivers/misc/ibmvmc.c
@@ -2298,8 +2298,8 @@ static void ibmvmc_remove(struct vio_dev *vdev)
}
static struct vio_device_id ibmvmc_device_table[] = {
- { "ibm,vmc", "IBM,vmc" },
- { "", "" }
+ { .type = "ibm,vmc", .compat = "IBM,vmc" },
+ { }
};
MODULE_DEVICE_TABLE(vio, ibmvmc_device_table);
--
2.55.0.11.g153666a7d9bb