OSDN Git Service

usb: usb251xb: Fix property_u32 NULL pointer dereference
authorSerge Semin <fancer.lancer@gmail.com>
Sun, 22 Oct 2017 20:38:10 +0000 (23:38 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 1 Nov 2017 16:14:21 +0000 (17:14 +0100)
commit287c2bb6e1b5b1299da59537fe58515001286c85
tree7b8723c070c80b29b7204a6b2dae17b572182448
parent2818e13ae174bf6a607db3e3fc405bbf5f66b1ce
usb: usb251xb: Fix property_u32 NULL pointer dereference

The methods like of_property_read_u32 utilizing the specified
pointer permit only the pointer to a preallocated u32 storage as the
third argument. As a result the driver crashes on NULL pointer
dereference in case if "oc-delay-us" or "power-on-time-ms" declared
in dts file.

Signed-off-by: Serge Semin <fancer.lancer@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/misc/usb251xb.c