From patchwork Thu Jun 19 06:32:05 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jarkko Nikula X-Patchwork-Id: 4380741 Return-Path: X-Original-To: patchwork-alsa-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 20E409F26E for ; Thu, 19 Jun 2014 06:32:53 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 552712038D for ; Thu, 19 Jun 2014 06:32:52 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.kernel.org (Postfix) with ESMTP id A88662021F for ; Thu, 19 Jun 2014 06:32:50 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id 416D8265253; Thu, 19 Jun 2014 08:32:49 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 Received: from alsa0.perex.cz (localhost [IPv6:::1]) by alsa0.perex.cz (Postfix) with ESMTP id 6D0E4265272; Thu, 19 Jun 2014 08:32:40 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa0.perex.cz (Postfix, from userid 1000) id E176226525F; Thu, 19 Jun 2014 08:32:34 +0200 (CEST) Received: from mga03.intel.com (mga03.intel.com [143.182.124.21]) by alsa0.perex.cz (Postfix) with ESMTP id 64D772651CF for ; Thu, 19 Jun 2014 08:32:26 +0200 (CEST) Received: from azsmga001.ch.intel.com ([10.2.17.19]) by azsmga101.ch.intel.com with ESMTP; 18 Jun 2014 23:32:15 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.01,505,1400050800"; d="scan'208";a="447360958" Received: from mylly.fi.intel.com (HELO mylly.fi.intel.com.) ([10.237.72.57]) by azsmga001.ch.intel.com with ESMTP; 18 Jun 2014 23:32:13 -0700 From: Jarkko Nikula To: alsa-devel@alsa-project.org Date: Thu, 19 Jun 2014 09:32:05 +0300 Message-Id: <1403159525-4352-1-git-send-email-jarkko.nikula@linux.intel.com> X-Mailer: git-send-email 2.0.0 Cc: Mark Brown , Jarkko Nikula , Liam Girdwood , Stable Subject: [alsa-devel] [PATCH] ASoC: max98090: Fix missing free_irq X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP max98090.c doesn't free the threaded interrupt it requests. This causes an oops when doing "cat /proc/interrupts" after snd-soc-max98090.ko is unloaded. Fix this by requesting the interrupt by using devm_request_threaded_irq(). Signed-off-by: Jarkko Nikula Cc: Stable # 3.10+ --- This issue has been in max98090.c since v3.8 commit 685e42154dcf ("ASoC: Replace max98090 Device Driver"). However this patch applies only after v3.10 which has 3d15aacbb802 ("ASoC: max98090: request IRQF_ONESHOT interrupt"). I'm not sure is there need to go before that since first upstream max98090 user was introduced in a v3.14 commit 7637af2e17f1 ("ASoC: tegra: add tegra+MAX98090 machine driver"). However I'm aware there is an out-of-tree 3.10 user. --- sound/soc/codecs/max98090.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/codecs/max98090.c b/sound/soc/codecs/max98090.c index f5fccc7a8e89..d97f1ce7ff7d 100644 --- a/sound/soc/codecs/max98090.c +++ b/sound/soc/codecs/max98090.c @@ -2284,7 +2284,7 @@ static int max98090_probe(struct snd_soc_codec *codec) /* Register for interrupts */ dev_dbg(codec->dev, "irq = %d\n", max98090->irq); - ret = request_threaded_irq(max98090->irq, NULL, + ret = devm_request_threaded_irq(codec->dev, max98090->irq, NULL, max98090_interrupt, IRQF_TRIGGER_FALLING | IRQF_ONESHOT, "max98090_interrupt", codec); if (ret < 0) {