]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
usb: typec: Add the missed altmode_id_remove() in typec_register_altmode()
authorJing Xiangfeng <jingxiangfeng@huawei.com>
Thu, 17 Jun 2021 07:32:26 +0000 (15:32 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 20 Jul 2021 14:15:39 +0000 (16:15 +0200)
commit9c7de678190ac6d48e51633584075d045901b580
tree8bdb383492021ae53542fac902447e5e13cfb261
parent309970bf56ed469eef1d59d20be5d37693845076
usb: typec: Add the missed altmode_id_remove() in typec_register_altmode()

commit 03026197bb657d784220b040c6173267a0375741 upstream.

typec_register_altmode() misses to call altmode_id_remove() in an error
path. Add the missed function call to fix it.

Fixes: 8a37d87d72f0 ("usb: typec: Bus type for alternate modes")
Cc: stable <stable@vger.kernel.org>
Acked-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Signed-off-by: Jing Xiangfeng <jingxiangfeng@huawei.com>
Link: https://lore.kernel.org/r/20210617073226.47599-1-jingxiangfeng@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/typec/class.c