diff options
| author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-10-05 23:10:14 -0700 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-10-05 23:10:14 -0700 |
| commit | 9e06a307a040bb17573afb2f48b6a7d26920394f (patch) | |
| tree | 222b8cbd15a432f906f01dcd21de484984a01bc4 /p16.patch | |
| parent | 439aaed86577bc756086c2193f8fa23ae48d6722 (diff) | |
| download | patches-9e06a307a040bb17573afb2f48b6a7d26920394f.tar.gz | |
new dev_attr bus removal patches added
Diffstat (limited to 'p16.patch')
| -rw-r--r-- | p16.patch | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/p16.patch b/p16.patch new file mode 100644 index 00000000000000..0787a2dcb91eba --- /dev/null +++ b/p16.patch @@ -0,0 +1,40 @@ +--- + drivers/memstick/core/memstick.c | 18 +++++++++--------- + 1 file changed, 9 insertions(+), 9 deletions(-) + +--- a/drivers/memstick/core/memstick.c ++++ b/drivers/memstick/core/memstick.c +@@ -153,24 +153,24 @@ static ssize_t name##_show(struct device + struct memstick_dev *card = container_of(dev, struct memstick_dev, \ + dev); \ + return sprintf(buf, format, card->id.name); \ +-} ++} \ ++static DEVICE_ATTR_RO(name); + + MEMSTICK_ATTR(type, "%02X"); + MEMSTICK_ATTR(category, "%02X"); + MEMSTICK_ATTR(class, "%02X"); + +-#define MEMSTICK_ATTR_RO(name) __ATTR(name, S_IRUGO, name##_show, NULL) +- +-static struct device_attribute memstick_dev_attrs[] = { +- MEMSTICK_ATTR_RO(type), +- MEMSTICK_ATTR_RO(category), +- MEMSTICK_ATTR_RO(class), +- __ATTR_NULL ++static struct attribute *memstick_dev_attrs[] = { ++ &dev_attr_type.attr, ++ &dev_attr_category.attr, ++ &dev_attr_class.attr, ++ NULL, + }; ++ATTRIBUTE_GROUPS(memstick_dev); + + static struct bus_type memstick_bus_type = { + .name = "memstick", +- .dev_attrs = memstick_dev_attrs, ++ .dev_groups = memstick_dev_groups, + .match = memstick_bus_match, + .uevent = memstick_uevent, + .probe = memstick_device_probe, |
