Lines Matching refs:groups
324 const struct attribute_group **groups, **old; in rtc_add_groups() local
331 groups = rtc->dev.groups; in rtc_add_groups()
332 if (groups) in rtc_add_groups()
333 for (; *groups; groups++) in rtc_add_groups()
336 for (groups = grps; *groups; groups++) in rtc_add_groups()
340 groups = devm_kcalloc(&rtc->dev, new_cnt, sizeof(*groups), GFP_KERNEL); in rtc_add_groups()
341 if (!groups) in rtc_add_groups()
343 memcpy(groups, rtc->dev.groups, old_cnt * sizeof(*groups)); in rtc_add_groups()
344 memcpy(groups + old_cnt, grps, add_cnt * sizeof(*groups)); in rtc_add_groups()
345 groups[old_cnt + add_cnt] = NULL; in rtc_add_groups()
347 old = rtc->dev.groups; in rtc_add_groups()
348 rtc->dev.groups = groups; in rtc_add_groups()
358 const struct attribute_group *groups[] = { grp, NULL }; in rtc_add_group() local
360 return rtc_add_groups(rtc, groups); in rtc_add_group()