[PATCH RFC 05/10] driver core: make struct device member groups a constant array
From: Heiner Kallweit
Date: Tue Feb 17 2026 - 17:29:20 EST
Constify the groups array, allowing to assign constant arrays.
Signed-off-by: Heiner Kallweit <hkallweit1@xxxxxxxxx>
---
include/linux/device.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/linux/device.h b/include/linux/device.h
index 48a0444ccc1..bfa2ca603c2 100644
--- a/include/linux/device.h
+++ b/include/linux/device.h
@@ -640,7 +640,7 @@ struct device {
struct list_head devres_head;
const struct class *class;
- const struct attribute_group **groups; /* optional groups */
+ const struct attribute_group *const *groups; /* optional groups */
void (*release)(struct device *dev);
struct iommu_group *iommu_group;
--
2.53.0