Message ID | 20231204111532.3165-1-chancel.liu@nxp.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:bcd1:0:b0:403:3b70:6f57 with SMTP id r17csp2699621vqy; Mon, 4 Dec 2023 03:38:00 -0800 (PST) X-Google-Smtp-Source: AGHT+IHmW4YCBc8ex00VTbCAeOmSDe6MXS6o2JMR3YF2FvBZf724vmeBPN74oD7lyQkvCnOL5IKJ X-Received: by 2002:a17:902:d4cd:b0:1d0:965f:b003 with SMTP id o13-20020a170902d4cd00b001d0965fb003mr1286828plg.67.1701689879891; Mon, 04 Dec 2023 03:37:59 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1701689879; cv=pass; d=google.com; s=arc-20160816; b=NGLRgzYWhTKeQfb1RLGHakU0QpJZV9idRb3CcF3rD+IX0PO7HYyY5VWH+ms3nd/JJR FCrJGfAua2tQl5MdbgE1UrKxvvzHlx9DCJb3sVeSTSyJOoC+Le0Os2/4/jl/wE+MrBwn GgeP8hwQWYU5SlMOXkFA2ImcxmJbq2TejoX6FnOFItC/XRXy3Jpn6W86kVD4gj1H4x2w TYfSJDgT4ASCeK8oOfi6K04EoPf4rN9jBiB9LndE8URO9ZEW/xvb6veLWfrtV0NzoVmE ZXbMH80DOZUDa5ZmeZwEg+e1D18KcPNqUY4gu7oI6YwUr+7sGa219E+yd1oBpu2H2fCC SRrQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from :dkim-signature; bh=xsI8AmSHxDc9++mPZHuKZ+nURaI2GVzQqSoLx25NIb8=; fh=dR4VUqeU73sEFOn3gH4znPhxkYCNHL1P6f9mjYMK1FA=; b=CHEGNo0ReDyzDOk2E2pUNKhPPCc/pXaMpWvkkGA2BCcj9bmIXjDx7heKbJcekfOHDa n5xGQ9TWEoyfV/fQHykzTal3QkKUgKKI+KFvOfit3cisLWkDYP+HUztSxOXLazIgCPqH 7Wpql1c8FQwNh+i1ySXO22fTji5WJVJfIEZBNY0ctp1qW+JxcoukirJeV5Ua6qqJ9+dp Qn9mP1tQWaYvQLnpUv40yWqNbsNFveR1l+Tt+u/05Jlj0ELzz0EWmg6SdHgrQBI8njBs CNN2zOvDF10ok0yg4gnHTvVKKYldymk68wDFkiLBGyzt04MRHTFeHc5UdWuftD9Cl09v 7LoA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@nxp.com header.s=selector2 header.b=eVIm0y3N; arc=pass (i=1 spf=pass spfdomain=nxp.com dkim=pass dkdomain=nxp.com dmarc=pass fromdomain=nxp.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from pete.vger.email (pete.vger.email. [2620:137:e000::3:6]) by mx.google.com with ESMTPS id a2-20020a170902ecc200b001c59b6ed118si7678053plh.157.2023.12.04.03.37.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 04 Dec 2023 03:37:59 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) client-ip=2620:137:e000::3:6; Authentication-Results: mx.google.com; dkim=pass header.i=@nxp.com header.s=selector2 header.b=eVIm0y3N; arc=pass (i=1 spf=pass spfdomain=nxp.com dkim=pass dkdomain=nxp.com dmarc=pass fromdomain=nxp.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by pete.vger.email (Postfix) with ESMTP id E6CF2804E333; Mon, 4 Dec 2023 03:37:55 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232704AbjLDLhp (ORCPT <rfc822;chrisfriedt@gmail.com> + 99 others); Mon, 4 Dec 2023 06:37:45 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47346 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232458AbjLDLhn (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Mon, 4 Dec 2023 06:37:43 -0500 Received: from EUR05-AM6-obe.outbound.protection.outlook.com (mail-am6eur05on2068.outbound.protection.outlook.com [40.107.22.68]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DECAEB0; Mon, 4 Dec 2023 03:37:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=XjutKVzrYO/ptM0lLPmwyndd1ndrmY0Jidl5Cepo+mpC3xEfepyQ8HYmQo4WUUUgrSU87DRaPEdbpAiNwIlT+Jz8mkytitWo9k0MuGCQ/UPumAa7L3yxew2FA38m/prhJhDAopxeOONeAtxzjdyEEBr094N7Ax9cyAPLsL9rV6FPPddbUh5Jd7e0M/sDBwL6M5jBgsOeY+nyaTm1x+eg+E0K4SY8R4FwTDE+sHzF4fAuOiRZ5ukHLqgf5nava6fOABv648JrVN6nso1F8oMdKK9iTsYIG2ijmfLQVAHwdMWEMZSkQtMUk5t27yV2o/m895IkvSLRAWSTInOBqz9hNw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=xsI8AmSHxDc9++mPZHuKZ+nURaI2GVzQqSoLx25NIb8=; b=JO4K5FXGuVc3mrHMYN2uvIJ0l8b50mdWKgLcqKF2YIiy3npY4x/J05izRA6HKxP0Pqo+KAaT47scMQibhrwiUCAmXMbcoomXqkzwvhSOERBY9E2L6orSvGeS15YHi3Vefnv5mLQdvzskOPJp461Og1kSZU9G/t2NajhjB8y0Df9cisQ3iuYNlTAdFkJM5vxMOA3z7Z8/tTH+/IPdSaZKicJqhVvm2cexiF9yvP5c4VxYbKhPu8s5Q4EkchN1VEjsffD+yOl6KgBygs8m6lB+wxGiZAZdmCmwBdXEh6nc2Q7mDfJq6VxG4JluQ/PaHiXK0iPi4TBjO1ROukOXkOUgXw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=xsI8AmSHxDc9++mPZHuKZ+nURaI2GVzQqSoLx25NIb8=; b=eVIm0y3N8lbJ7NzOBxO1mBnfB539S+Qim0EzjpeR4b375ynuKbsRFQGtAGeTPy4yiGMHBjCAoObDYA33nt0SksIhuM0tsxGT+PaAOLy457fIOpynFWXBp40utnLPjEnotgn6ekCMQMFcVNhdlbKK7KjYvUqzY4cwCQ81C8yC2KM= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from DB9PR04MB9498.eurprd04.prod.outlook.com (2603:10a6:10:360::21) by DB9PR04MB8089.eurprd04.prod.outlook.com (2603:10a6:10:247::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7068.22; Mon, 4 Dec 2023 11:37:45 +0000 Received: from DB9PR04MB9498.eurprd04.prod.outlook.com ([fe80::dffc:1d:4398:7768]) by DB9PR04MB9498.eurprd04.prod.outlook.com ([fe80::dffc:1d:4398:7768%6]) with mapi id 15.20.7068.021; Mon, 4 Dec 2023 11:37:45 +0000 From: Chancel Liu <chancel.liu@nxp.com> To: lgirdwood@gmail.com, broonie@kernel.org, perex@perex.cz, tiwai@suse.com, linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Chancel Liu <chancel.liu@nxp.com> Subject: [PATCH] ASoC: soc-pcm.c: Complete the active count for components without DAIs Date: Mon, 4 Dec 2023 19:15:32 +0800 Message-Id: <20231204111532.3165-1-chancel.liu@nxp.com> X-Mailer: git-send-email 2.17.1 Content-Type: text/plain X-ClientProxiedBy: AM0PR01CA0165.eurprd01.prod.exchangelabs.com (2603:10a6:208:aa::34) To DB9PR04MB9498.eurprd04.prod.outlook.com (2603:10a6:10:360::21) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DB9PR04MB9498:EE_|DB9PR04MB8089:EE_ X-MS-Office365-Filtering-Correlation-Id: 4851a649-db44-4b1c-14d4-08dbf4bd6f0d X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 1dc7/fZk17yOCpqasuc3ZRcZdjCk+EwXpL9EwIc350++TMyJ3GdMbOnaXPgF+/wl0zHxAZaWFEHmNUES6ho/XwOfz1WbP97uJNVcOO6kcPD950AnYx7pgxTyiC3HX/V4otnfkLDUs05xu2N49B/9QVJTQqGRr7SYKv3CZ5ej0AToRMkLZpJPzcoLDlwk+6o+j2HWvSQ6UBTCKRBKLQJOxEmPSH9rQdnSoOx4g9J7n1LMTwfo1Kt2LblOHvHJaneCgEygiaF2kCcOuPt4L1Dh/g+jSLrsiY1QidHkXbMN45FvqHPSI9TYoM4cfkZO90nvH8J0OW1Es1Phf+rRHlLSYOCBVSwgnBBDoZdVuiI7qt8B2IHVAthOf4YoQZVuugZnJlGgAmT4izHMoAEgE5bexxdkqs94fXPd/vK55I9rSOvQMH0hcmyzgqyDnlryi1fDXTFpyF896x2tcaOIYgyxGuvlE/BW0q0OmuIVjQB6tjDXWiDgfRaRDv/FnycpJkJH0r+znoXt3JWR5hKmGxZ93thlKUReWHKYHOd9AXPv5bEeKof5V2DQnJPPIG0dw/15JNl9Ao+WprQDiIm/wYns7IPOTCbAaRxXuNVcV9cuMAOCkm5AIWE29hUkttr2um6E X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DB9PR04MB9498.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(39860400002)(366004)(376002)(396003)(346002)(136003)(230922051799003)(186009)(451199024)(64100799003)(1800799012)(36756003)(41300700001)(38350700005)(5660300002)(2906002)(44832011)(38100700002)(478600001)(6666004)(6486002)(6512007)(52116002)(6506007)(2616005)(1076003)(26005)(8936002)(8676002)(4326008)(66556008)(66476007)(66946007)(83380400001)(86362001)(316002);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: FcDpz8NkdOEmb1CWBSBGU7YmXgCo2Y3vyGu9jVGrO3qVoPnMP/fU2c0j3rj8KrLzY3bLI8ADLrZNmDpWJBzrBOQTVuGriqdqQa8zbtO+/r3Sa2RM87jp4q5I10KpOCK8dDeGaLUIO14rUlX9mHXpdh9XVvCMNTVBZ1mivV2poNPWJuZhUmSPXZOZw6QF7gjii0cU4HOmjzJ6RxWyRzL0jqdLnfsqM+le9NICaaygMitpQz+6bW3FAK45cG041CW3ZjZ+BGFZpEZKs0Dlw4aF+Gzb2LciZkhWgF0z6xLlhOCeArIb+61naB57TlKYjJ4KKZ6f0sf5ZWwsX0j7h8IR86CILmWQ4J3bbV8LEF/+YS+Y9iRpLULPUR0WWodDIneU+Nacmx//ymZGQ1YKmO2Zzahcc6plHAqqH16tv2BwZ0HAmxPapOGKvQL2yjMB9WBirX0ygDeGy9PaCdpN5beOVygFk93bDcQPZCtFMQhoHrMqGD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StPWrSWmw5BV2AZ3Ai1Sq8N8xvJJOIC4uc2uI5b X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 4851a649-db44-4b1c-14d4-08dbf4bd6f0d X-MS-Exchange-CrossTenant-AuthSource: DB9PR04MB9498.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Dec 2023 11:37:45.6722 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: oq6mKeRDkjHhR32SNRfVfcM+PeKF4Jo6BmzI8/wtV4njuOCu2r8sU7H6ru8o1PuMTHanosvy56H/ZF1Qm2bQeA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB9PR04MB8089 X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.vger.email Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (pete.vger.email [0.0.0.0]); Mon, 04 Dec 2023 03:37:56 -0800 (PST) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1784351167634642079 X-GMAIL-MSGID: 1784351167634642079 |
Series |
ASoC: soc-pcm.c: Complete the active count for components without DAIs
|
|
Commit Message
Chancel Liu
Dec. 4, 2023, 11:15 a.m. UTC
Some components like platforms don't have DAIs. If the active count of
these components is ignored pinctrl may be wrongly selected between
default and sleep state. So need to increment or decrement the active
count for components without DAIs to avoid it.
Signed-off-by: Chancel Liu <chancel.liu@nxp.com>
---
sound/soc/soc-pcm.c | 8 ++++++++
1 file changed, 8 insertions(+)
Comments
On Mon, 04 Dec 2023 19:15:32 +0800, Chancel Liu wrote: > Some components like platforms don't have DAIs. If the active count of > these components is ignored pinctrl may be wrongly selected between > default and sleep state. So need to increment or decrement the active > count for components without DAIs to avoid it. > > Applied to https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next Thanks! [1/1] ASoC: soc-pcm.c: Complete the active count for components without DAIs commit: 8f039360897bdd2f1f455b46a7f504b677405913 All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted. You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed. If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced. Please add any relevant lists and maintainers to the CCs when replying to this mail. Thanks, Mark
diff --git a/sound/soc/soc-pcm.c b/sound/soc/soc-pcm.c index efde4203bbf7..7dd4d41f680a 100644 --- a/sound/soc/soc-pcm.c +++ b/sound/soc/soc-pcm.c @@ -292,6 +292,7 @@ static void dpcm_set_be_update_state(struct snd_soc_pcm_runtime *be, void snd_soc_runtime_action(struct snd_soc_pcm_runtime *rtd, int stream, int action) { + struct snd_soc_component *component; struct snd_soc_dai *dai; int i; @@ -299,6 +300,13 @@ void snd_soc_runtime_action(struct snd_soc_pcm_runtime *rtd, for_each_rtd_dais(rtd, i, dai) snd_soc_dai_action(dai, stream, action); + + /* Increments/Decrements the active count for components without DAIs */ + for_each_rtd_components(rtd, i, component) { + if (component->num_dai) + continue; + component->active += action; + } } EXPORT_SYMBOL_GPL(snd_soc_runtime_action);