]> git.itanic.dy.fi Git - linux-stable/commit
USB: serial: spcp8x5: fix NULL-deref at open
authorJohan Hovold <johan@kernel.org>
Tue, 3 Jan 2017 15:40:02 +0000 (16:40 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 12 Jan 2017 10:22:45 +0000 (11:22 +0100)
commit0243498813d20485e49d58f4d70bb2c12c89afa2
treeb3b4df3dcadc14dce199cda9a8fe0a6aa8f99b90
parent65d107038ec6ecee4a4240d23e87deb295051caf
USB: serial: spcp8x5: fix NULL-deref at open

commit cc0909248258f679c4bb4cd315565d40abaf6bc6 upstream.

Fix NULL-pointer dereference in open() should the device lack the
expected endpoints:

Unable to handle kernel NULL pointer dereference at virtual address 00000030
...
PC is at spcp8x5_open+0x30/0xd0 [spcp8x5]

Fixes: 619a6f1d1423 ("USB: add usb-serial spcp8x5 driver")
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/serial/spcp8x5.c