staging: dgap: unwind on error in dgap_tty_init()
authorDaeseok Youn <daeseok.youn@gmail.com>
Mon, 2 Jun 2014 05:07:46 +0000 (14:07 +0900)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 19 Jun 2014 22:21:47 +0000 (15:21 -0700)
commit551a9d73942b0ffa6cb9fe3bb35936dcc7172281
tree511dec71c8a10495ddb0fd3726faa5ef118e5f5a
parente74c2ddcbbc3ecfc55c246b3da3c5320fe46d8e3
staging: dgap: unwind on error in dgap_tty_init()

If the kzalloc() fails for channels, it need to handle
that error. It should free channels which were already
allocated.

And also removes the call to dgap_tty_uninit() in
dgap_firmware_load().

Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/dgap/dgap.c