aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/serial/bus.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2005-06-21 00:15:16 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2005-10-28 19:47:47 -0400
commitea65370d025f5005649e5cb37c4d025e92c6fc38 (patch)
tree554476fb8c69fc0f0f7dc5e2287f4c9cec1a26d6 /drivers/usb/serial/bus.c
parenta6c82600d4058346ea6fd801bc21d7abcc1350d8 (diff)
[PATCH] USB Serial: rename usb_serial_device_type to usb_serial_driver
I'm tired of trying to explain why a "device_type" is really a driver. This better describes exactly what this structure is. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/serial/bus.c')
-rw-r--r--drivers/usb/serial/bus.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/drivers/usb/serial/bus.c b/drivers/usb/serial/bus.c
index 2f612c2d894b..5a0bcd34bb6d 100644
--- a/drivers/usb/serial/bus.c
+++ b/drivers/usb/serial/bus.c
@@ -18,7 +18,7 @@
18 18
19static int usb_serial_device_match (struct device *dev, struct device_driver *drv) 19static int usb_serial_device_match (struct device *dev, struct device_driver *drv)
20{ 20{
21 struct usb_serial_device_type *driver; 21 struct usb_serial_driver *driver;
22 const struct usb_serial_port *port; 22 const struct usb_serial_port *port;
23 23
24 /* 24 /*
@@ -44,7 +44,7 @@ struct bus_type usb_serial_bus_type = {
44 44
45static int usb_serial_device_probe (struct device *dev) 45static int usb_serial_device_probe (struct device *dev)
46{ 46{
47 struct usb_serial_device_type *driver; 47 struct usb_serial_driver *driver;
48 struct usb_serial_port *port; 48 struct usb_serial_port *port;
49 int retval = 0; 49 int retval = 0;
50 int minor; 50 int minor;
@@ -80,7 +80,7 @@ exit:
80 80
81static int usb_serial_device_remove (struct device *dev) 81static int usb_serial_device_remove (struct device *dev)
82{ 82{
83 struct usb_serial_device_type *driver; 83 struct usb_serial_driver *driver;
84 struct usb_serial_port *port; 84 struct usb_serial_port *port;
85 int retval = 0; 85 int retval = 0;
86 int minor; 86 int minor;
@@ -109,26 +109,26 @@ exit:
109 return retval; 109 return retval;
110} 110}
111 111
112int usb_serial_bus_register(struct usb_serial_device_type *device) 112int usb_serial_bus_register(struct usb_serial_driver *driver)
113{ 113{
114 int retval; 114 int retval;
115 115
116 if (device->short_name) 116 if (driver->short_name)
117 device->driver.name = (char *)device->short_name; 117 driver->driver.name = (char *)driver->short_name;
118 else 118 else
119 device->driver.name = (char *)device->name; 119 driver->driver.name = (char *)driver->name;
120 device->driver.bus = &usb_serial_bus_type; 120 driver->driver.bus = &usb_serial_bus_type;
121 device->driver.probe = usb_serial_device_probe; 121 driver->driver.probe = usb_serial_device_probe;
122 device->driver.remove = usb_serial_device_remove; 122 driver->driver.remove = usb_serial_device_remove;
123 device->driver.owner = device->owner; 123 driver->driver.owner = driver->owner;
124 124
125 retval = driver_register(&device->driver); 125 retval = driver_register(&driver->driver);
126 126
127 return retval; 127 return retval;
128} 128}
129 129
130void usb_serial_bus_deregister(struct usb_serial_device_type *device) 130void usb_serial_bus_deregister(struct usb_serial_driver *driver)
131{ 131{
132 driver_unregister (&device->driver); 132 driver_unregister(&driver->driver);
133} 133}
134 134