rtc: sysfs: use __ATTRIBUTE_GROUPS()
PATCH 1/1 rtc: sysfs: use __ATTRIBUTE_GROUPS()
Embrace __ATTRIBUTE_GROUPS() to avoid boiler plate code. This should not introduce any functional changes.
Signed-off-by Andy Shevchenko <[email protected]>
--- drivers/rtc/sysfs.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-)
drivers/rtc/sysfs.c +1 -5
@@ -298,11 +298,7 @@ static struct attribute_group rtc_attr_group = { .is_visible = rtc_attr_is_visible, .attrs = rtc_attrs, }; - -static const struct attribute_group *rtc_attr_groups[] = { - &rtc_attr_group, -NULL -}; +__ATTRIBUTE_GROUPS (rtc_attr);const struct attribute_group **rtc_get_dev_attribute_groups (void ) {
Signature · 1 line
2.47.2
Quoted 4 lines · Andy Shevchenko
Embrace
__ATTRIBUTE_GROUPS()to avoid boiler plate code. This should not introduce any functional changes.
Applied, thanks!
[1/1] rtc: sysfs: use __ATTRIBUTE_GROUPS()
https://git.kernel.org/abelloni/c/fed5aaeb4e94
Best regards,
Signature · 3 lines
Alexandre Belloni, co-owner and COO, Bootlin Embedded Linux and Kernel engineering https://bootlin.com