Received: by 2002:a25:7ec1:0:0:0:0:0 with SMTP id z184csp2317257ybc; Sun, 17 Nov 2019 18:49:05 -0800 (PST) X-Google-Smtp-Source: APXvYqzLGGkLvLxxn63SrnpimmgR/TqZAgqGKvdYf8onOi4tvfBv9uNYWOpAkn2/n6QjPtA3meFb X-Received: by 2002:a17:906:9481:: with SMTP id t1mr23629996ejx.0.1574045344918; Sun, 17 Nov 2019 18:49:04 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574045344; cv=none; d=google.com; s=arc-20160816; b=voqLG1SGnkZVC4FFeV3gu8GKgtgWqNoCA0+pv8ss8+3JlPC7CERfranyyFg26e4j2C OUg+upMMTSx/MJeriqHyM0d8FSxSGiW2Ip0mfDGQLNovKmPYWSe4cywJXq5k1yj41CcP d2tiqSIWOkiqxEfDMDgnxIWMdGZdg1GH3PN4l848xMrSWn5dhFM96wB/WDKit7GupiLF U6dh/OB3etpH28gA929AROLujff94IAt/6iyYLcWrHMsRFOre1L5qQ8mckQSrmtkTYet yUNPmieldYMx27rSu7Qa39OvXNl4QPku5tovyGSVFnWtMe1InVkMv5ex1ahlPdXBR1tX rhyg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:content-transfer-encoding:mime-version :message-id:date:subject:cc:from:dkim-signature; bh=RREC1ahvRFfGyw76l4ibA9bqTupLckMQgY54O0gStrA=; b=cyoZ69fxFXAPcPktmDnj4rFjq+VY097CayVqLvYafFvjhoKjDXqmbjjn7TeI2B1kHr naX/gZs8oC7jtuoWFNGg29tjtxE6Nec3I2ANg5rpA4Yx2Lpd7ikLCD6nK32tK2vCFBWB 4/RvBV5MBkovcgJfo7pLT9gYhhvv/7wZhBhz3jEKY4djs/bPJhVNrzRk2R/S1ij1Qyz+ 8P32fkgoyTqBxvqoCHhIGiUlFhAC9lSvWGm7o1AlyTitBgzcnAXKfCjk5zXkYd0Uut2m Ie/IByy2+XrW+9UXETBDeSan4Vmf6iI00iqmv/1kZKeZ9YhWVnlsksg256DoCnF+mdcq +Umg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=lW+dGN+R; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h22si12187214edb.346.2019.11.17.18.48.41; Sun, 17 Nov 2019 18:49:04 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=lW+dGN+R; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726425AbfKRCrf (ORCPT + 99 others); Sun, 17 Nov 2019 21:47:35 -0500 Received: from mail-pf1-f194.google.com ([209.85.210.194]:40550 "EHLO mail-pf1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726168AbfKRCrf (ORCPT ); Sun, 17 Nov 2019 21:47:35 -0500 Received: by mail-pf1-f194.google.com with SMTP id r4so9608629pfl.7 for ; Sun, 17 Nov 2019 18:47:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=RREC1ahvRFfGyw76l4ibA9bqTupLckMQgY54O0gStrA=; b=lW+dGN+REA8N1B3l0ms9i7xiFULF9g+HqA3J5bWNgPmMViTEGbfFiKZqRb5DNPvniM nkT58TrOQmBLhxqz49sqtU1r50FRvwWUPT/uPWPvWYritw8YmnvSZpe/N1jjluLp0brm RwPDgpC8hKxNR3WrYAwWt4JxVxPBgKZftCWLVMEi8APgIusbf/VGUjGjXu5nRU8DjCEM WHU4vKhL99/VhKPIN8xoM4nd64Fw6AT8Jio2hQFHW1ZhAhsLZxDe2BRmmyOEdUp1th7u KuDfTgX/yUS3Vcao+srvscZfjN4uEFanBlq73GkeXVvSCv8FODgJ4DaCMFGAgBWVMZO1 3egQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=RREC1ahvRFfGyw76l4ibA9bqTupLckMQgY54O0gStrA=; b=pv4WaW5ElVEU+nyUQqwB1vfl7ygq+iMZIs0n4CSS4OoBrHiQY0Cbel3P/xgSEedEGk 96/3iva5004FW4NraGjtC7jnAQZ5Odkmz23YeblVBpNAcXbXpXexK2Acrxm/xOLeoW/w RoyjGRsyHYhHHfMuZXpfmx7iv79xTF7ATq5eACSmvHP2Kib6yyxpRyKqXqmBTOjY1B3I vm225P6WINsoL/KCyHDwmefRLRLSkdIsF2UEOpMPCyPh0VCkGLEAfR0NRKNihMKFSiVe OZTUVU5LG3yuoaLJ8mIB3zxIJgiLNAso93OUlGbOIHtjIJQ4MkcqVJ6o1GTK7FfPyUY6 M5MQ== X-Gm-Message-State: APjAAAUFRAiHeOgjuyQfj1KozXgL2wdvYMCMrWKK/k2KXP188HFNbyf3 +tbfeOD4N0+jkHMP+eIugrpEmJEI X-Received: by 2002:a63:334f:: with SMTP id z76mr3320019pgz.277.1574045254633; Sun, 17 Nov 2019 18:47:34 -0800 (PST) Received: from suzukaze.ipads-lab.se.sjtu.edu.cn ([202.120.40.82]) by smtp.gmail.com with ESMTPSA id x186sm20158760pfx.105.2019.11.17.18.47.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 17 Nov 2019 18:47:33 -0800 (PST) From: Chuhong Yuan Cc: Timur Tabi , Nicolin Chen , Xiubo Li , Fabio Estevam , Liam Girdwood , Mark Brown , Jaroslav Kysela , Takashi Iwai , alsa-devel@alsa-project.org, linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org, Chuhong Yuan Subject: [PATCH] ASoC: fsl_audmix: add missed pm_runtime_disable Date: Mon, 18 Nov 2019 10:47:21 +0800 Message-Id: <20191118024721.21400-1-hslester96@gmail.com> X-Mailer: git-send-email 2.24.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit To: unlisted-recipients:; (no To-header on input) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The driver forgets to call pm_runtime_disable in probe failure and remove. Add the missed calls to fix it. Signed-off-by: Chuhong Yuan --- sound/soc/fsl/fsl_audmix.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/sound/soc/fsl/fsl_audmix.c b/sound/soc/fsl/fsl_audmix.c index c7e4e9757dce..57cad4365e56 100644 --- a/sound/soc/fsl/fsl_audmix.c +++ b/sound/soc/fsl/fsl_audmix.c @@ -499,15 +499,20 @@ static int fsl_audmix_probe(struct platform_device *pdev) ARRAY_SIZE(fsl_audmix_dai)); if (ret) { dev_err(dev, "failed to register ASoC DAI\n"); - return ret; + goto err_disable_pm; } priv->pdev = platform_device_register_data(dev, mdrv, 0, NULL, 0); if (IS_ERR(priv->pdev)) { ret = PTR_ERR(priv->pdev); dev_err(dev, "failed to register platform %s: %d\n", mdrv, ret); + goto err_disable_pm; } + return 0; + +err_disable_pm: + pm_runtime_disable(dev); return ret; } @@ -515,6 +520,8 @@ static int fsl_audmix_remove(struct platform_device *pdev) { struct fsl_audmix *priv = dev_get_drvdata(&pdev->dev); + pm_runtime_disable(&pdev->dev); + if (priv->pdev) platform_device_unregister(priv->pdev); -- 2.24.0