USB: serial: remove generic release callback
Remove empty generic release implementation and make the release callback non-mandatory (like attach, probe and disconnect). Signed-off-by: Johan Hovold <jhovold@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
0f16cfe39e
commit
79b80b8a11
3 changed files with 1 additions and 8 deletions
|
@ -137,7 +137,7 @@ static void destroy_serial(struct kref *kref)
|
|||
if (serial->minor != SERIAL_TTY_NO_MINOR)
|
||||
return_serial(serial);
|
||||
|
||||
if (serial->attached)
|
||||
if (serial->attached && serial->type->release)
|
||||
serial->type->release(serial);
|
||||
|
||||
/* Now that nothing is using the ports, they can be freed */
|
||||
|
@ -1305,7 +1305,6 @@ static void fixup_generic(struct usb_serial_driver *device)
|
|||
set_to_generic_if_null(device, chars_in_buffer);
|
||||
set_to_generic_if_null(device, read_bulk_callback);
|
||||
set_to_generic_if_null(device, write_bulk_callback);
|
||||
set_to_generic_if_null(device, release);
|
||||
set_to_generic_if_null(device, process_read_urb);
|
||||
set_to_generic_if_null(device, prepare_write_buffer);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue