From patchwork Wed Feb 23 07:19:30 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Mukunda,Vijendar" X-Patchwork-Id: 12756500 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 59DD2C433EF for ; Wed, 23 Feb 2022 07:24:40 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id E54701919; Wed, 23 Feb 2022 08:23:48 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz E54701919 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1645601079; bh=Gem/M2FGIZyGqDE1xxac+svTPzVL65zM3KDfzRpYglU=; h=From:To:Subject:Date:Cc:List-Id:List-Unsubscribe:List-Archive: List-Post:List-Help:List-Subscribe:From; b=PtgjSE0KYh202Ojcppl1LRjFBjYLpyT6BcRtEYDEVgr7wGn9X1UeyyZbDC3z7Rs9r MkQlpyWqaZXoUvUqIlxOOmzFX0vnfpRUd2m5pT0Ea0EafwpvAGJlaug1lUnhcUFgOh LRZk6j0d1cCGt0qN4SOzuG03PrUU6uJgRlVoBbeE= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 8311FF800B6; Wed, 23 Feb 2022 08:23:48 +0100 (CET) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 49266F80237; Wed, 23 Feb 2022 08:23:46 +0100 (CET) Received: from NAM11-DM6-obe.outbound.protection.outlook.com (mail-dm6nam11on2060d.outbound.protection.outlook.com [IPv6:2a01:111:f400:7eaa::60d]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 54F4CF800F5 for ; Wed, 23 Feb 2022 08:23:40 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 54F4CF800F5 Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key) header.d=amd.com header.i=@amd.com header.b="btVK9KS5" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=byYcToTQkqYE2uvYxOScd0puLQZlLV9x9rkmFU5YgaMJi25/iVRlGOrFNCmBpNglo0XcJQ7PdTGO/IF8utnmqd9rOn768KzOtkIC1eHE/z6UhNUmc1UhMo/SBKWUs+jQeY/0AcOpEzsoWy9zwZUQjC0lr9ZSE5oeSsdOjlpJkwLW6V4mYXe09M0k89fkKHkuiiWAYLxhuqOnnotX2q+3OCmQdwxcbpG0Cs8MLJ3mcsbdAt2bCh3IOJO3nsbpumqnPQk0o0HbFtWvUgAMfjdLhlb8iLBGzxhMt5F5sbzXfuJuNkc3QZLtItL1Knx2tB/95Ory7g6uxbPegBD0JppStg== 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=fSLPIoyCoYNuCv031q6KvtizgGgQUbbVBnrTpN1trrA=; b=a/pyGLNScTMs1QTzIAbqZ2ZvBJzt54NYyrUaasplavgEkGLi6KwfEAdMsqrmSuBR5DeKZxoowaTm70rYu71n09b5Lvfk1FZ9Tx2HcnQJ9CmZbW0/8FPs+V0rVSRS30hV4PcWxL+7aa9K0WirK5RZ3/KUR0nxE5vvp18U9Aw7vB5KvcKLgmfu6OKkP2qknpMXo9kcnn1PNwHqgYNkfo2S/RrfUobbTYaTgVHqhHGjdIGAmC6hSSEanNQGfXxJVadvQGio+Z+qQD1V+HznV1o6FHLcyn2n+b5sHi0XzbT8tU7BbgMbYoO9MfuvakAZLtqkCgV8j30Q6g/6qPP6YVWh+A== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=fSLPIoyCoYNuCv031q6KvtizgGgQUbbVBnrTpN1trrA=; b=btVK9KS5D6EFc+sp0Ctw3i2cKNsOeNf0KzlWUfn55kyrrf5xNiNrXH5uWcX/QPWs6LYYNEDszhMDwqbJa9boY0MPMkClWC4/6iAr7Pv5+q2yxj+CS0jowkm3s61Ond/h2S/m61PqXNzMVqEN4gydLDDHjNJKIxkeFV5AMqcAoig= Received: from BN9PR03CA0507.namprd03.prod.outlook.com (2603:10b6:408:130::32) by MW2PR12MB2348.namprd12.prod.outlook.com (2603:10b6:907:e::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4995.16; Wed, 23 Feb 2022 07:23:35 +0000 Received: from BN8NAM11FT039.eop-nam11.prod.protection.outlook.com (2603:10b6:408:130:cafe::c5) by BN9PR03CA0507.outlook.office365.com (2603:10b6:408:130::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5017.21 via Frontend Transport; Wed, 23 Feb 2022 07:23:34 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB03.amd.com; Received: from SATLEXMB03.amd.com (165.204.84.17) by BN8NAM11FT039.mail.protection.outlook.com (10.13.177.169) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5017.22 via Frontend Transport; Wed, 23 Feb 2022 07:23:34 +0000 Received: from SATLEXMB05.amd.com (10.181.40.146) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.18; Wed, 23 Feb 2022 01:23:34 -0600 Received: from SATLEXMB04.amd.com (10.181.40.145) by SATLEXMB05.amd.com (10.181.40.146) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.18; Wed, 23 Feb 2022 01:23:33 -0600 Received: from LinuxHost.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server id 15.1.2375.18 via Frontend Transport; Wed, 23 Feb 2022 01:23:30 -0600 From: Vijendar Mukunda To: , Subject: [PATCH 1/9] ASoC: amd: vg: fix for pm resume callback sequence Date: Wed, 23 Feb 2022 12:49:30 +0530 Message-ID: <20220223071959.13539-1-Vijendar.Mukunda@amd.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 97ec166d-e9fe-48df-65f6-08d9f69d66f3 X-MS-TrafficTypeDiagnostic: MW2PR12MB2348:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: qjoTapz/IusMGuYJqufDOw4N2Dgzt91zvtht8NvvNo5waYxd4yxU0xR2wLXUYK6rdV8eq+6eE//dBQUzYcgcQAYdBBn3/L2vIMJcktToIj+vMn9X1YrjaN4mPuAvgP0o77eIedcGRaBEPCGJQFUJqShGhiQ/NeFkcwVJFqb3DWhDDOvAB84zSraNb2KTd63An8UYxqG74smggdbLmfJxKZx1Hy7edGdlouRCHUq+AzCIAOJG73H5dohPm3Ot+rJMnfLnm8cxCju6u1Pgx1jQHHL/hqj74cqOvxcd/tGcyiXfeXGoWEe+XyZsYHZ3fho5vljkG2xefqwp05PpKkQsP7QH79APGvnsFgGh8ucIi79RBaoedFD8IuAh+8bAJt2ckTIM7ImuqZWJlpy0aV+lhvkSD/51VxGdkQcOV8fldl3WySFcH0OqUw4qtjxm3wzRUz/2N0ZoYICIq+h50HK1CpLVWFvxww5ABGk2IEhuN+XZKMExqGjcBaTI+wNQjMgYYDfKHUJgJfvRPz8h+bFuBele4zq51sSibG7tqhPxCpLDFCHMrHvDgkaGCMz1yGAZBk+dxMXgmjxIsXAMglpSR6Sl4Mrj/8DiyUnRwK20mLwiyb+uBeJ8DMae87DQxyS+w3f6+6qIoNaNFEV6xkfjzDltJh9LEdqAC2gefblIwWaNTVunL74NJk/PguqbYFL6dGWDbDsQpmC0z0Oz7FCfWg== X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB03.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230001)(4636009)(46966006)(36840700001)(40470700004)(8936002)(2616005)(336012)(7696005)(186003)(26005)(508600001)(356005)(86362001)(40460700003)(1076003)(70586007)(70206006)(4326008)(8676002)(81166007)(5660300002)(82310400004)(36860700001)(47076005)(54906003)(83380400001)(316002)(36756003)(110136005)(2906002)(426003)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Feb 2022 07:23:34.6536 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 97ec166d-e9fe-48df-65f6-08d9f69d66f3 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB03.amd.com] X-MS-Exchange-CrossTenant-AuthSource: BN8NAM11FT039.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: MW2PR12MB2348 Cc: Pierre-Louis Bossart , Sunil-kumar.Dommati@amd.com, wtli@nuvoton.com, open list , Takashi Iwai , Liam Girdwood , Vijendar Mukunda , Alexander.Deucher@amd.com, krisman@collabora.com X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 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: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" The previous condition is used to cross check only the active stream status for I2S HS instance playback and capture use cases. Modified logic to invoke sequence for two i2s controller instances. Signed-off-by: Vijendar Mukunda Reported-by: kernel test robot Reported-by: kernel test robot --- sound/soc/amd/vangogh/acp5x-pcm-dma.c | 62 ++++++++++++++------------- 1 file changed, 32 insertions(+), 30 deletions(-) diff --git a/sound/soc/amd/vangogh/acp5x-pcm-dma.c b/sound/soc/amd/vangogh/acp5x-pcm-dma.c index f10de38976cb..17853d8d56d3 100644 --- a/sound/soc/amd/vangogh/acp5x-pcm-dma.c +++ b/sound/soc/amd/vangogh/acp5x-pcm-dma.c @@ -426,6 +426,7 @@ static int acp5x_audio_remove(struct platform_device *pdev) static int __maybe_unused acp5x_pcm_resume(struct device *dev) { struct i2s_dev_data *adata; + struct i2s_stream_instance *rtd; u32 val, reg_val, frmt_val; reg_val = 0; @@ -433,44 +434,45 @@ static int __maybe_unused acp5x_pcm_resume(struct device *dev) adata = dev_get_drvdata(dev); if (adata->play_stream && adata->play_stream->runtime) { - struct i2s_stream_instance *rtd = - adata->play_stream->runtime->private_data; + rtd = adata->play_stream->runtime->private_data; config_acp5x_dma(rtd, SNDRV_PCM_STREAM_PLAYBACK); - switch (rtd->i2s_instance) { - case I2S_HS_INSTANCE: - reg_val = ACP_HSTDM_ITER; - frmt_val = ACP_HSTDM_TXFRMT; - break; - case I2S_SP_INSTANCE: - default: - reg_val = ACP_I2STDM_ITER; - frmt_val = ACP_I2STDM_TXFRMT; + acp_writel((rtd->xfer_resolution << 3), rtd->acp5x_base + ACP_HSTDM_ITER); + if (adata->tdm_mode == TDM_ENABLE) { + acp_writel(adata->tdm_fmt, adata->acp5x_base + ACP_HSTDM_TXFRMT); + val = acp_readl(adata->acp5x_base + ACP_HSTDM_ITER); + acp_writel(val | 0x2, adata->acp5x_base + ACP_HSTDM_ITER); + } + } + if (adata->i2ssp_play_stream && adata->i2ssp_play_stream->runtime) { + rtd = adata->i2ssp_play_stream->runtime->private_data; + config_acp5x_dma(rtd, SNDRV_PCM_STREAM_PLAYBACK); + acp_writel((rtd->xfer_resolution << 3), rtd->acp5x_base + ACP_I2STDM_ITER); + if (adata->tdm_mode == TDM_ENABLE) { + acp_writel(adata->tdm_fmt, adata->acp5x_base + ACP_I2STDM_TXFRMT); + val = acp_readl(adata->acp5x_base + ACP_I2STDM_ITER); + acp_writel(val | 0x2, adata->acp5x_base + ACP_I2STDM_ITER); } - acp_writel((rtd->xfer_resolution << 3), - rtd->acp5x_base + reg_val); } if (adata->capture_stream && adata->capture_stream->runtime) { - struct i2s_stream_instance *rtd = - adata->capture_stream->runtime->private_data; + rtd = adata->capture_stream->runtime->private_data; config_acp5x_dma(rtd, SNDRV_PCM_STREAM_CAPTURE); - switch (rtd->i2s_instance) { - case I2S_HS_INSTANCE: - reg_val = ACP_HSTDM_IRER; - frmt_val = ACP_HSTDM_RXFRMT; - break; - case I2S_SP_INSTANCE: - default: - reg_val = ACP_I2STDM_IRER; - frmt_val = ACP_I2STDM_RXFRMT; + acp_writel((rtd->xfer_resolution << 3), rtd->acp5x_base + ACP_HSTDM_IRER); + if (adata->tdm_mode == TDM_ENABLE) { + acp_writel(adata->tdm_fmt, adata->acp5x_base + ACP_HSTDM_RXFRMT); + val = acp_readl(adata->acp5x_base + ACP_HSTDM_IRER); + acp_writel(val | 0x2, adata->acp5x_base + ACP_HSTDM_IRER); } - acp_writel((rtd->xfer_resolution << 3), - rtd->acp5x_base + reg_val); } - if (adata->tdm_mode == TDM_ENABLE) { - acp_writel(adata->tdm_fmt, adata->acp5x_base + frmt_val); - val = acp_readl(adata->acp5x_base + reg_val); - acp_writel(val | 0x2, adata->acp5x_base + reg_val); + if (adata->i2ssp_capture_stream && adata->i2ssp_capture_stream->runtime) { + rtd = adata->i2ssp_capture_stream->runtime->private_data; + config_acp5x_dma(rtd, SNDRV_PCM_STREAM_CAPTURE); + acp_writel((rtd->xfer_resolution << 3), rtd->acp5x_base + ACP_I2STDM_IRER); + if (adata->tdm_mode == TDM_ENABLE) { + acp_writel(adata->tdm_fmt, adata->acp5x_base + ACP_I2STDM_RXFRMT); + val = acp_readl(adata->acp5x_base + ACP_I2STDM_IRER); + acp_writel(val | 0x2, adata->acp5x_base + ACP_I2STDM_IRER); + } } acp_writel(1, adata->acp5x_base + ACP_EXTERNAL_INTR_ENB); return 0; From patchwork Wed Feb 23 07:19:31 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Mukunda,Vijendar" X-Patchwork-Id: 12756501 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id D528EC433EF for ; Wed, 23 Feb 2022 07:25:17 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 008FD193A; Wed, 23 Feb 2022 08:24:25 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 008FD193A DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1645601116; bh=qXvDvVwBCHbweKAieI2WcxjrWKpqdGwTZ1CFc5f1hhs=; h=From:To:Subject:Date:In-Reply-To:References:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=l2fyW9RP3qaiuGGNY7iw9FOy6wjFWAHmgdvlbG6y5O6m01NOQF5nkHsAzKPBWNLBE 9CV1IMqCeatWhzzB9Umtx/F6EkY6eD3Fxa096sxYubsAhOhLa9sQ432R9tA3z9K8Ic MVJfEfJ8dl0JGtRqQeIEIi5dGqwK8MMo53ZRwB0A= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 94D5FF8025D; Wed, 23 Feb 2022 08:24:25 +0100 (CET) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 59C4CF802E3; Wed, 23 Feb 2022 08:24:22 +0100 (CET) Received: from NAM10-BN7-obe.outbound.protection.outlook.com (mail-bn7nam10on2060b.outbound.protection.outlook.com [IPv6:2a01:111:f400:7e8a::60b]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 3D547F800F5 for ; Wed, 23 Feb 2022 08:24:16 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 3D547F800F5 Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key) header.d=amd.com header.i=@amd.com header.b="ylc/ZYqq" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=m87F0rRBu8WazUGIclFVSA+Y9bmucxiyBtLWCszinKiGc/8xGPljncisQt0S6y4KFh05ls0sL8aMTEVGmSTfBsza9h36L3dIbAutkslHVYF32OvYSyUmJCOw67/QSl+iI9jFbuV4bTM38OuK/pbcheKqC9wgyWGOEYBHshkDq+KfhAwKhJUiM4/m2iqC3GxoaChSvoxkqrCKzeD0gsJd5xTunzZkTU9LFSAtjzb+Gxg+M1oUDQX+Hx7iJkYUaisAhnIR/EgAfglzNzhVn7BMejYAyBnJmyUN9OW1yTOOu6ZOy6nIyoMVDlld0j55gGkGzDSqholzws0IhzErveNXvw== 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=rNRvlWPfQIdipH1qhAW8xKtQn594+8w0iwVdP6o9t1c=; b=Fvp+RKBlZAM3Oi/4ijMbLfdMfJgThD1rvyKpQ7L3bXZ+DrMjmk5I6X6xlDr/fAvWwvvUsFYQa8ZiWulxzBwpY48dBkIF2XczrJuL/6N8cGAJJbLLfunoD632rMeihEo12q35RcY79N8AamZvBHMlhtMFjuQZypq4Pp6yJXJ/hZmQpJuzJEiJ44JEYF1mvy/d4683PsUF3Q4R1/OwglO4mSveGsiQj5gxR6kv0rrG9sEpmufG1kvaiMAAR4FBmrRdMMxAG78bvm1LbnIWelUUGxfDK+4OBs/uKSBFxMaz/3I4RkSfjI3L9s0kr/r4slyyUJuM6+fbRqPXk9chOVxf6g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=rNRvlWPfQIdipH1qhAW8xKtQn594+8w0iwVdP6o9t1c=; b=ylc/ZYqqsehnN5wbPHcdqWyTMi3pXQQ6OZ7XIc6tQhvcVkdknr2+F1v+5wh4MhUyEpyaR3C4HKPB/JJ34ArKsxR1OmzNNxsBIUZkqamO+X5DtknjwWTt00QXTEVPlqkwY3t4B1yDYqGpzFovFExmGVlvCj/cTk6AUVWx3GdGhW8= Received: from BN6PR14CA0031.namprd14.prod.outlook.com (2603:10b6:404:13f::17) by DM6PR12MB3356.namprd12.prod.outlook.com (2603:10b6:5:38::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4995.16; Wed, 23 Feb 2022 07:24:11 +0000 Received: from BN8NAM11FT047.eop-nam11.prod.protection.outlook.com (2603:10b6:404:13f:cafe::3a) by BN6PR14CA0031.outlook.office365.com (2603:10b6:404:13f::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5017.23 via Frontend Transport; Wed, 23 Feb 2022 07:24:11 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB03.amd.com; Received: from SATLEXMB03.amd.com (165.204.84.17) by BN8NAM11FT047.mail.protection.outlook.com (10.13.177.220) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5017.22 via Frontend Transport; Wed, 23 Feb 2022 07:24:11 +0000 Received: from SATLEXMB07.amd.com (10.181.41.45) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.18; Wed, 23 Feb 2022 01:23:45 -0600 Received: from SATLEXMB04.amd.com (10.181.40.145) by SATLEXMB07.amd.com (10.181.41.45) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.18; Tue, 22 Feb 2022 23:23:45 -0800 Received: from LinuxHost.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server id 15.1.2375.18 via Frontend Transport; Wed, 23 Feb 2022 01:23:41 -0600 From: Vijendar Mukunda To: , Subject: [PATCH 2/9] ASoC: amd: vangogh: refactor i2s master mode clock sequence code Date: Wed, 23 Feb 2022 12:49:31 +0530 Message-ID: <20220223071959.13539-2-Vijendar.Mukunda@amd.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220223071959.13539-1-Vijendar.Mukunda@amd.com> References: <20220223071959.13539-1-Vijendar.Mukunda@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 3beeee4e-93a3-4b37-a62a-08d9f69d7cdd X-MS-TrafficTypeDiagnostic: DM6PR12MB3356:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: uPEFwL5KBLrnjxXKgcd22ZTmF85zntG/PrcJDsE5xpPikq7Vwn9iQdhbC7ZfoIt1BbKFS3GJiYZY2us9AB7s/9wGetTx3F1ECzFaH22vl4f123XCf2/yNTJM9pMubYesK2MhE2QF28mPApUk5ng7VKIYLBCemaPxtyZG7+VBncHzmOMMqKlfyCogmTZKh+gttolUJYA/WSrUrrXBBeJqDqYOPTTThntJKMZADaNTqCpSI7NzZ/QL62oED58PvNhOXT2/ExIipe1M+wBqL7x6t/ppqgEzL5OUtwT9i3zhgPpepMVABRC1twI48nK+M9KKoxaHL9k+rIm0OzI2CvVCdnt6qxE0/LVknKcnmzFSY8vsuHlHtRuYfz0P27xfgkN3MuVcYwydPeJnB6E+jLRtuIYMgjyjTW2tTOPNhC6MNxZaL2up2Z+S4auwam5SobckUqN5r9kx/lLFPzRc0xCEgx9OH8b2scbbbCQEjvI1w0Ol3+8gwBTVc0m3hG9syx+EyHcMBbh1pqj311vVZoYLBO2wYz75oS7b0T9qf5RvKtqSsjSfbh6qgJsMIwk6X8YtPLF8HVJ8vko2b7g9D+MHx+Cs5M1xE5BYHQHxNSE7IB1nZ4jQSAFzh04pTr5UKFC4T4JpGBOuXlYSxnTWvnLXm/HHY+TXWnR2SyxboIk2+4vKZhD0frXjE+NUvJTYAG9SV35J1B5//gAnBc1dCmk58Q== X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB03.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230001)(4636009)(46966006)(36840700001)(40470700004)(2616005)(1076003)(5660300002)(426003)(316002)(86362001)(336012)(36860700001)(54906003)(7416002)(40460700003)(26005)(36756003)(83380400001)(186003)(110136005)(47076005)(356005)(70206006)(8676002)(81166007)(70586007)(2906002)(8936002)(6666004)(4326008)(508600001)(82310400004)(7696005)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Feb 2022 07:24:11.4210 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 3beeee4e-93a3-4b37-a62a-08d9f69d7cdd X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB03.amd.com] X-MS-Exchange-CrossTenant-AuthSource: BN8NAM11FT047.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR12MB3356 Cc: Pierre-Louis Bossart , Sunil-kumar.Dommati@amd.com, wtli@nuvoton.com, open list , Takashi Iwai , Liam Girdwood , Rikard Falkeborn , Vijendar Mukunda , Alexander.Deucher@amd.com, krisman@collabora.com, Dan Carpenter X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 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: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" Refactor I2S Master mode clock programming sequence code. This will also fix the i2s clocks restore issue during system level resume. Signed-off-by: Vijendar Mukunda --- sound/soc/amd/vangogh/acp5x-i2s.c | 26 +++++++------------------- sound/soc/amd/vangogh/acp5x.h | 29 +++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+), 19 deletions(-) diff --git a/sound/soc/amd/vangogh/acp5x-i2s.c b/sound/soc/amd/vangogh/acp5x-i2s.c index 002db3971ca9..59a98f89a669 100644 --- a/sound/soc/amd/vangogh/acp5x-i2s.c +++ b/sound/soc/amd/vangogh/acp5x-i2s.c @@ -88,10 +88,9 @@ static int acp5x_i2s_hwparams(struct snd_pcm_substream *substream, struct snd_soc_card *card; struct acp5x_platform_info *pinfo; struct i2s_dev_data *adata; - union acp_i2stdm_mstrclkgen mclkgen; u32 val; - u32 reg_val, frmt_reg, master_reg; + u32 reg_val, frmt_reg; u32 lrclk_div_val, bclk_div_val; lrclk_div_val = 0; @@ -160,20 +159,6 @@ static int acp5x_i2s_hwparams(struct snd_pcm_substream *substream, acp_writel(val, rtd->acp5x_base + reg_val); if (adata->master_mode) { - switch (rtd->i2s_instance) { - case I2S_HS_INSTANCE: - master_reg = ACP_I2STDM2_MSTRCLKGEN; - break; - case I2S_SP_INSTANCE: - default: - master_reg = ACP_I2STDM0_MSTRCLKGEN; - break; - } - mclkgen.bits.i2stdm_master_mode = 0x1; - if (adata->tdm_mode) - mclkgen.bits.i2stdm_format_mode = 0x01; - else - mclkgen.bits.i2stdm_format_mode = 0x0; switch (params_format(params)) { case SNDRV_PCM_FORMAT_S16_LE: switch (params_rate(params)) { @@ -238,9 +223,8 @@ static int acp5x_i2s_hwparams(struct snd_pcm_substream *substream, default: return -EINVAL; } - mclkgen.bits.i2stdm_bclk_div_val = bclk_div_val; - mclkgen.bits.i2stdm_lrclk_div_val = lrclk_div_val; - acp_writel(mclkgen.u32_all, rtd->acp5x_base + master_reg); + rtd->lrclk_div = lrclk_div_val; + rtd->bclk_div = bclk_div_val; } return 0; } @@ -249,9 +233,11 @@ static int acp5x_i2s_trigger(struct snd_pcm_substream *substream, int cmd, struct snd_soc_dai *dai) { struct i2s_stream_instance *rtd; + struct i2s_dev_data *adata; u32 ret, val, period_bytes, reg_val, ier_val, water_val; u32 buf_size, buf_reg; + adata = snd_soc_dai_get_drvdata(dai); rtd = substream->runtime->private_data; period_bytes = frames_to_bytes(substream->runtime, substream->runtime->period_size); @@ -300,6 +286,8 @@ static int acp5x_i2s_trigger(struct snd_pcm_substream *substream, } acp_writel(period_bytes, rtd->acp5x_base + water_val); acp_writel(buf_size, rtd->acp5x_base + buf_reg); + if (adata->master_mode) + acp5x_set_i2s_clk(adata, rtd); val = acp_readl(rtd->acp5x_base + reg_val); val = val | BIT(0); acp_writel(val, rtd->acp5x_base + reg_val); diff --git a/sound/soc/amd/vangogh/acp5x.h b/sound/soc/amd/vangogh/acp5x.h index fe5e1fa98974..b85d3ee369a3 100644 --- a/sound/soc/amd/vangogh/acp5x.h +++ b/sound/soc/amd/vangogh/acp5x.h @@ -105,6 +105,8 @@ struct i2s_stream_instance { dma_addr_t dma_addr; u64 bytescount; void __iomem *acp5x_base; + u32 lrclk_div; + u32 bclk_div; }; union acp_dma_count { @@ -191,3 +193,30 @@ static inline u64 acp_get_byte_count(struct i2s_stream_instance *rtd, } return byte_count.bytescount; } + +static inline void acp5x_set_i2s_clk(struct i2s_dev_data *adata, + struct i2s_stream_instance *rtd) +{ + union acp_i2stdm_mstrclkgen mclkgen; + u32 master_reg; + + switch (rtd->i2s_instance) { + case I2S_HS_INSTANCE: + master_reg = ACP_I2STDM2_MSTRCLKGEN; + break; + case I2S_SP_INSTANCE: + default: + master_reg = ACP_I2STDM0_MSTRCLKGEN; + break; + } + + mclkgen.bits.i2stdm_master_mode = 0x1; + if (adata->tdm_mode) + mclkgen.bits.i2stdm_format_mode = 0x01; + else + mclkgen.bits.i2stdm_format_mode = 0x00; + + mclkgen.bits.i2stdm_bclk_div_val = rtd->bclk_div; + mclkgen.bits.i2stdm_lrclk_div_val = rtd->lrclk_div; + acp_writel(mclkgen.u32_all, rtd->acp5x_base + master_reg); +} From patchwork Wed Feb 23 07:19:32 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Mukunda,Vijendar" X-Patchwork-Id: 12756502 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 15A65C433F5 for ; Wed, 23 Feb 2022 07:25:34 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 17B2A19FE; Wed, 23 Feb 2022 08:24:42 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 17B2A19FE DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1645601132; bh=vo1pimwegWweai8458tuFqI4wiJTy+vsNYWQZ5E4c1Q=; h=From:To:Subject:Date:In-Reply-To:References:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=lqcYRfBuGqIg7IQWLhUe1lPwwwjPh1193AIOCdnKJsKtqrQz+tbzSnOV9R2BAd67Y hyVjIiSE4e/PvY++l/sqeok5vcYV+c2eqebGYWxtI1fHQSY+i6PJKTii8gPS4O7lTS ZFAD0oflqvpAfamhkLtzRKqoQOXBXKtJXdSce6Qc= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id CA269F80515; Wed, 23 Feb 2022 08:24:26 +0100 (CET) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 68BFBF802A0; Wed, 23 Feb 2022 08:24:23 +0100 (CET) Received: from NAM04-DM6-obe.outbound.protection.outlook.com (mail-dm6nam08on20604.outbound.protection.outlook.com [IPv6:2a01:111:f400:7e8b::604]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id D21F9F8019D for ; Wed, 23 Feb 2022 08:24:20 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz D21F9F8019D Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key) header.d=amd.com header.i=@amd.com header.b="vuSuFqoa" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=kiqgEdD0yo/vJosm5tAMtHiu9l5xEXo16VfGrylwa5P78d8+sMlNDLD+SXJnSuWHfEJ82wW/c+odAOG03wlTOrpup1DiU/b9xK5pgJ5G/0B8hmsmG8liXBxwoC2jgY+jWS4u1lwd5MqyNdFjx8ahDBCfwQ7fxhDjkmOTR434OLz8eILW3askIEKGzcph6NyD0xUqFrN1kmJI7TrVmyMyD4pNmfyVHg/Pro9FCM/MJcE4BNa4c6tgSwlnVHCaizlKm6UdnUC9baWcULuM7y1yIFYAgBTsb9s7omLqsyGLKZyuyZ9Jx3skIf1muzqfYnkPCDwSD7J223lfRxraY9cbMA== 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=VNZdMwv7f9vordSmao+DeoLfrkUT4J7OyzKY+uIv7DY=; b=FjUVY07YA2pcVl0KS7Xvmu/CfGuyyMw1mM9nQCibCXazme7jMkCnjlevaaQ3zZOo7KSdqxhgdsdWbkCwBntRuNBuPfBrjcQXVyxMLOHM5CzLDtfY4F+LLKjXpb9giNxlByax7P1iTMEYBXROblUgNsDPAGSGyd8C7Kl3d/tTwRvMP7g+Rwbj2XpyB72Mx5opsxTFzRLVomXkO3yEx5XwkiG1hHI8WOcHs6blDamVlihK5SQpyyC7KVIfhPapEtIc0cx+VffuHihXkhMKXCwqFTcAvOk+DGp9ZhtmAj0JgDwakfDbd1e6FdpLUn4Y9VeCrKWwwK3n9fXJ9MWr/GZAKA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=VNZdMwv7f9vordSmao+DeoLfrkUT4J7OyzKY+uIv7DY=; b=vuSuFqoa49jSrINIWHEw5jeAlcxQLox863W728kRR7gRstlPtjVvPsJe+wo/pbaaAWmhvreS+i3ywp8EWq53frzvPfYR+Wv6vSEORIBcV9RzzSvAA1x5OFqnNKcuHSS0DTvNoZGglJIZ992o9T5OOrZveNTUf91mC42Ej0GJ7RI= Received: from BN6PR14CA0042.namprd14.prod.outlook.com (2603:10b6:404:13f::28) by DM6PR12MB3819.namprd12.prod.outlook.com (2603:10b6:5:1c6::20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4995.24; Wed, 23 Feb 2022 07:24:16 +0000 Received: from BN8NAM11FT047.eop-nam11.prod.protection.outlook.com (2603:10b6:404:13f:cafe::88) by BN6PR14CA0042.outlook.office365.com (2603:10b6:404:13f::28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5017.21 via Frontend Transport; Wed, 23 Feb 2022 07:24:16 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB03.amd.com; Received: from SATLEXMB03.amd.com (165.204.84.17) by BN8NAM11FT047.mail.protection.outlook.com (10.13.177.220) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5017.22 via Frontend Transport; Wed, 23 Feb 2022 07:24:16 +0000 Received: from SATLEXMB06.amd.com (10.181.40.147) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.18; Wed, 23 Feb 2022 01:24:11 -0600 Received: from SATLEXMB04.amd.com (10.181.40.145) by SATLEXMB06.amd.com (10.181.40.147) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.18; Wed, 23 Feb 2022 01:23:58 -0600 Received: from LinuxHost.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server id 15.1.2375.18 via Frontend Transport; Wed, 23 Feb 2022 01:23:55 -0600 From: Vijendar Mukunda To: , Subject: [PATCH 3/9] ASoC: nau8821: enable no_capture_mute flag Date: Wed, 23 Feb 2022 12:49:32 +0530 Message-ID: <20220223071959.13539-3-Vijendar.Mukunda@amd.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220223071959.13539-1-Vijendar.Mukunda@amd.com> References: <20220223071959.13539-1-Vijendar.Mukunda@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: ff7e0e9f-a554-43f6-ee25-08d9f69d7f9c X-MS-TrafficTypeDiagnostic: DM6PR12MB3819:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 9egyPvR2XUM+NrKSjjwhlT21my6TYOXVzj374RLMCE35u3GqbIVo3oQlMtZx17cFa16yGiQc0zzrq/0k89K1+p2zxQ1Aivs9cvL9B9hzBINpcEdSENUECto4fhq3PMTo1APAGMrMddp66E4fVTvTptiqb3uSA2c5tiMVUaRswrUeeTru6idASuLMJgw9kuIOvBap89OFr4pJMg6N8yS3PQNCdMFFaSPIs2oaXW4U9Bthiw4KUxlxC6MAY7IScDi5LIG1fDOYoxK5n5o1XzC7oYoRO54cwya5rkIwpdNIRdmUeeNLvEnjgXWaFDjT0mf5o98xMS11oI8l+FXgZeI5ReKm905lL2tLTwkN3RtmIp1zQCm88VG4YxRcN8l5m8eSuY/VWUyXHC8+0MpbJ+tYwmZNVmsex1v8XhTat5SDIAFyMCN9r0GBFsECbOejF/33fVydvt2CqVMrYFOmtgKP9pciyHMFki6j8j95Rq50qeTT40FTUVjG+A2eD/lpBNOHWyZeK/WGZGyjwG7kkKW3O15nvnvJMyfhnxMKHTpcQW0w0seYp2Y1EXEWUyHOKpuHS0Z0YMDSqKA8lZndqMHaQufFrYRUTg0u4fQJ3N6+kUGxwjAyoyO4RtSsalrwdhfpR7q8q8uQBP7KAyRjZYPW/PJ4OTaWK4JDrZF0V/QdrkDFw1YqD8hTo1tVTjdbAp1NFO2bn7YKQv9C2I8XQIYDXw== X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB03.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230001)(4636009)(40470700004)(36840700001)(46966006)(4326008)(81166007)(1076003)(186003)(70206006)(70586007)(2616005)(26005)(8676002)(316002)(508600001)(82310400004)(356005)(86362001)(7696005)(83380400001)(426003)(36756003)(40460700003)(110136005)(54906003)(8936002)(47076005)(36860700001)(6666004)(4744005)(336012)(5660300002)(2906002)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Feb 2022 07:24:16.0300 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: ff7e0e9f-a554-43f6-ee25-08d9f69d7f9c X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB03.amd.com] X-MS-Exchange-CrossTenant-AuthSource: BN8NAM11FT047.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR12MB3819 Cc: Pierre-Louis Bossart , Sunil-kumar.Dommati@amd.com, wtli@nuvoton.com, open list , Takashi Iwai , Liam Girdwood , Vijendar Mukunda , Alexander.Deucher@amd.com, krisman@collabora.com X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 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: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" Enable no_capture_mute_flag in nau8821 codec driver. This will fix active playback stream mute issue when capture stream got closed. Signed-off-by: Vijendar Mukunda --- sound/soc/codecs/nau8821.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sound/soc/codecs/nau8821.c b/sound/soc/codecs/nau8821.c index 2de818377484..d67dc27890a9 100644 --- a/sound/soc/codecs/nau8821.c +++ b/sound/soc/codecs/nau8821.c @@ -814,6 +814,7 @@ static const struct snd_soc_dai_ops nau8821_dai_ops = { .hw_params = nau8821_hw_params, .set_fmt = nau8821_set_dai_fmt, .mute_stream = nau8821_digital_mute, + .no_capture_mute = 1, }; #define NAU8821_RATES SNDRV_PCM_RATE_8000_192000 From patchwork Wed Feb 23 07:19:33 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Mukunda,Vijendar" X-Patchwork-Id: 12756503 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id F1F37C433EF for ; Wed, 23 Feb 2022 07:25:38 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 441711A28; Wed, 23 Feb 2022 08:24:47 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 441711A28 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1645601137; bh=9I+tD7xrlzYhy6wI7RVOwtz1ur7X515lZHrOmuWF29I=; h=From:To:Subject:Date:In-Reply-To:References:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=j7fDo7EyHvJ9Y2cLZfk3qxmLN3jiPHsp6CD0fBiVwqt711SH4zz0JP9stJ2FPUyEb K77iyGHmD2cb0PzbhYvqJEjnyJg8V9EscDnvpcPhVA6cQr7inFrpQmPy8b4QcqmCI0 wYpEknFuKkQFkawipp4rwWw7Xt1Se26WIWyClny4= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 4808BF8051A; Wed, 23 Feb 2022 08:24:38 +0100 (CET) Received: by alsa1.perex.cz (Postfix, from userid 50401) id A7674F8019D; Wed, 23 Feb 2022 08:24:37 +0100 (CET) Received: from NAM02-BN1-obe.outbound.protection.outlook.com (mail-bn1nam07on2060d.outbound.protection.outlook.com [IPv6:2a01:111:f400:7eb2::60d]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id BC430F8019D for ; Wed, 23 Feb 2022 08:24:29 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz BC430F8019D Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key) header.d=amd.com header.i=@amd.com header.b="qFTQpkEQ" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=aUUKxchlX+EydVOg1IsusUaav6Cfns4XWuIKa116k0wlXetjJXXUoQxatk6R+f1dFT0GO/WX0rRCYsPC0xEAdHoq4rGMUzXHwsEmVJgsAvTv6NvfCupSzMrYkAhBXOSTlxF7IrVbzilJ37k3rOnmz9JcDkf6mOvSBhK+gH27GPeoCeVVzL8QZLORpE3eJVXJMkdUv8wczcqWIFeJcDD9nnmQapIZIf9QBSBYTgcReCwF68xlgnS5C9JGc9y3wUkZ7akLFn8fYZIchO0ykTUYPV1WkyxaiOc4tjVpr4Rm/w5uuqjoxFlvZVlvRz3Vzz64erfiyFocYqD8GuRVKXIfwg== 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=JaONtKtKuues/80Z065JmAA3NdlvKn7/RhGsQ0u67l8=; b=khHXAWYDkZ0/xh39x56BzqSkR/n96mICWkoOnW/zhLInmvXS2lZpnVm7dof+b3SD7s6cNg8QjGCwSFy1tpqrSUE0By2+60CjjQvqEgC5yvfRE96aHzbM7uyUAFySXxwR8a8hCbE2/O/Ml7Ym53ne576PdDg+8pa5tqcVLjfzYCKeah6C+ZSTtpMRRdSSZfXTSlgEG5PDJ4YZ54hmbkJzL7v64pVBR+xyxUyCK0dsmdwxuezv1aVa8sCev0ibjCwNxdLTOg2ff904p+r8e9MFu7SfvHN5IT1OFyQXrM7qcs/pJC/i6whIFg5D4yWD3oqcZr2szcjsGVsoOuBHWqZt/w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=JaONtKtKuues/80Z065JmAA3NdlvKn7/RhGsQ0u67l8=; b=qFTQpkEQyxu4vcTIRGVZkIY0AHG4pnUqBzUGDd5z7ocTpy34T4PN5CUKM9NP55/WvuFXf5nH9AmDhjrERiegxOTISwQ9ILiqYM8Sjuh3ZE/5WrouGTWzI33j5Hny+MIfTZZNjk+00mfBPmG/aKB/0JUSckmf7Y+mk+7gET5mvV0= Received: from DM5PR10CA0001.namprd10.prod.outlook.com (2603:10b6:4:2::11) by DM6PR12MB4202.namprd12.prod.outlook.com (2603:10b6:5:219::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5017.21; Wed, 23 Feb 2022 07:24:24 +0000 Received: from DM6NAM11FT027.eop-nam11.prod.protection.outlook.com (2603:10b6:4:2:cafe::2a) by DM5PR10CA0001.outlook.office365.com (2603:10b6:4:2::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5017.22 via Frontend Transport; Wed, 23 Feb 2022 07:24:24 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; Received: from SATLEXMB04.amd.com (165.204.84.17) by DM6NAM11FT027.mail.protection.outlook.com (10.13.172.205) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5017.22 via Frontend Transport; Wed, 23 Feb 2022 07:24:24 +0000 Received: from SATLEXMB07.amd.com (10.181.41.45) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.18; Wed, 23 Feb 2022 01:24:21 -0600 Received: from SATLEXMB04.amd.com (10.181.40.145) by SATLEXMB07.amd.com (10.181.41.45) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.18; Tue, 22 Feb 2022 23:24:21 -0800 Received: from LinuxHost.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server id 15.1.2375.18 via Frontend Transport; Wed, 23 Feb 2022 01:24:18 -0600 From: Vijendar Mukunda To: , Subject: [PATCH 4/9] ASoC: amd: vg: update platform clock control sequence Date: Wed, 23 Feb 2022 12:49:33 +0530 Message-ID: <20220223071959.13539-4-Vijendar.Mukunda@amd.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220223071959.13539-1-Vijendar.Mukunda@amd.com> References: <20220223071959.13539-1-Vijendar.Mukunda@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 9cd909db-30c1-4787-7c61-08d9f69d847a X-MS-TrafficTypeDiagnostic: DM6PR12MB4202:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Z37HawR/ZWha6FgBWkOiAgaa5BweaLSuPVwP0LuEjKHIAfvd3cdOkE6TJXw/vGnnmktFpm+4ATqt4ByQAVinOM8qmQ8nBM19JBufPSS6pkPLfcVz46T83A5G2F0XDO5SI0RknIIvNJP/fnN1mKyVZ1ReNuLKkErXMkjnDp6n8LRC4cqbFqwAjc+mbH1t7wK9BYpLL4Wo7lKhPVl/xVbf0pZF8ygWdBFOpdMJdjmM/xHpL8M4vzosLH1M+SdgvsKnuiFStCF4ZcAaWWYScvBn6z8BNHKOoctamMNt9/NWXnH64htdNUA/wi5D/ye7/LR8tvozQQ0bE6DKB9+9VQ9v1xbQREh0jlR8buP4JWPeK0EoZqkoZjZ/kckyCPwch3OLb86YNj3oARWuftet59Kg5qVMy+ARTdYqHKIKV/21DvlL5/UPvavHA1T48HI6dFbwy5Re8zNEZrSolPo464/2aBCJ++0jP0Rrd+YB2x+GHm7+LxQEQN72Y0vYbuSUV4wSepbon6Gn3tg2yLzxuY2Dub7An/ZWpujjoFRkvRjW3if+bTNgt6giZ1l8DTcHoEM8Ztr4+WCFLEhN0JBet+6BAKJg8JdKTMql2XFqqpJjeebtktViFVgwuAnxZyzoNr5I654dtVt59gkZNnMkJPit3cew1wQ+wSx/9u6UQ+kGclsiTzOtad0IKpSCw8XJrLptpUt/qRqzFWJd1Swr26NlAA== X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB04.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230001)(4636009)(36840700001)(46966006)(40470700004)(83380400001)(36860700001)(1076003)(86362001)(2616005)(336012)(26005)(426003)(47076005)(356005)(36756003)(186003)(81166007)(508600001)(54906003)(316002)(110136005)(70586007)(70206006)(4326008)(15650500001)(5660300002)(8936002)(82310400004)(2906002)(8676002)(6666004)(7696005)(40460700003)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Feb 2022 07:24:24.1460 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 9cd909db-30c1-4787-7c61-08d9f69d847a X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: DM6NAM11FT027.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR12MB4202 Cc: Sunil-kumar.Dommati@amd.com, wtli@nuvoton.com, open list , Takashi Iwai , Liam Girdwood , Vijendar Mukunda , Alexander.Deucher@amd.com, krisman@collabora.com X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 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: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" Add pre power on widget event. Based on this event update platform clock control sequence. This will fix Codec clock and pll restoration issue during system level resume. Signed-off-by: Vijendar Mukunda --- sound/soc/amd/vangogh/acp5x-mach.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/sound/soc/amd/vangogh/acp5x-mach.c b/sound/soc/amd/vangogh/acp5x-mach.c index 14cf325e4b23..e610616d796c 100644 --- a/sound/soc/amd/vangogh/acp5x-mach.c +++ b/sound/soc/amd/vangogh/acp5x-mach.c @@ -33,6 +33,8 @@ #define DUAL_CHANNEL 2 #define ACP5X_NUVOTON_CODEC_DAI "nau8821-hifi" #define VG_JUPITER 1 +#define ACP5X_NUVOTON_BCLK 3072000 +#define ACP5X_NAU8821_FREQ_OUT 12288000 static unsigned long acp5x_machine_id; static struct snd_soc_jack vg_headset; @@ -274,6 +276,15 @@ static int platform_clock_control(struct snd_soc_dapm_widget *w, dev_err(card->dev, "set sysclk err = %d\n", ret); return -EIO; } + } else { + ret = snd_soc_dai_set_sysclk(codec_dai, NAU8821_CLK_FLL_BLK, 0, + SND_SOC_CLOCK_IN); + if (ret < 0) + dev_err(codec_dai->dev, "can't set BLK clock %d\n", ret); + ret = snd_soc_dai_set_pll(codec_dai, 0, 0, ACP5X_NUVOTON_BCLK, + ACP5X_NAU8821_FREQ_OUT); + if (ret < 0) + dev_err(codec_dai->dev, "can't set FLL: %d\n", ret); } return ret; } @@ -289,7 +300,7 @@ static const struct snd_soc_dapm_widget acp5x_8821_widgets[] = { SND_SOC_DAPM_MIC("Headset Mic", NULL), SND_SOC_DAPM_MIC("Int Mic", NULL), SND_SOC_DAPM_SUPPLY("Platform Clock", SND_SOC_NOPM, 0, 0, - platform_clock_control, SND_SOC_DAPM_POST_PMD), + platform_clock_control, SND_SOC_DAPM_PRE_PMU | SND_SOC_DAPM_POST_PMD), }; static const struct snd_soc_dapm_route acp5x_8821_audio_route[] = { From patchwork Wed Feb 23 07:19:34 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Mukunda,Vijendar" X-Patchwork-Id: 12756504 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 99F1BC433EF for ; Wed, 23 Feb 2022 07:26:06 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id AF4791944; Wed, 23 Feb 2022 08:25:14 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz AF4791944 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1645601164; bh=4EcAmxjAC0laFt2fCA2a2jzqf6mfKNNd2EkvnzfEArQ=; h=From:To:Subject:Date:In-Reply-To:References:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=e+uDesh6n5pMnYFUk6JJfj4HVtCsny9s3Z2URk5QcFpPiRHiRuvZJyDG0+zPObgFx kN9HqRZS3pt5EmQB5I5s9UWeCI9l/XcccIMkdzdQoNVNE1of8GHjD2QgHBWoE6hohb QKJYe9s4W0HfsSn4r6lelVcZXVykW4zVpLhm3me0= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id C1E0EF802E3; Wed, 23 Feb 2022 08:24:43 +0100 (CET) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 517C5F80431; Wed, 23 Feb 2022 08:24:42 +0100 (CET) Received: from NAM12-DM6-obe.outbound.protection.outlook.com (mail-dm6nam12on2060a.outbound.protection.outlook.com [IPv6:2a01:111:f400:fe59::60a]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id CA154F800B6 for ; Wed, 23 Feb 2022 08:24:38 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz CA154F800B6 Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key) header.d=amd.com header.i=@amd.com header.b="S9YYnre/" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=oNOGxceMb20JJmzATcL+s2MTK806u1j2kdCniz4gxcwVYm1QHZlHb05WXj49y26GipCcV+NyF0zhtkxKDb4C/zJh3YYhvA2mdDm0zR4pJREJO1PV2rHIl/sUxpfJLDOQ+ys4omrcEyZceNfZAl+A20ryPn0WpMoxmnUJqRyL84/Nqhi8iUB/tzVISPewveR9ziKw9xpxR6goYf4Mfh/4VhSP29OUsV3H5e1DJdEpzgDVyp2k4jpYHs+oDStFYwPMbIMS4+qlZnEd/5pJ0m95dNkM+HuF9HCvSMHIGCVNJ7mtMxEq8BV5ucL79o91kj6orBh3gtp2AQzLQ+PnYKd5Ng== 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=V7xGXCgOBqLlRtfmLnCo6ngGAXObtc0QHwij5Yc2q5A=; b=EfSYI+jsntp2WuuNNsLfTRCKlX9v/zRd1+AracAFhwEl+21ZR4FFOxkrZ6c1WdXPcE1mgKRqi/+sIkFYtrrEySsP9KEb+qE2r2f2SbVl5skOx/P/zFIXLDyhIyNjUbAkUaFBnbbEDD0hwU5bHeefnc1KZug4OWIeHkjQhes6htwHaZEERT2hDJJUu8w9Ef0FWMeBs8JHUoB7tYwsQ8i5Flu1Y9lmIaSsvgTCfmndt8UNoF7bMeA8M4tHHm5f/F8TJSuAcZgvfzRNM0jKgj23+JqVW4qjZ/8YLcrhn8LwN+cY0KDLeNp3UVPjxiqj8eT93QQeCKYB2d1Y8HWMMH9/fQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=V7xGXCgOBqLlRtfmLnCo6ngGAXObtc0QHwij5Yc2q5A=; b=S9YYnre/oOCe86L3rW2j6DWv1apM2NT/131Ukxal5Ofe/DqtScL9hFuawosv4Ur0osX3llkuai+o66xU7yQgcZCHsV6pxtbJsWm9OQTSGR3PzGhsZfU4nsyK8ezbglyNeR1aex8zos5Jt+15hIXOuT++a+LCI5nafJK8kM6+k40= Received: from BN1PR10CA0011.namprd10.prod.outlook.com (2603:10b6:408:e0::16) by BYAPR12MB2871.namprd12.prod.outlook.com (2603:10b6:a03:13d::25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5017.22; Wed, 23 Feb 2022 07:24:33 +0000 Received: from BN8NAM11FT023.eop-nam11.prod.protection.outlook.com (2603:10b6:408:e0:cafe::58) by BN1PR10CA0011.outlook.office365.com (2603:10b6:408:e0::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5017.21 via Frontend Transport; Wed, 23 Feb 2022 07:24:32 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB03.amd.com; Received: from SATLEXMB03.amd.com (165.204.84.17) by BN8NAM11FT023.mail.protection.outlook.com (10.13.177.103) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5017.22 via Frontend Transport; Wed, 23 Feb 2022 07:24:32 +0000 Received: from SATLEXMB07.amd.com (10.181.41.45) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.18; Wed, 23 Feb 2022 01:24:32 -0600 Received: from SATLEXMB04.amd.com (10.181.40.145) by SATLEXMB07.amd.com (10.181.41.45) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.18; Tue, 22 Feb 2022 23:24:31 -0800 Received: from LinuxHost.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server id 15.1.2375.18 via Frontend Transport; Wed, 23 Feb 2022 01:24:28 -0600 From: Vijendar Mukunda To: , Subject: [PATCH 5/9] ASoC: amd: vg: apply sample bits pcm constraint Date: Wed, 23 Feb 2022 12:49:34 +0530 Message-ID: <20220223071959.13539-5-Vijendar.Mukunda@amd.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220223071959.13539-1-Vijendar.Mukunda@amd.com> References: <20220223071959.13539-1-Vijendar.Mukunda@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: f25d9d4d-b6fb-4d93-b07b-08d9f69d8994 X-MS-TrafficTypeDiagnostic: BYAPR12MB2871:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 77Pd10GToVb/I+dDdGr/vy8YwuHX13vm+2XAMzt3T0szTbkQW/EI5kypGaq93XH/iUbHMtZO+VHMQna+8VEKgwf4obQvEmn8/uReRGwzoeiEPNeLwyLq1jeJisqNn8uYtH9r8/Mp0pqR89CugdvzHE2RU7ygrMIzOXdHg/8AX5SKQqjSAd1easnl9zrnbcp7hW3VOBAoUjbFoRkluI73pspYQsi88yf8UmzvSJdo6zNE/ijbkx9ksC+qoBwrHQ6TIwfxnuEroLbfr7rTFIPxCgllRZAGcCDU3gzKPx+ydKyQ3Lv31Ti2c/aaVgQekc/4VamDMe1m7erS8fids231heMQdlKF5we2HzOtW5OiKFFPBeSK+U/S0SHqMYSAJFKQO63Nkan4OjEBzNVJkG7isQECn/Gjco1ThAfy0SCYG3BscKSmahTC+CUHq5W17tISBRUTPHhDoNYBY3g/o/INj54f0L9MnCV22ANrmX7h2sZXxaMml3LcvfuM6CGbrjwaYrgk7/RN8VKIjmm+LaAhqIsTa194w3jyWbWLSj1skrJ3hRGWBVN1AyYi3db8GVHxYrll7gW+XEd34CijznMxaTGyvpPsEA6X+1G0E4+vVFo0TGlLNQGitIabfeTILfX4p68oTTXPz6/97Iqul0BpxlhVDVubdvEro6DtHnlQ3zvFi7KYepSF06fgxV+OavOxtLFLmQc6YdBG0RniNYiz3Q== X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB03.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230001)(4636009)(46966006)(40470700004)(36840700001)(36860700001)(2616005)(47076005)(81166007)(356005)(7696005)(2906002)(54906003)(110136005)(316002)(40460700003)(70206006)(70586007)(86362001)(4326008)(5660300002)(36756003)(8676002)(1076003)(8936002)(82310400004)(426003)(26005)(186003)(508600001)(6666004)(83380400001)(336012)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Feb 2022 07:24:32.7532 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: f25d9d4d-b6fb-4d93-b07b-08d9f69d8994 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB03.amd.com] X-MS-Exchange-CrossTenant-AuthSource: BN8NAM11FT023.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR12MB2871 Cc: Sunil-kumar.Dommati@amd.com, wtli@nuvoton.com, open list , Takashi Iwai , Liam Girdwood , Vijendar Mukunda , Alexander.Deucher@amd.com, krisman@collabora.com X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 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: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" ACP I2S controller has limitation to program different BCLK for TX and RX paths. Headset path uses I2S SP controller instance. As per requirement, Restricted 32 bits as sample bits by applying pcm constraint in startup calabck for Headset path. Signed-off-by: Vijendar Mukunda --- sound/soc/amd/vangogh/acp5x-mach.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/sound/soc/amd/vangogh/acp5x-mach.c b/sound/soc/amd/vangogh/acp5x-mach.c index e610616d796c..18b2fdc8dc9e 100644 --- a/sound/soc/amd/vangogh/acp5x-mach.c +++ b/sound/soc/amd/vangogh/acp5x-mach.c @@ -100,6 +100,13 @@ static const struct snd_pcm_hw_constraint_list constraints_channels = { .mask = 0, }; +static const unsigned int acp5x_nau8821_format[] = {32}; + +static struct snd_pcm_hw_constraint_list constraints_sample_bits = { + .list = acp5x_nau8821_format, + .count = ARRAY_SIZE(acp5x_nau8821_format), +}; + static int acp5x_8821_startup(struct snd_pcm_substream *substream) { struct snd_pcm_runtime *runtime = substream->runtime; @@ -115,6 +122,9 @@ static int acp5x_8821_startup(struct snd_pcm_substream *substream) &constraints_channels); snd_pcm_hw_constraint_list(runtime, 0, SNDRV_PCM_HW_PARAM_RATE, &constraints_rates); + snd_pcm_hw_constraint_list(substream->runtime, 0, + SNDRV_PCM_HW_PARAM_SAMPLE_BITS, + &constraints_sample_bits); return 0; } From patchwork Wed Feb 23 07:19:35 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Mukunda,Vijendar" X-Patchwork-Id: 12756505 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 6336DC433EF for ; Wed, 23 Feb 2022 07:26:24 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 7F7831A3C; Wed, 23 Feb 2022 08:25:32 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 7F7831A3C DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1645601182; bh=N5NSh9DizGcwdcGOB9zlx8ucj6CmkNPP1zApBS5LixE=; h=From:To:Subject:Date:In-Reply-To:References:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=P87NQ58KPAxSteN3DBGttW7i/Tv0hOeZfnOPvQ9nuawCFTdaUeIId9MRwetwc3xLD iCQROcakJTcVSISJZpZ2FGjg7k9u3X4Wyo/DSwdgEBixb9uZ8aF2gTCPy7k6PJ2RmI qemls1idmvn4cfA5S3yrIOw6uvIUBMDinDwVcP6w= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 53ED3F804FD; Wed, 23 Feb 2022 08:25:00 +0100 (CET) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 6C089F804FD; Wed, 23 Feb 2022 08:24:59 +0100 (CET) Received: from NAM10-DM6-obe.outbound.protection.outlook.com (mail-dm6nam10on2060a.outbound.protection.outlook.com [IPv6:2a01:111:f400:7e88::60a]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 61D45F804FD for ; Wed, 23 Feb 2022 08:24:53 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 61D45F804FD Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key) header.d=amd.com header.i=@amd.com header.b="kIenCyxB" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=AHqz42/NpA47lZw6O/DzZuEDzDxSik2xT/fsSQkvI3/j+PawRaBn1v8sqLs8oolONG7Je9cKzAv3TRSIsj9YnA4curCcrNLTuzWBMWw5tIx2Fyfpe3pyw+IMps/S7PjFaRz1JYjpuxn3Ow+Kr/OxFf0TngAsW+yetdIxlZ4uGWFkQIRSmrnjJcv9Z9u1oinj+UIWLG4mFYUFmRxixxH9ekL7cjrMMN786LGYjPmxm1z1hByxV3PpMshn1TPPNj4mt/zT5WOPuVeBmp8RxNs48pmN1ZePt0DmPJL32YQsPKIFxKhIM7acWJuxhK6EkR70YflP/DlWeGLoMQFppsIC9A== 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=qF5aFrLNUIZP6RUTzhtPYwChlMAZo7yzMXVp7fCOFeQ=; b=NkDRzwpw9S8JW8AGgtx6e/oUOxPr6RZZ9qSbhQ1CNoJV1Tg3fb0s4ZKW2bceBfHX4aZQuVjlxfzlkLdvhRaSfJ0fiaMaytsEjgblZFz0z4Iq6C2pigszaFxSYYUTwGarDS8wDCNy7it4O4FkX0LWaW4/3IXabVwQMSx52PGWVL31Chb/5Css2Rs5UBx7oNHZ4pJ8stZTiJ1+HtK/2pG2Aubdpf8HB6tcGO/Q7ArK2jD1NY2ipvXEy3X3JYQ3QRr9H5Mf6dRT3jyMI8nRfABHbUnwiQJGT2Xa4WPiVlpmHe4CDygpxlicTK5TQQDsQnCswnIWiH9LgHTWQzz6Kj1Htg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=qF5aFrLNUIZP6RUTzhtPYwChlMAZo7yzMXVp7fCOFeQ=; b=kIenCyxBQ2ZkGYQT5gjeZ4kj+4gJJ7BJ7BfUN93UBwwRXBd0cJ3wyW0G/oVe8gPdbEJqeCQk53KBWXOzpwr4A8vuK0Oe/fNaYT4KmHx5wQH0NaQiIlRVmUHvqIX3k5jLUtrFV39T7Yw293J/6NhWYLkkl8RVypyU9xDG+/zlm00= Received: from DS7PR07CA0001.namprd07.prod.outlook.com (2603:10b6:5:3af::10) by DM6PR12MB3402.namprd12.prod.outlook.com (2603:10b6:5:3b::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5017.22; Wed, 23 Feb 2022 07:24:47 +0000 Received: from DM6NAM11FT037.eop-nam11.prod.protection.outlook.com (2603:10b6:5:3af:cafe::bf) by DS7PR07CA0001.outlook.office365.com (2603:10b6:5:3af::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5017.21 via Frontend Transport; Wed, 23 Feb 2022 07:24:47 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; Received: from SATLEXMB04.amd.com (165.204.84.17) by DM6NAM11FT037.mail.protection.outlook.com (10.13.172.122) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5017.22 via Frontend Transport; Wed, 23 Feb 2022 07:24:47 +0000 Received: from SATLEXMB04.amd.com (10.181.40.145) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.18; Wed, 23 Feb 2022 01:24:39 -0600 Received: from LinuxHost.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server id 15.1.2375.18 via Frontend Transport; Wed, 23 Feb 2022 01:24:36 -0600 From: Vijendar Mukunda To: , Subject: [PATCH 6/9] ASoC: amd: vg: update acp init and deinit sequence Date: Wed, 23 Feb 2022 12:49:35 +0530 Message-ID: <20220223071959.13539-6-Vijendar.Mukunda@amd.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220223071959.13539-1-Vijendar.Mukunda@amd.com> References: <20220223071959.13539-1-Vijendar.Mukunda@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 5f97a476-cc76-47e9-8cac-08d9f69d9241 X-MS-TrafficTypeDiagnostic: DM6PR12MB3402:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: ks+u3OjHK4Yf1fWDlAoUrSzkiAXMSDwF5Z8gEngCr0UusUfoSXcw7YVo0eNgVVab++q/A+3e0Ip2518v+bzacO/Vm9xTZ1sCG3hFrvUNW3B2IONx+VudirG1FW8exDoH0TPSMmPrz5bUlIhsiHjpGHW0xLI+VCNlJBQ40rsHPfuOGVinwN4z0WJPlFQXzh+Rd5Ei9wcx0pYvOhODmX73zZT4YbZ3M2vez3RGRnhQ0ktJ0df/7UI2jpB1r89IGcwfAlzxvJu6ZKCv6GVa0mkNPQYlmBAKAiVOaztTh5jxmsZ4d7Nien5bjxeoFCIti7mihOQHzSjcbsGp6Uc7iEJFi2g8n59QpFsyQDbziXRn6cbg/gTU8BnZT+k8zhUNFdqgUxFbH4Wha9UaIPOFgzv3y2Xtw/OV3ny3HFq2yrTMfsXbUXHn+X5/iHFO8MAZ+gNEbct3IbFW89/XSO4jiyufaYkMTNRuVMgfXshIeMGjPsEdioxJsXqwg6nCA024emxCCvMiSdIox1PxmvMVfQao1DyprOZxmxozW7V4YSENdaZM+TVuDJWAk3LQ/cYAFLIbEp/9UMOv7O95b6OZl8bvvVKK4CZfNmw1VsWshjjU8ELZwEhYeXZxHUY8QC4JXrrTf4rfJp+UsJhs0fnv1fri6te9kUqFWThEpIwHGVsb75ojus5MBFahCKwq6XXv95zNtTaGTVwpgx29oOxeDN4KDA== X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB04.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230001)(4636009)(40470700004)(46966006)(36840700001)(4326008)(8676002)(70586007)(70206006)(2616005)(86362001)(7696005)(82310400004)(15650500001)(40460700003)(2906002)(356005)(81166007)(83380400001)(5660300002)(36860700001)(8936002)(110136005)(54906003)(508600001)(316002)(186003)(26005)(1076003)(336012)(36756003)(47076005)(426003)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Feb 2022 07:24:47.2766 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 5f97a476-cc76-47e9-8cac-08d9f69d9241 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: DM6NAM11FT037.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR12MB3402 Cc: Pierre-Louis Bossart , Sunil-kumar.Dommati@amd.com, wtli@nuvoton.com, open list , Takashi Iwai , Liam Girdwood , Vijendar Mukunda , Alexander.Deucher@amd.com, krisman@collabora.com X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 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: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" As part of ACP programming sequence, ACP_CONTROL and ACP_CLKMUX_SEL registers should be updated during acp init and de-init sequence. This patch updates register sequence during ACP init and deinit. Signed-off-by: Vijendar Mukunda --- sound/soc/amd/vangogh/pci-acp5x.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sound/soc/amd/vangogh/pci-acp5x.c b/sound/soc/amd/vangogh/pci-acp5x.c index 2b6b9edc36e2..e0df17c88e8e 100644 --- a/sound/soc/amd/vangogh/pci-acp5x.c +++ b/sound/soc/amd/vangogh/pci-acp5x.c @@ -92,12 +92,14 @@ static int acp5x_init(void __iomem *acp5x_base) pr_err("ACP5x power on failed\n"); return ret; } + acp_writel(0x01, acp5x_base + ACP_CONTROL); /* Reset */ ret = acp5x_reset(acp5x_base); if (ret) { pr_err("ACP5x reset failed\n"); return ret; } + acp_writel(0x03, acp5x_base + ACP_CLKMUX_SEL); acp5x_enable_interrupts(acp5x_base); return 0; } @@ -113,6 +115,8 @@ static int acp5x_deinit(void __iomem *acp5x_base) pr_err("ACP5x reset failed\n"); return ret; } + acp_writel(0x00, acp5x_base + ACP_CLKMUX_SEL); + acp_writel(0x00, acp5x_base + ACP_CONTROL); return 0; } From patchwork Wed Feb 23 07:19:36 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Mukunda,Vijendar" X-Patchwork-Id: 12756506 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id E9221C433EF for ; Wed, 23 Feb 2022 07:26:40 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 0DDDB1923; Wed, 23 Feb 2022 08:25:49 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 0DDDB1923 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1645601199; bh=unOYrTNIhP99rs+0niudaiGnIh/L9pgziKK58SEZo58=; h=From:To:Subject:Date:In-Reply-To:References:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=oVFEpVr6HHmBr90PfQhTg1GxzSUoh8mbkuzgb5lSYoGz6IdooLvru2/WY7RrkU4G5 HMgQ45xD+4LuKlxy9GgzMiNKFj5Ug8p4zjgyzNHQTJiPRThjm/B/ByLuza+J7nv3OK fnQpkzqF9aOdfl0fFZHqfB3FwNUCgPqLG2/acRXI= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 406BFF8051E; Wed, 23 Feb 2022 08:25:18 +0100 (CET) Received: by alsa1.perex.cz (Postfix, from userid 50401) id AFAB8F80525; Wed, 23 Feb 2022 08:25:17 +0100 (CET) Received: from NAM12-DM6-obe.outbound.protection.outlook.com (mail-dm6nam12on2060f.outbound.protection.outlook.com [IPv6:2a01:111:f400:fe59::60f]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id C2923F8051E for ; Wed, 23 Feb 2022 08:25:09 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz C2923F8051E Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key) header.d=amd.com header.i=@amd.com header.b="f1R59bwD" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=oDEioTE2DGr89w1V8STtqEO+TzXVIPq+DZEwe4CO6JvzCt/fizuDNS4sgGisOTsyQdTBXihAYwCvZpizoLVHD+QtwMSZpna0ykfvy0Ro9saQoWHnvkUhbVtzJ5a3n6rPpJJl+UNbwEltFKexIy0bfR6b3lkWGLGLLyvAE+u+o+HAJjOCOR9SMO+FXGmaC8QLyd09SLyrKYAMDrCf5WSpyUBk8Hfs4AEslnMx7JblmuhUAyTGCo7dwZY2N4w7jAGAJWpxmjFZPrDUP319SE+01c1J2v0CgA3KyE9GzkcCjQl9kdcMyGc0RIKGr0YKZehGJs15e9f2xQ5xMjkk9qzPsg== 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=lTO65rPdmswhIwJtUcDHe4bDzdsQNBWL3CBniXbDuMQ=; b=lDWuu82tEhRMlU9anjXULYfeX+53LVmgwlGWYN7HVrQcLeuBdzP+7YNkq2+g+74IHVSqvsLakSbZ78RuzqB+xcyxpGWVfyLy0VNOUExjfjiGwmxkgM0Ws+FdVVpmo6rs6M2qhVWKej8m9f1Rrr+ewm+2xCyqessN7kzcblsech5Y/oDcwZYKxEWbQ0hPHXg0zGJPh03gP5x/dQ6da6pLGjl2QQV1T6iQOFM0OFJQhlhOnJ8xnYbbQEAKldM8NDOQbdN/Wz65+URM/HGJsJryYRtx/uzKv9b2FUtcDvmuKZMNhu0cdnafzdFqgVnBr6c1JTwSkby7DrH2+8/n8AGN+w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=lTO65rPdmswhIwJtUcDHe4bDzdsQNBWL3CBniXbDuMQ=; b=f1R59bwDYmwDdNd/q9+T7JUxK3yrJKQOe7wg5QFh9r1bPZKN7tiS830Vm6JhTu7H+tFBn+ULw/lewnsWzF3hk8BklWbgXZ0I1+o5HTY8YFH7jPP9oMlHQEwNdxBnsO+aSJEBzVVQ6nk5f2bauyQsimoXSqdx7IOwnvKDimcEcBY= Received: from MWHPR13CA0018.namprd13.prod.outlook.com (2603:10b6:300:16::28) by CY4PR12MB1256.namprd12.prod.outlook.com (2603:10b6:903:3d::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4995.16; Wed, 23 Feb 2022 07:25:03 +0000 Received: from CO1NAM11FT058.eop-nam11.prod.protection.outlook.com (2603:10b6:300:16:cafe::6c) by MWHPR13CA0018.outlook.office365.com (2603:10b6:300:16::28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5017.9 via Frontend Transport; Wed, 23 Feb 2022 07:25:03 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; Received: from SATLEXMB04.amd.com (165.204.84.17) by CO1NAM11FT058.mail.protection.outlook.com (10.13.174.164) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5017.22 via Frontend Transport; Wed, 23 Feb 2022 07:25:02 +0000 Received: from SATLEXMB05.amd.com (10.181.40.146) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.18; Wed, 23 Feb 2022 01:24:55 -0600 Received: from SATLEXMB04.amd.com (10.181.40.145) by SATLEXMB05.amd.com (10.181.40.146) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.18; Wed, 23 Feb 2022 01:24:54 -0600 Received: from LinuxHost.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server id 15.1.2375.18 via Frontend Transport; Wed, 23 Feb 2022 01:24:51 -0600 From: Vijendar Mukunda To: , Subject: [PATCH 7/9] ASoC: amd: vg: update DAI link name Date: Wed, 23 Feb 2022 12:49:36 +0530 Message-ID: <20220223071959.13539-7-Vijendar.Mukunda@amd.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220223071959.13539-1-Vijendar.Mukunda@amd.com> References: <20220223071959.13539-1-Vijendar.Mukunda@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 72ca46f7-0a9e-4c65-9997-08d9f69d9b98 X-MS-TrafficTypeDiagnostic: CY4PR12MB1256:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: /25mKJruHUh1lCeQRHsIqwmfgwngPndaJN2T+lBt1gDzZxbuBbpMAchVNWQB5wTuqmgPu9kP3tC+TtMppe3CntBS4AR2g8kXbbYPZqvCWFMvpx1zzSqHj5O0EncHuCakfEn73wke7sOfIr10PUiOo3D/jgf587Q41myGpSOzAShmjHgj9vXHXukVPaGN46WlZxs67H85wBMoipZky08t8BUh0MZBmWuMmgVXnM2hviydrF4MEP3bqaBWLqMreLCesV/CRHwMncWEWtkBmuiS2/JZAouTNKspce26Afnp1JUmgkV4J0BDwWKN4KWOJ+s0qT+FH+tAVaXx+yegS6U04FDcSs0t/DuBDgRQh8d6oRRUOjqjaJC5lhCNAeXCl47eu7+Lee/vpQklhXqu9J5AezBmqFMPJ7HBwR96NCGczaWa2zsv0WOodXmeK5zNP90xcZgoChd+wBXc1fGhpwpFysW6/x/+f4IiJj3sRubd34kVXCX0DXACgDCgZ7x28N6P+ZaipeS1j1s3wrJ1ryeIvwlR4Iqyj6E9flFwBtSTNqir6bYiH3x4cPUnsoDoZ3iDAT7OXgZH0gyEq1Lt2FV3idPfpw0Qr9TPe+/R+3aqiYRO67JlIlPEr/KKkGYkCMQhorofwOma/uyVHtbawJO1OWXHAZJXYp1GrTHv5T7gd/u08jJrspUeZwTgr/vYPI9mxQdsvC2G+6VPNQj8sAOqRQ== X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB04.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230001)(4636009)(46966006)(40470700004)(36840700001)(15650500001)(4744005)(70586007)(336012)(508600001)(36860700001)(316002)(82310400004)(70206006)(4326008)(426003)(8676002)(5660300002)(2616005)(7696005)(186003)(1076003)(40460700003)(83380400001)(26005)(81166007)(86362001)(8936002)(36756003)(356005)(54906003)(2906002)(47076005)(6666004)(110136005)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Feb 2022 07:25:02.8528 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 72ca46f7-0a9e-4c65-9997-08d9f69d9b98 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CO1NAM11FT058.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR12MB1256 Cc: Sunil-kumar.Dommati@amd.com, wtli@nuvoton.com, open list , Takashi Iwai , Liam Girdwood , Vijendar Mukunda , Alexander.Deucher@amd.com, krisman@collabora.com X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 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: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" Update DAI link name as "acp5x-8821-play". Signed-off-by: Vijendar Mukunda --- sound/soc/amd/vangogh/acp5x-mach.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/amd/vangogh/acp5x-mach.c b/sound/soc/amd/vangogh/acp5x-mach.c index 18b2fdc8dc9e..287efd9282db 100644 --- a/sound/soc/amd/vangogh/acp5x-mach.c +++ b/sound/soc/amd/vangogh/acp5x-mach.c @@ -242,7 +242,7 @@ SND_SOC_DAILINK_DEF(platform, static struct snd_soc_dai_link acp5x_dai[] = { { - .name = "acp5x-8825-play", + .name = "acp5x-8821-play", .stream_name = "Playback/Capture", .dai_fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_NF | SND_SOC_DAIFMT_CBC_CFC, From patchwork Wed Feb 23 07:19:37 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Mukunda,Vijendar" X-Patchwork-Id: 12756507 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 4F188C433F5 for ; Wed, 23 Feb 2022 07:26:58 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 97EBC194A; Wed, 23 Feb 2022 08:26:06 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 97EBC194A DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1645601216; bh=LnNoBYnTdS05T0G8C80/DXcwlKN1q8t3oAEmDORFxD0=; h=From:To:Subject:Date:In-Reply-To:References:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=Cy5YSTDeXdz0xa3HF4hcuda9BgHcVfX0BxzxeSwaKfRbnF7N8A3fvgTJ5QsN9NnJk B4PbLILryQk+dPOPfMDMpMQpiG2C7W5MgY3U3XwU8Nq1V3p3WFePxWiRn9lAB1g2ph /NcOQ2Ia2bCxWPeZ8R4VrW3bMnag1eysOW0bn2HY= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id BAC5CF80527; Wed, 23 Feb 2022 08:25:20 +0100 (CET) Received: by alsa1.perex.cz (Postfix, from userid 50401) id A1E02F80528; Wed, 23 Feb 2022 08:25:19 +0100 (CET) Received: from NAM04-DM6-obe.outbound.protection.outlook.com (mail-dm6nam08on2061c.outbound.protection.outlook.com [IPv6:2a01:111:f400:7e8b::61c]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id C6B40F80524 for ; Wed, 23 Feb 2022 08:25:13 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz C6B40F80524 Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key) header.d=amd.com header.i=@amd.com header.b="g1q+mkG2" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=YJhxiOo62KmR2uE6Mzz97yYQ+gn8+lyHcjpjRfqnnDd+X+Ob4r2bpjWrhuzbd8lJ4xpqcda6tR/AQ4FWZHIximGe5N1e5zD7DbjghdaYxWpOYpdI8qOQYqYnw9kNGzPM3+M2W7kpbZE/hnwb+uLhVAUDDCXSAhlK3/vKE4MuLvjWdLi1dBBHkmUqaJSR72CqvlYX3uE3Pb1O10Vcqk4FXG45Io5EMnT5N0zsK5urdirD96eCC+wE9Ai7OypKEFJKagiVfDyX+0GI6tiJbuiSY2EspUihrkBU4Z2g8IdCfiNmnKwPEdkSB6eXeW1eK1lWd8y/cYFeSKWM0vQe1go9Tg== 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=OLUY6DlGAwjdwdzQLNA/gt8yUAg6SwxroiCRgpkoduo=; b=adskn2u6t9d5i0o7ywVkyUkFNl0mVgaIJeLPmodlzt6HQ6S9K0Yb79qKVfExU5xOMxdx+6dN91efxQ1egy2DIzXLmKSxJ0PAds/6sZGvNXISdwo+xHAZEZggLy4pg/liYymg0xYzn5i3CXFFiaQ7Kd3Sqy24mt90Vl1fxJkO7ylqxs6pd6JIz9WzSGJCldiCvkwdxxv2HUAe/xZiLbjYMCnZgmUA4WhLrpeUY/1fz2vqDSh7anCre+YUHYFR4hfvIho5PVeJJ1QzkzwLoN3dtDiru0nQmUlniFaRjXLOf8RielMgNizyFnYRucfAmBodp2u7ewnNbd/4fb4ty3mAvw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=OLUY6DlGAwjdwdzQLNA/gt8yUAg6SwxroiCRgpkoduo=; b=g1q+mkG2kW6chSdzDahgsrVQ1R46Dq24YH0nx3yAQMRCerZPbc6RRq6rA/uL7/fCOQ6LwzjC0D/Ug37MP+ZKxSp4Z11yIXxmjRw2f/J6ihbyODNYeFdYlu4FdMxoxyAVTR4FmI8YIUElbymxBWiv0Gkg3DKounUoK9XU5Uz66Kw= Received: from CO2PR04CA0182.namprd04.prod.outlook.com (2603:10b6:104:5::12) by BN9PR12MB5067.namprd12.prod.outlook.com (2603:10b6:408:134::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4995.16; Wed, 23 Feb 2022 07:25:09 +0000 Received: from CO1NAM11FT052.eop-nam11.prod.protection.outlook.com (2603:10b6:104:5:cafe::61) by CO2PR04CA0182.outlook.office365.com (2603:10b6:104:5::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5017.23 via Frontend Transport; Wed, 23 Feb 2022 07:25:08 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; Received: from SATLEXMB04.amd.com (165.204.84.17) by CO1NAM11FT052.mail.protection.outlook.com (10.13.174.225) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5017.22 via Frontend Transport; Wed, 23 Feb 2022 07:25:08 +0000 Received: from SATLEXMB04.amd.com (10.181.40.145) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.18; Wed, 23 Feb 2022 01:25:04 -0600 Received: from LinuxHost.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server id 15.1.2375.18 via Frontend Transport; Wed, 23 Feb 2022 01:25:01 -0600 From: Vijendar Mukunda To: , Subject: [PATCH 8/9] ASoC: amd: vg: remove warnings and erros pointed out by checkpatch pl Date: Wed, 23 Feb 2022 12:49:37 +0530 Message-ID: <20220223071959.13539-8-Vijendar.Mukunda@amd.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220223071959.13539-1-Vijendar.Mukunda@amd.com> References: <20220223071959.13539-1-Vijendar.Mukunda@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 9c110a07-c675-4d91-a4f3-08d9f69d9ec5 X-MS-TrafficTypeDiagnostic: BN9PR12MB5067:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: l6zeDD2C3xVQkqIWcZcgtZOT7I8w8ZX0KZE9opm/0rbtwXiggH04Dlpbr9uiYUATH1iHyGAlKfA08FXnu3iBeD7JhodJxYe7DDQ0aWJNb7GFwhiwo5yQgAoUJFfl8CVN+qORwgfE3uKX6DVBfGj6hD80nPoFsp4Zr3bikXmeCk3kw1SYyADW7Mc1YvEaCW7WpzGt6ezAC52zUYjktgzwEbDQYO6UOmKmGcaArJ8VXGJgprC2X7/TBWpPN1n6TjAxbO6XE8e6F7pe5it6SSvPHXF9tgyYQJYidkNVE0rEq1Z4pKlD8zvOXT0NgUIgfCj2XKPpMyCLDxazWKui77lXb6XdvV3ZQFUllXAJnzy0FY2ZoG4avnSifFYz2U8Hf1k7c/M+GKPPTfJSAWwJTGGLYajd/4ey4jg5O1u4YO9Vz7FQWGZEvPJRYyadlFVk3Gk34hSZIBnSskqxDRb50HGYZe29xXhpa+rqm9LL7fpU0mdHQYbAEjx7IIKBSPzUHKxdixWBhmBhe560COneddWEtVyhznEW5Fv8nC2gtxH7myhK1gi8TKnJqxViPhfXBruGcSQZ1C+eU2Wf3ixTEzUqyuRFvrg6wON0eSV/hJ/khglz4usbWeX2pafQh/X9qrY2/TqTKqNrpHHRwYEY3kyRuRm+haA7p5yDzI50rrxRyMNpUKJYTjsudJJuzRW5jTe7hFBGgdAO6GIuBqIkebwZgQ== X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB04.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230001)(4636009)(46966006)(36840700001)(40470700004)(186003)(26005)(36860700001)(70586007)(2616005)(70206006)(7696005)(82310400004)(6666004)(86362001)(54906003)(8676002)(508600001)(110136005)(316002)(1076003)(356005)(81166007)(336012)(83380400001)(426003)(4326008)(47076005)(5660300002)(40460700003)(2906002)(8936002)(36756003)(4744005)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Feb 2022 07:25:08.1968 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 9c110a07-c675-4d91-a4f3-08d9f69d9ec5 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CO1NAM11FT052.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN9PR12MB5067 Cc: Sunil-kumar.Dommati@amd.com, wtli@nuvoton.com, open list , Takashi Iwai , Liam Girdwood , Vijendar Mukunda , Alexander.Deucher@amd.com, krisman@collabora.com X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 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: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" Fix checkpatch pl errors and warnings in vangogh machine driver. Signed-off-by: Vijendar Mukunda --- sound/soc/amd/vangogh/acp5x-mach.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sound/soc/amd/vangogh/acp5x-mach.c b/sound/soc/amd/vangogh/acp5x-mach.c index 287efd9282db..c574e80907f0 100644 --- a/sound/soc/amd/vangogh/acp5x-mach.c +++ b/sound/soc/amd/vangogh/acp5x-mach.c @@ -341,7 +341,6 @@ static struct snd_soc_card acp5x_card = { .num_controls = ARRAY_SIZE(acp5x_8821_controls), }; - static int acp5x_vg_quirk_cb(const struct dmi_system_id *id) { acp5x_machine_id = VG_JUPITER; @@ -371,7 +370,7 @@ static int acp5x_probe(struct platform_device *pdev) return -ENOMEM; dmi_check_system(acp5x_vg_quirk_table); - switch(acp5x_machine_id) { + switch (acp5x_machine_id) { case VG_JUPITER: card = &acp5x_card; acp5x_card.dev = &pdev->dev; From patchwork Wed Feb 23 07:19:38 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Mukunda,Vijendar" X-Patchwork-Id: 12756508 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 371CAC433FE for ; Wed, 23 Feb 2022 07:27:15 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 754AF1A60; Wed, 23 Feb 2022 08:26:23 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 754AF1A60 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1645601233; bh=7K1dBeIF0M4dMEVqDLl5D9gUvJ2I7OzzqZeCH2TZEnw=; h=From:To:Subject:Date:In-Reply-To:References:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=rSK+6yF/lNV12o7SZw7kVPicJKw9SDThqdS9a8Opyidno6LAY/XPCT9ME5Fc2kZcq 2zKYFqganMQtc/RHJeEjYqFRVHXASKLJ40u607xsABGwfkDTGxba+mfxSOONObliEh QaJ8TUT4LILIrGBC9/OBMcX9RhLP/CBFSxEvcP/Q= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 5A1D5F802A0; Wed, 23 Feb 2022 08:25:27 +0100 (CET) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 2FA52F8052E; Wed, 23 Feb 2022 08:25:26 +0100 (CET) Received: from NAM04-BN8-obe.outbound.protection.outlook.com (mail-bn8nam08on20625.outbound.protection.outlook.com [IPv6:2a01:111:f400:7e8d::625]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id DAE47F8052D for ; Wed, 23 Feb 2022 08:25:23 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz DAE47F8052D Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key) header.d=amd.com header.i=@amd.com header.b="0JWB/TJ5" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=jVf8p5Z5p/EA7QAT135jabXs9DjP6liX/A0xgnFudTEoXF4avuX0e4RHwi3Pg71dDd7FIMfx829GvC77mTFkag4wBD2iIQa0hUfKLnWM0RP7onv2vdCoPpl+/yB4FDH4J2aZAawjJUVG3btTHA04GtpmPuMVbMbG4pxRCjCnbEAg+U9w+meRIsOwvRfXvGS2Lgp/y96Wa/C4kIsUpUYiz0gdNJkkJApvxGrD5guTTyvZSqRNItvbqxx9zcv/nd+sbwxcEjFn+W3xPRzVAd9zrmV5KIA8hOzJ0oUSjc3rrQBpY3QI3SFQ+qv7Tdl+XigCsS8zS5YGv1HbMM2Bt3HT9Q== 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=HC4ndKkpKXKWwiRAMnVGzBo7zxZ8TlguMupPQfnxF50=; b=ecWyta1tTxxf8O4q7V9vP9j6hNqnPaR7InqtSUFK8NGYnxjcLZ0LEAWa8/tcBEe37rzhjpPJ29UAhJnTJntgQCfvHQpeUrbGTbtTIg6Z1+2EYZEu230+b15pOm61qY5OSjM0+Y02J+i7doipDDd3eoqF9/pvg0FJwV7Ry5RCYP5YhdmpIBBT+LBxrYPDD6KjvotxqK5MH3wZB7EvxXkA35mSTHfJdElGdLi027z54C3Bz8cixp4PRU+k0JFY+WNgRqoN+7vWc9i1G4hmpOeebA3sLu94cSSD1aNK0/Bn4bxGwiqyIwcVvZWeN+psCCVJqKpGQORmyj8Ny1qCYp4Ydw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=HC4ndKkpKXKWwiRAMnVGzBo7zxZ8TlguMupPQfnxF50=; b=0JWB/TJ51pQLWKvFODxmxLAv5hB5zwdGVNih6Y99Beswq3tGCOpV6JUk1BqPLelnHwkrjBjVp3Ol83x8aMaFiy1u0Mc0fgd9LI+qatk3ywcRGhJoiFBia7eEO2vLtLWNgR9Ok3LFKvlrgAN6Dv/uCOEX72T5hNv+4hHX9D04Ovg= Received: from MW4P221CA0002.NAMP221.PROD.OUTLOOK.COM (2603:10b6:303:8b::7) by MN2PR12MB4390.namprd12.prod.outlook.com (2603:10b6:208:26e::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4995.16; Wed, 23 Feb 2022 07:25:18 +0000 Received: from CO1NAM11FT049.eop-nam11.prod.protection.outlook.com (2603:10b6:303:8b:cafe::47) by MW4P221CA0002.outlook.office365.com (2603:10b6:303:8b::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5017.22 via Frontend Transport; Wed, 23 Feb 2022 07:25:17 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; Received: from SATLEXMB04.amd.com (165.204.84.17) by CO1NAM11FT049.mail.protection.outlook.com (10.13.175.50) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5017.22 via Frontend Transport; Wed, 23 Feb 2022 07:25:17 +0000 Received: from SATLEXMB05.amd.com (10.181.40.146) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.18; Wed, 23 Feb 2022 01:25:15 -0600 Received: from SATLEXMB04.amd.com (10.181.40.145) by SATLEXMB05.amd.com (10.181.40.146) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.18; Wed, 23 Feb 2022 01:25:14 -0600 Received: from LinuxHost.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server id 15.1.2375.18 via Frontend Transport; Wed, 23 Feb 2022 01:25:12 -0600 From: Vijendar Mukunda To: , Subject: [PATCH 9/9] ASoC: amd: vangogh: fix uninitialized symbol warning in machine driver Date: Wed, 23 Feb 2022 12:49:38 +0530 Message-ID: <20220223071959.13539-9-Vijendar.Mukunda@amd.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220223071959.13539-1-Vijendar.Mukunda@amd.com> References: <20220223071959.13539-1-Vijendar.Mukunda@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 30aa2c90-155b-474e-cf06-08d9f69da478 X-MS-TrafficTypeDiagnostic: MN2PR12MB4390:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: F8wuWCBlam75QDvmi7hOQLnBHljZbInSLBcoW/ASINK3/pq0y2AFQAmqJ206Md1IG1j2TKzH6fh7BOoVfl6pjNRwCNoQVKFveM32qEW3H84Dwfz0DNRPmU1Iq7AoD3HhZkFa0viW9MjUgs8hT2fhu8SU9QE8h6fQThSaGXhKz1XutvU5/jgl0czSd0CtgW2R5W9poEJVvPMV1ZSMVdgv9g5g4SSvT/x2KwGkLEqg3jo0CJZoozaDexw/rNZSTqYL5tPpHH7SpRD3RibLi+UVWG1XBDU2yPtN3fM8Ojv3fJSSPWrs9u3e2srDYK/MsvgPyvEaTT83bcakVHq3kV7mTTlU466KeZDRw3/NE417z5VMamMajD6SFvtPva5G4SK3xcGwQItysLHp93NAU4YmHawd5rAzlSd0rspew0RRnMo60rqt5+21oXIvqycE2MVfyMFGe6818oHq3VUXwU0q7uZntizrrzQw8Xx3d4H3ezIsOkRNdtcPpvZsqy1qMo8rbZcTz5GV3rvVVCNmGembvw4dKyqMdPd6om+63P6QtenU1ZHiF3rYyQNMkUGw+lMQv3EaMZOgmz48u1UOti5U6oi/dNMI8c8Mpl6P/ThDOGPbYKJNB1CsW09tcA+Pzg97hxnsCPyp8ru/F0PBEYXjDnvIBry/49Lo16xUklkcwkWRzpy9TI4piwMzOSoO1yxJy+Q59sZkL/LH9V+a2HouMg== X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB04.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230001)(4636009)(40470700004)(46966006)(36840700001)(426003)(26005)(2616005)(186003)(336012)(1076003)(70206006)(70586007)(83380400001)(86362001)(6666004)(508600001)(110136005)(316002)(82310400004)(7696005)(54906003)(2906002)(36756003)(81166007)(5660300002)(356005)(4744005)(8936002)(40460700003)(36860700001)(4326008)(47076005)(8676002)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Feb 2022 07:25:17.7440 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 30aa2c90-155b-474e-cf06-08d9f69da478 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CO1NAM11FT049.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR12MB4390 Cc: Sunil-kumar.Dommati@amd.com, wtli@nuvoton.com, open list , Takashi Iwai , Liam Girdwood , Vijendar Mukunda , Alexander.Deucher@amd.com, krisman@collabora.com X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 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: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" Fixed below smatch static checker warning. sound/soc/amd/vangogh/acp5x-mach.c:190 acp5x_cs35l41_hw_params() error: uninitialized symbol 'ret'. Reported-by: Dan Carpenter Signed-off-by: Vijendar Mukunda --- sound/soc/amd/vangogh/acp5x-mach.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sound/soc/amd/vangogh/acp5x-mach.c b/sound/soc/amd/vangogh/acp5x-mach.c index c574e80907f0..5ae3de76283e 100644 --- a/sound/soc/amd/vangogh/acp5x-mach.c +++ b/sound/soc/amd/vangogh/acp5x-mach.c @@ -177,6 +177,7 @@ static int acp5x_cs35l41_hw_params(struct snd_pcm_substream *substream, unsigned int num_codecs = rtd->num_codecs; unsigned int bclk_val; + ret = 0; for (i = 0; i < num_codecs; i++) { codec_dai = asoc_rtd_to_codec(rtd, i); if ((strcmp(codec_dai->name, "spi-VLV1776:00") == 0) ||