diff options
author | Greg Kroah-Hartman <gregkh@suse.de> | 2006-06-14 15:14:34 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2006-06-21 18:04:19 -0400 |
commit | 36679ea59846d8f34a48f71ca1a37671ca0ad3c5 (patch) | |
tree | 3483f57f83dc5af39c773246255c85954ff4b67f /drivers/usb | |
parent | 84412f6291b50690febd81899e46f0f0ef7a13e0 (diff) |
[PATCH] USB: make usb_create_ep_files take a struct device
Instead of a kobject, will make things easier in the future (don't know
what I was thinking when I did this originally...)
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb')
-rw-r--r-- | drivers/usb/core/endpoint.c | 4 | ||||
-rw-r--r-- | drivers/usb/core/sysfs.c | 4 | ||||
-rw-r--r-- | drivers/usb/core/usb.h | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/drivers/usb/core/endpoint.c b/drivers/usb/core/endpoint.c index 2b1697715e88..4c2fe8f723e5 100644 --- a/drivers/usb/core/endpoint.c +++ b/drivers/usb/core/endpoint.c | |||
@@ -173,7 +173,7 @@ static struct kobj_type ep_object_ktype = { | |||
173 | .default_attrs = ep_attrs, | 173 | .default_attrs = ep_attrs, |
174 | }; | 174 | }; |
175 | 175 | ||
176 | void usb_create_ep_files(struct kobject *parent, | 176 | void usb_create_ep_files(struct device *parent, |
177 | struct usb_host_endpoint *endpoint, | 177 | struct usb_host_endpoint *endpoint, |
178 | struct usb_device *udev) | 178 | struct usb_device *udev) |
179 | { | 179 | { |
@@ -189,7 +189,7 @@ void usb_create_ep_files(struct kobject *parent, | |||
189 | 189 | ||
190 | kobj = &ep_obj->kobj; | 190 | kobj = &ep_obj->kobj; |
191 | kobject_set_name(kobj, "ep_%02x", endpoint->desc.bEndpointAddress); | 191 | kobject_set_name(kobj, "ep_%02x", endpoint->desc.bEndpointAddress); |
192 | kobj->parent = parent; | 192 | kobj->parent = &parent->kobj; |
193 | kobj->ktype = &ep_object_ktype; | 193 | kobj->ktype = &ep_object_ktype; |
194 | 194 | ||
195 | /* Don't use kobject_register, because it generates a hotplug event */ | 195 | /* Don't use kobject_register, because it generates a hotplug event */ |
diff --git a/drivers/usb/core/sysfs.c b/drivers/usb/core/sysfs.c index cc18a05e5777..3f49bf51cff7 100644 --- a/drivers/usb/core/sysfs.c +++ b/drivers/usb/core/sysfs.c | |||
@@ -223,7 +223,7 @@ void usb_create_sysfs_dev_files (struct usb_device *udev) | |||
223 | if (udev->serial) | 223 | if (udev->serial) |
224 | device_create_file (dev, &dev_attr_serial); | 224 | device_create_file (dev, &dev_attr_serial); |
225 | device_create_file (dev, &dev_attr_configuration); | 225 | device_create_file (dev, &dev_attr_configuration); |
226 | usb_create_ep_files(&dev->kobj, &udev->ep0, udev); | 226 | usb_create_ep_files(dev, &udev->ep0, udev); |
227 | } | 227 | } |
228 | 228 | ||
229 | void usb_remove_sysfs_dev_files (struct usb_device *udev) | 229 | void usb_remove_sysfs_dev_files (struct usb_device *udev) |
@@ -327,7 +327,7 @@ static inline void usb_create_intf_ep_files(struct usb_interface *intf, | |||
327 | 327 | ||
328 | iface_desc = intf->cur_altsetting; | 328 | iface_desc = intf->cur_altsetting; |
329 | for (i = 0; i < iface_desc->desc.bNumEndpoints; ++i) | 329 | for (i = 0; i < iface_desc->desc.bNumEndpoints; ++i) |
330 | usb_create_ep_files(&intf->dev.kobj, &iface_desc->endpoint[i], | 330 | usb_create_ep_files(&intf->dev, &iface_desc->endpoint[i], |
331 | udev); | 331 | udev); |
332 | } | 332 | } |
333 | 333 | ||
diff --git a/drivers/usb/core/usb.h b/drivers/usb/core/usb.h index 941cb397ba04..7a650c763a62 100644 --- a/drivers/usb/core/usb.h +++ b/drivers/usb/core/usb.h | |||
@@ -4,7 +4,7 @@ extern void usb_create_sysfs_dev_files (struct usb_device *dev); | |||
4 | extern void usb_remove_sysfs_dev_files (struct usb_device *dev); | 4 | extern void usb_remove_sysfs_dev_files (struct usb_device *dev); |
5 | extern void usb_create_sysfs_intf_files (struct usb_interface *intf); | 5 | extern void usb_create_sysfs_intf_files (struct usb_interface *intf); |
6 | extern void usb_remove_sysfs_intf_files (struct usb_interface *intf); | 6 | extern void usb_remove_sysfs_intf_files (struct usb_interface *intf); |
7 | extern void usb_create_ep_files(struct kobject *parent, struct usb_host_endpoint *endpoint, | 7 | extern void usb_create_ep_files(struct device *parent, struct usb_host_endpoint *endpoint, |
8 | struct usb_device *udev); | 8 | struct usb_device *udev); |
9 | extern void usb_remove_ep_files(struct usb_host_endpoint *endpoint); | 9 | extern void usb_remove_ep_files(struct usb_host_endpoint *endpoint); |
10 | 10 | ||