Lines Matching refs:groups
319 const struct attribute_group **groups, **old; in rtc_add_groups() local
324 groups = rtc->dev.groups; in rtc_add_groups()
325 if (groups) in rtc_add_groups()
326 for (; *groups; groups++) in rtc_add_groups()
329 for (groups = grps; *groups; groups++) in rtc_add_groups()
333 groups = devm_kcalloc(&rtc->dev, new_cnt, sizeof(*groups), GFP_KERNEL); in rtc_add_groups()
334 if (!groups) in rtc_add_groups()
336 memcpy(groups, rtc->dev.groups, old_cnt * sizeof(*groups)); in rtc_add_groups()
337 memcpy(groups + old_cnt, grps, add_cnt * sizeof(*groups)); in rtc_add_groups()
338 groups[old_cnt + add_cnt] = NULL; in rtc_add_groups()
340 old = rtc->dev.groups; in rtc_add_groups()
341 rtc->dev.groups = groups; in rtc_add_groups()
351 const struct attribute_group *groups[] = { grp, NULL }; in rtc_add_group() local
353 return rtc_add_groups(rtc, groups); in rtc_add_group()