diff options
| author | Andy Shevchenko <[email protected]> | 2025-07-02 08:01:08 +0000 |
|---|---|---|
| committer | Alexandre Belloni <[email protected]> | 2025-07-22 11:06:19 +0000 |
| commit | fed5aaeb4e94e0f071bf467f2bafd5ea6f093722 (patch) | |
| tree | 68ac298b41cb7599fb09451a31aed292d088fdbf /drivers/rtc | |
| parent | rtc: sysfs: Bail out earlier if no new groups provided (diff) | |
| download | kernel-fed5aaeb4e94e0f071bf467f2bafd5ea6f093722.tar.gz kernel-fed5aaeb4e94e0f071bf467f2bafd5ea6f093722.zip | |
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]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Alexandre Belloni <[email protected]>
Diffstat (limited to 'drivers/rtc')
| -rw-r--r-- | drivers/rtc/sysfs.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/drivers/rtc/sysfs.c b/drivers/rtc/sysfs.c index bf98a89d0e4e..4ab05e105a76 100644 --- a/drivers/rtc/sysfs.c +++ b/drivers/rtc/sysfs.c @@ -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) { |
