From patchwork Sat Apr 11 08:47:57 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lars-Peter Clausen X-Patchwork-Id: 6201161 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.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 8EFCD9F1C4 for ; Sat, 11 Apr 2015 08:48:14 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id C5B76202FF for ; Sat, 11 Apr 2015 08:48:13 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.kernel.org (Postfix) with ESMTP id D9DFF202AE for ; Sat, 11 Apr 2015 08:48:12 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id D5DA92614D3; Sat, 11 Apr 2015 10:48:10 +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 B693C2612D3; Sat, 11 Apr 2015 10:48:08 +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 720DE261493; Sat, 11 Apr 2015 10:48:07 +0200 (CEST) Received: from smtp-out-051.synserver.de (smtp-out-051.synserver.de [212.40.185.51]) by alsa0.perex.cz (Postfix) with ESMTP id 41BC5260621 for ; Sat, 11 Apr 2015 10:48:00 +0200 (CEST) Received: (qmail 3766 invoked by uid 0); 11 Apr 2015 08:47:59 -0000 X-SynServer-TrustedSrc: 1 X-SynServer-AuthUser: lars@metafoo.de X-SynServer-PPID: 3694 Received: from ppp-88-217-83-222.dynamic.mnet-online.de (HELO lars-adi-laptop.fritz.box) [88.217.83.222] by 217.119.54.87 with SMTP; 11 Apr 2015 08:47:59 -0000 From: Lars-Peter Clausen To: Mark Brown , Liam Girdwood Date: Sat, 11 Apr 2015 10:47:57 +0200 Message-Id: <1428742078-9704-1-git-send-email-lars@metafoo.de> X-Mailer: git-send-email 1.8.0 Cc: Peter Ujfalusi , alsa-devel@alsa-project.org, Lars-Peter Clausen , Jarkko Nikula Subject: [alsa-devel] [PATCH 1/2] ASoC: n810: Consistently pass the card DAPM context to n810_ext_control() 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 Some callers of n810_ext_control() pass the card DAPM context and some pass the CODEC DAPM context. Given that some of the widgets that are accessed in the function are in the card's context, always passing it is the obvious choice. Signed-off-by: Lars-Peter Clausen --- sound/soc/omap/n810.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sound/soc/omap/n810.c b/sound/soc/omap/n810.c index 5d7f9ce..617eae3 100644 --- a/sound/soc/omap/n810.c +++ b/sound/soc/omap/n810.c @@ -98,12 +98,11 @@ static int n810_startup(struct snd_pcm_substream *substream) { struct snd_pcm_runtime *runtime = substream->runtime; struct snd_soc_pcm_runtime *rtd = substream->private_data; - struct snd_soc_codec *codec = rtd->codec; snd_pcm_hw_constraint_minmax(runtime, SNDRV_PCM_HW_PARAM_CHANNELS, 2, 2); - n810_ext_control(&codec->dapm); + n810_ext_control(&rtd->card->dapm); return clk_prepare_enable(sys_clkout2); }