diff options
author | Jaejoong Kim <climbbb.kim@gmail.com> | 2018-06-21 11:45:05 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2018-06-25 16:58:26 +0300 |
commit | cae2bc768d176bfbdad7035bbcc3cdc973eb7984 (patch) | |
tree | 09cd58c17e3575c3a4698271c0f9e403591cc050 /drivers/usb/host/Makefile | |
parent | 61ef4b90793b3c1905ed8cbec228ff63ecb1a5c5 (diff) | |
download | linux-cae2bc768d176bfbdad7035bbcc3cdc973eb7984.tar.xz |
usb: cdc-acm: Decrement tty port's refcount if probe() fail
The cdc-acm driver does not have a refcount of itself, but uses a
tty_port's refcount. That is, if the refcount of tty_port is '0', we
can clean up the cdc-acm driver by calling the .destruct()
callback function of struct tty_port_operations.
The problem is the destruct() callback function is not called if
the probe() fails, because tty_port's refcount is not zero. So,
add tty_port_put() when probe() fails.
Signed-off-by: Jaejoong Kim <climbbb.kim@gmail.com>
Acked-by: Oliver Neukum <oneukum@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/host/Makefile')
0 files changed, 0 insertions, 0 deletions