diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-11-07 10:03:42 +0900 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-11-07 11:42:15 +0900 |
commit | 0324e74534241f3f00910ec04ef67de1fe1542f4 (patch) | |
tree | 88f0b2a40a47dc0a22c0ce5e9b75a58470a56204 /drivers/uwb | |
parent | 1071ec7bc2dabd0a9d12a1ae5570f4fd3ba944ca (diff) | |
parent | 0cae60f91494e34a0c5391f1455f825d5849b05f (diff) |
Merge tag 'driver-core-3.13-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core
Pull driver core / sysfs patches from Greg KH:
"Here's the big driver core / sysfs update for 3.13-rc1.
There's lots of dev_groups updates for different subsystems, as they
all get slowly migrated over to the safe versions of the attribute
groups (removing userspace races with the creation of the sysfs
files.) Also in here are some kobject updates, devres expansions, and
the first round of Tejun's sysfs reworking to enable it to be used by
other subsystems as a backend for an in-kernel filesystem.
All of these have been in linux-next for a while with no reported
issues"
* tag 'driver-core-3.13-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: (83 commits)
sysfs: rename sysfs_assoc_lock and explain what it's about
sysfs: use generic_file_llseek() for sysfs_file_operations
sysfs: return correct error code on unimplemented mmap()
mdio_bus: convert bus code to use dev_groups
device: Make dev_WARN/dev_WARN_ONCE print device as well as driver name
sysfs: separate out dup filename warning into a separate function
sysfs: move sysfs_hash_and_remove() to fs/sysfs/dir.c
sysfs: remove unused sysfs_get_dentry() prototype
sysfs: honor bin_attr.attr.ignore_lockdep
sysfs: merge sysfs_elem_bin_attr into sysfs_elem_attr
devres: restore zeroing behavior of devres_alloc()
sysfs: fix sysfs_write_file for bin file
input: gameport: convert bus code to use dev_groups
input: serio: remove bus usage of dev_attrs
input: serio: use DEVICE_ATTR_RO()
i2o: convert bus code to use dev_groups
memstick: convert bus code to use dev_groups
tifm: convert bus code to use dev_groups
virtio: convert bus code to use dev_groups
ipack: convert bus code to use dev_groups
...
Diffstat (limited to 'drivers/uwb')
-rw-r--r-- | drivers/uwb/umc-bus.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/drivers/uwb/umc-bus.c b/drivers/uwb/umc-bus.c index 5c5b3fc9088a..e3ed6ff6a481 100644 --- a/drivers/uwb/umc-bus.c +++ b/drivers/uwb/umc-bus.c @@ -201,6 +201,7 @@ static ssize_t capability_id_show(struct device *dev, struct device_attribute *a return sprintf(buf, "0x%02x\n", umc->cap_id); } +static DEVICE_ATTR_RO(capability_id); static ssize_t version_show(struct device *dev, struct device_attribute *attr, char *buf) { @@ -208,12 +209,14 @@ static ssize_t version_show(struct device *dev, struct device_attribute *attr, c return sprintf(buf, "0x%04x\n", umc->version); } +static DEVICE_ATTR_RO(version); -static struct device_attribute umc_dev_attrs[] = { - __ATTR_RO(capability_id), - __ATTR_RO(version), - __ATTR_NULL, +static struct attribute *umc_dev_attrs[] = { + &dev_attr_capability_id.attr, + &dev_attr_version.attr, + NULL, }; +ATTRIBUTE_GROUPS(umc_dev); struct bus_type umc_bus_type = { .name = "umc", @@ -222,7 +225,7 @@ struct bus_type umc_bus_type = { .remove = umc_device_remove, .suspend = umc_device_suspend, .resume = umc_device_resume, - .dev_attrs = umc_dev_attrs, + .dev_groups = umc_dev_groups, }; EXPORT_SYMBOL_GPL(umc_bus_type); |