serial.c (b10778a00d40b3d9fdaaf5891e802794781ff71c) serial.c (c94e289f195e0e13cf34d27f9338d28221a85751)
1/*
2 * serial.c -- USB gadget serial driver
3 *
4 * Copyright (C) 2003 Al Borchers (alborchers@steinerpoint.com)
5 * Copyright (C) 2008 by David Brownell
6 * Copyright (C) 2008 by Nokia Corporation
7 *
8 * This software is distributed under the terms of the GNU General

--- 160 unchanged lines hidden (view full) ---

169 usb_put_function(f_serial[i]);
170 usb_put_function_instance(fi_serial[i]);
171 i--;
172 }
173out:
174 return ret;
175}
176
1/*
2 * serial.c -- USB gadget serial driver
3 *
4 * Copyright (C) 2003 Al Borchers (alborchers@steinerpoint.com)
5 * Copyright (C) 2008 by David Brownell
6 * Copyright (C) 2008 by Nokia Corporation
7 *
8 * This software is distributed under the terms of the GNU General

--- 160 unchanged lines hidden (view full) ---

169 usb_put_function(f_serial[i]);
170 usb_put_function_instance(fi_serial[i]);
171 i--;
172 }
173out:
174 return ret;
175}
176
177static int __init gs_bind(struct usb_composite_dev *cdev)
177static int gs_bind(struct usb_composite_dev *cdev)
178{
179 int status;
180
181 /* Allocate string descriptor numbers ... note that string
182 * contents can be overridden by the composite_dev glue.
183 */
184
185 status = usb_string_ids_tab(cdev, strings_dev);

--- 39 unchanged lines hidden (view full) ---

225
226 for (i = 0; i < n_ports; i++) {
227 usb_put_function(f_serial[i]);
228 usb_put_function_instance(fi_serial[i]);
229 }
230 return 0;
231}
232
178{
179 int status;
180
181 /* Allocate string descriptor numbers ... note that string
182 * contents can be overridden by the composite_dev glue.
183 */
184
185 status = usb_string_ids_tab(cdev, strings_dev);

--- 39 unchanged lines hidden (view full) ---

225
226 for (i = 0; i < n_ports; i++) {
227 usb_put_function(f_serial[i]);
228 usb_put_function_instance(fi_serial[i]);
229 }
230 return 0;
231}
232
233static __refdata struct usb_composite_driver gserial_driver = {
233static struct usb_composite_driver gserial_driver = {
234 .name = "g_serial",
235 .dev = &device_desc,
236 .strings = dev_strings,
237 .max_speed = USB_SPEED_SUPER,
238 .bind = gs_bind,
239 .unbind = gs_unbind,
240};
241

--- 35 unchanged lines hidden ---
234 .name = "g_serial",
235 .dev = &device_desc,
236 .strings = dev_strings,
237 .max_speed = USB_SPEED_SUPER,
238 .bind = gs_bind,
239 .unbind = gs_unbind,
240};
241

--- 35 unchanged lines hidden ---