ASoC: arizona: call wm_adsp2_remove when codec driver is removed

Ensure that the wm_adsp driver cleans up when the codec driver
is removed.

Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
Richard Fitzgerald
2016-04-27 14:58:28 +01:00
committed by Mark Brown
부모 66225e98b9
커밋 401cf1466a
3개의 변경된 파일15개의 추가작업 그리고 0개의 파일을 삭제

파일 보기

@@ -2435,10 +2435,16 @@ static int wm5110_probe(struct platform_device *pdev)
static int wm5110_remove(struct platform_device *pdev)
{
struct wm5110_priv *wm5110 = platform_get_drvdata(pdev);
int i;
snd_soc_unregister_platform(&pdev->dev);
snd_soc_unregister_codec(&pdev->dev);
pm_runtime_disable(&pdev->dev);
for (i = 0; i < WM5110_NUM_ADSP; i++)
wm_adsp2_remove(&wm5110->core.adsp[i]);
return 0;
}