usb: chipidea: usbmisc_imx: fix a possible NULL dereference
authorLABBE Corentin <clabbe.montjoie@gmail.com>
Thu, 12 Nov 2015 07:43:33 +0000 (08:43 +0100)
committerPeter Chen <peter.chen@freescale.com>
Wed, 18 Nov 2015 07:27:12 +0000 (15:27 +0800)
commit090bc267ea1013bbb33778b343b4acd78b9c5d9b
tree8ca3e39ef4e034b5f4fa1907bd43030819b9a75d
parent85da852df66e5e0d3aba761b0fece7c958ff0685
usb: chipidea: usbmisc_imx: fix a possible NULL dereference

of_match_device could return NULL, and so cause a NULL pointer
dereference later. Renaming tmp_dev to of_id (like all others do) in the
process.

Reported-by: coverity (CID 1324135)
Signed-off-by: LABBE Corentin <clabbe.montjoie@gmail.com>
Signed-off-by: Peter Chen <peter.chen@freescale.com>
drivers/usb/chipidea/usbmisc_imx.c