mmc: Convert to use ATTRIBUTE_GROUPS
authorAxel Lin <axel.lin@ingics.com>
Sat, 8 Mar 2014 07:05:27 +0000 (15:05 +0800)
committerChris Ball <chris@printf.net>
Tue, 22 Apr 2014 11:06:38 +0000 (07:06 -0400)
Use new ATTRIBUTE_GROUPS macro to declare attribute groups.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: Chris Ball <chris@printf.net>
drivers/mmc/core/mmc.c
drivers/mmc/core/sd.c

index e22d8515ff97ee607a28c277ca81d71ee7b594d0..fbcf93d818585761bc68507b68297a7d2095ca9f 100644 (file)
@@ -694,18 +694,10 @@ static struct attribute *mmc_std_attrs[] = {
        &dev_attr_rel_sectors.attr,
        NULL,
 };
-
-static struct attribute_group mmc_std_attr_group = {
-       .attrs = mmc_std_attrs,
-};
-
-static const struct attribute_group *mmc_attr_groups[] = {
-       &mmc_std_attr_group,
-       NULL,
-};
+ATTRIBUTE_GROUPS(mmc_std);
 
 static struct device_type mmc_type = {
-       .groups = mmc_attr_groups,
+       .groups = mmc_std_groups,
 };
 
 /*
index 2dd359d2242fa811efae1a03d02ca9d9dfba77ca..aef515755e5bf94c2da03bab5b3f28cb3f38d0f9 100644 (file)
@@ -707,18 +707,10 @@ static struct attribute *sd_std_attrs[] = {
        &dev_attr_serial.attr,
        NULL,
 };
-
-static struct attribute_group sd_std_attr_group = {
-       .attrs = sd_std_attrs,
-};
-
-static const struct attribute_group *sd_attr_groups[] = {
-       &sd_std_attr_group,
-       NULL,
-};
+ATTRIBUTE_GROUPS(sd_std);
 
 struct device_type sd_type = {
-       .groups = sd_attr_groups,
+       .groups = sd_std_groups,
 };
 
 /*