mirror of
https://github.com/hardkernel/linux.git
synced 2026-03-24 19:40:21 +09:00
ASoC: codecs: wcd938x: fix unbind tear down order
commitfa2f8a991bupstream. Make sure to deregister the component before tearing down the resources it depends on during unbind(). Fixes:16572522ae("ASoC: codecs: wcd938x-sdw: add SoundWire driver") Cc: stable@vger.kernel.org # 5.14 Cc: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Johan Hovold <johan+linaro@kernel.org> Link: https://lore.kernel.org/r/20231003155558.27079-3-johan+linaro@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
b2974b20e4
commit
8092aed623
@@ -3510,10 +3510,10 @@ static void wcd938x_unbind(struct device *dev)
|
||||
{
|
||||
struct wcd938x_priv *wcd938x = dev_get_drvdata(dev);
|
||||
|
||||
snd_soc_unregister_component(dev);
|
||||
device_link_remove(dev, wcd938x->txdev);
|
||||
device_link_remove(dev, wcd938x->rxdev);
|
||||
device_link_remove(wcd938x->rxdev, wcd938x->txdev);
|
||||
snd_soc_unregister_component(dev);
|
||||
component_unbind_all(dev, wcd938x);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user