From: Christophe JAILLET Date: Fri, 18 Apr 2025 06:48:16 +0000 (+0200) Subject: drm/bridge: lt9611uxc: Fix an error handling path in lt9611uxc_probe() X-Git-Tag: v6.16-rc1~33^2~25^2~35 X-Git-Url: https://git.kernel.dk/?a=commitdiff_plain;h=b848cd418aebdb313364b4843f41fae82281a823;p=linux-block.git drm/bridge: lt9611uxc: Fix an error handling path in lt9611uxc_probe() If lt9611uxc_audio_init() fails, some resources still need to be released before returning the error code. Use the existing error handling path. Fixes: 0cbbd5b1a012 ("drm: bridge: add support for lontium LT9611UXC bridge") Signed-off-by: Christophe JAILLET Reviewed-by: Dmitry Baryshkov Link: https://lore.kernel.org/r/f167608e392c6b4d7d7f6e45e3c21878feb60cbd.1744958833.git.christophe.jaillet@wanadoo.fr Signed-off-by: Dmitry Baryshkov --- diff --git a/drivers/gpu/drm/bridge/lontium-lt9611uxc.c b/drivers/gpu/drm/bridge/lontium-lt9611uxc.c index 20bf1a3c786d..bb33c30d3f88 100644 --- a/drivers/gpu/drm/bridge/lontium-lt9611uxc.c +++ b/drivers/gpu/drm/bridge/lontium-lt9611uxc.c @@ -881,7 +881,11 @@ retry: } } - return lt9611uxc_audio_init(dev, lt9611uxc); + ret = lt9611uxc_audio_init(dev, lt9611uxc); + if (ret) + goto err_remove_bridge; + + return 0; err_remove_bridge: free_irq(client->irq, lt9611uxc);