Skip to content
Commit 342161c1 authored by Li Yang's avatar Li Yang Committed by Greg Kroah-Hartman
Browse files

usb: phy: phy-tahvo: fix memory leak in tahvo_usb_probe()



Smatch reports:
drivers/usb/phy/phy-tahvo.c: tahvo_usb_probe()
warn: missing unwind goto?

After geting irq, if ret < 0, it will return without error handling to
free memory.
Just add error handling to fix this problem.

Fixes: 0d45a137 ("usb: phy: tahvo: add IRQ check")
Signed-off-by: default avatarLi Yang <lidaxian@hust.edu.cn>
Reviewed-by: default avatarDongliang Mu <dzm91@hust.edu.cn>
Link: https://lore.kernel.org/r/20230420140832.9110-1-lidaxian@hust.edu.cn


Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 4a680fcd
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment