aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorH Hartley Sweeten <hartleys@visionengravers.com>2009-04-15 21:34:40 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2009-06-16 00:44:41 -0400
commita864e3aa5d8e1278c05aa93c57dba0debbb46858 (patch)
tree5f01488ae06e6802c32f037d8e2d6fee6ad52952
parentc5be1b52d9ea6ede4931691bf9f0bd454515aa52 (diff)
USB: core/sysfs: fix sparse warnings
Fix 3 sparse warning in drivers/usb/core/sysfs.c. warning: symbol '__mptr' shadows an earlier one Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r--drivers/usb/core/sysfs.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/usb/core/sysfs.c b/drivers/usb/core/sysfs.c
index c66789197927..b5c72e458943 100644
--- a/drivers/usb/core/sysfs.c
+++ b/drivers/usb/core/sysfs.c
@@ -552,8 +552,8 @@ static struct attribute *dev_string_attrs[] = {
552static mode_t dev_string_attrs_are_visible(struct kobject *kobj, 552static mode_t dev_string_attrs_are_visible(struct kobject *kobj,
553 struct attribute *a, int n) 553 struct attribute *a, int n)
554{ 554{
555 struct usb_device *udev = to_usb_device( 555 struct device *dev = container_of(kobj, struct device, kobj);
556 container_of(kobj, struct device, kobj)); 556 struct usb_device *udev = to_usb_device(dev);
557 557
558 if (a == &dev_attr_manufacturer.attr) { 558 if (a == &dev_attr_manufacturer.attr) {
559 if (udev->manufacturer == NULL) 559 if (udev->manufacturer == NULL)
@@ -585,8 +585,8 @@ static ssize_t
585read_descriptors(struct kobject *kobj, struct bin_attribute *attr, 585read_descriptors(struct kobject *kobj, struct bin_attribute *attr,
586 char *buf, loff_t off, size_t count) 586 char *buf, loff_t off, size_t count)
587{ 587{
588 struct usb_device *udev = to_usb_device( 588 struct device *dev = container_of(kobj, struct device, kobj);
589 container_of(kobj, struct device, kobj)); 589 struct usb_device *udev = to_usb_device(dev);
590 size_t nleft = count; 590 size_t nleft = count;
591 size_t srclen, n; 591 size_t srclen, n;
592 int cfgno; 592 int cfgno;
@@ -786,8 +786,8 @@ static struct attribute *intf_assoc_attrs[] = {
786static mode_t intf_assoc_attrs_are_visible(struct kobject *kobj, 786static mode_t intf_assoc_attrs_are_visible(struct kobject *kobj,
787 struct attribute *a, int n) 787 struct attribute *a, int n)
788{ 788{
789 struct usb_interface *intf = to_usb_interface( 789 struct device *dev = container_of(kobj, struct device, kobj);
790 container_of(kobj, struct device, kobj)); 790 struct usb_interface *intf = to_usb_interface(dev);
791 791
792 if (intf->intf_assoc == NULL) 792 if (intf->intf_assoc == NULL)
793 return 0; 793 return 0;