]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
usb: typec: ucsi: yoga-c630: fix error and remove paths
authorDmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Sat, 21 Jun 2025 18:12:56 +0000 (21:12 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 24 Jun 2025 14:40:50 +0000 (15:40 +0100)
commit168c3896f32e78e7b87f6aa9e85af36e47a9f96c
tree7cb402d3d22409df7751aeafe714a94c3603fa6e
parent860295a6bbbb9a9fd7e03dea7790cbcdad31da0c
usb: typec: ucsi: yoga-c630: fix error and remove paths

Fix memory leak and call ucsi_destroy() from the driver's remove
function and probe's error path in order to remove debugfs files and
free the memory. Also call yoga_c630_ec_unregister_notify() in the
probe's error path.

Fixes: 2ea6d07efe53 ("usb: typec: ucsi: add Lenovo Yoga C630 glue driver")
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Link: https://lore.kernel.org/r/20250621-c630-ucsi-v1-1-a86de5e11361@oss.qualcomm.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/typec/ucsi/ucsi_yoga_c630.c