summaryrefslogtreecommitdiffstats
path: root/drivers/pwm/sysfs.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2014-01-27 17:15:51 +0100
committerLinus Torvalds <torvalds@linux-foundation.org>2014-01-27 17:15:51 +0100
commit398b60a8de46adfbd43aa4c01753acf0161ec764 (patch)
tree7d3a1673f4c764782cec34523967b386bf085fc6 /drivers/pwm/sysfs.c
parentMerge tag 'firewire-updates' of git://git.kernel.org/pub/scm/linux/kernel/git... (diff)
parentpwm: tiecap: Remove duplicate put_sync call (diff)
downloadlinux-398b60a8de46adfbd43aa4c01753acf0161ec764.tar.xz
linux-398b60a8de46adfbd43aa4c01753acf0161ec764.zip
Merge tag 'pwm/for-3.14-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/thierry.reding/linux-pwm
Pull pwm changes from Thierry Reding: "The patches for this release cycle include various enhancements (device tree support, better compile coverage, ...) for existing drivers. There is a new driver for Atmel SoCs. Various drivers as well as the sysfs support received minor fixes and cleanups" * tag 'pwm/for-3.14-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/thierry.reding/linux-pwm: pwm: tiecap: Remove duplicate put_sync call pwm: tiehrpwm: use dev_err() instead of pr_err() pwm: pxa: remove unnecessary space before tabs pwm: ep93xx: split module author names pwm: use seq_puts() instead of seq_printf() pwm: atmel-pwm: Do not unprepare clock after successful registration of: Add Atmel PWM controller device tree binding pwm: atmel-pwm: Add Atmel PWM controller driver backlight: pwm_bl: Remove error message upon devm_kzalloc() failure pwm: pca9685: depends on I2C rather than REGMAP_I2C pwm: renesas-tpu: Enable driver compilation with COMPILE_TEST pwm: jz4740: Use devm_clk_get() pwm: jz4740: Pass device to clk_get() pwm: sysfs: Convert to use ATTRIBUTE_GROUPS macro pwm: pxa: Add device tree support
Diffstat (limited to 'drivers/pwm/sysfs.c')
-rw-r--r--drivers/pwm/sysfs.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/drivers/pwm/sysfs.c b/drivers/pwm/sysfs.c
index 8c20332d4825..4bd0c639e16d 100644
--- a/drivers/pwm/sysfs.c
+++ b/drivers/pwm/sysfs.c
@@ -169,15 +169,7 @@ static struct attribute *pwm_attrs[] = {
&dev_attr_polarity.attr,
NULL
};
-
-static const struct attribute_group pwm_attr_group = {
- .attrs = pwm_attrs,
-};
-
-static const struct attribute_group *pwm_attr_groups[] = {
- &pwm_attr_group,
- NULL,
-};
+ATTRIBUTE_GROUPS(pwm);
static void pwm_export_release(struct device *child)
{
@@ -205,7 +197,7 @@ static int pwm_export_child(struct device *parent, struct pwm_device *pwm)
export->child.release = pwm_export_release;
export->child.parent = parent;
export->child.devt = MKDEV(0, 0);
- export->child.groups = pwm_attr_groups;
+ export->child.groups = pwm_groups;
dev_set_name(&export->child, "pwm%u", pwm->hwpwm);
ret = device_register(&export->child);