]> git.baikalelectronics.ru Git - kernel.git/commit
usb: dwc3: keystone: check return value
authorPan Bian <bianpan2016@163.com>
Sun, 23 Apr 2017 05:55:13 +0000 (13:55 +0800)
committerFelipe Balbi <felipe.balbi@linux.intel.com>
Tue, 16 May 2017 11:11:04 +0000 (14:11 +0300)
commitd27e115b27140ff002d3a72a0ebd2d30f23ab343
treee4e4275636014062a31e542e81c7b1ac03fcf026
parent7e3f4e3319cd76e23fceedb2ad4408e499bd8f32
usb: dwc3: keystone: check return value

Function devm_clk_get() returns an ERR_PTR when it fails. However, in
function kdwc3_probe(), its return value is not checked, which may
result in a bad memory access bug. This patch fixes the bug.

Signed-off-by: Pan Bian <bianpan2016@163.com>
Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
drivers/usb/dwc3/dwc3-keystone.c