From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 44AC5C2D0CE for ; Sun, 29 Dec 2019 17:25:37 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 1C31D21D7E for ; Sun, 29 Dec 2019 17:25:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1577640337; bh=xS+lBwFLJzDnqF2B0UvTsY6AXhYlAT+VP+Vhr/nouYw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=lAOAPZ2ZGtdB4eTtFysyYTcnl1uMh1a6Yy66Fnb1GbKnSbkmNY7PcZNy4ygSpGdIT 1bfDi3QKQYM1ytRtP+Fvlc75A5/rWp0/J6HSU/GRwk9qZqvkeJh7WPFOJgPdks78NY p36xJR7AJ4wRa6OX4XURisCji812+c7KQ7P8g88I= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728011AbfL2RZf (ORCPT ); Sun, 29 Dec 2019 12:25:35 -0500 Received: from mail.kernel.org ([198.145.29.99]:45566 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728006AbfL2RZf (ORCPT ); Sun, 29 Dec 2019 12:25:35 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 5253720409; Sun, 29 Dec 2019 17:25:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1577640334; bh=xS+lBwFLJzDnqF2B0UvTsY6AXhYlAT+VP+Vhr/nouYw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=VvNfArV/2t4WXQvfg5CBMjq7w1RoxsjDNTVGmH9+oZzA58BvFEJTXuFezHz7l6UyH cB/iaZPsDn6SsVWMtXAFGXBCeVUZ3L3ROfSkwpohVA+L5KW7HsOo7N+Sq7RFSOlo0c bnvdxmwb2sqR5H7r/9uVSVxNCI5L/ElAqPY7+jYA= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Yu-Hsuan Hsu , Pierre-Louis Bossart , Mark Brown , Sasha Levin Subject: [PATCH 4.14 114/161] ASoC: Intel: kbl_rt5663_rt5514_max98927: Add dmic format constraint Date: Sun, 29 Dec 2019 18:19:22 +0100 Message-Id: <20191229162431.989230651@linuxfoundation.org> X-Mailer: git-send-email 2.24.1 In-Reply-To: <20191229162355.500086350@linuxfoundation.org> References: <20191229162355.500086350@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Yu-Hsuan Hsu [ Upstream commit e2db787bdcb4f2722ecf410168f0583764634e45 ] On KBL platform, the microphone is attached to external codec(rt5514) instead of PCH. However, TDM slot between PCH and codec is 16 bits only. In order to avoid setting wrong format, we should add a constraint to force to use 16 bits format forever. Signed-off-by: Yu-Hsuan Hsu Acked-by: Pierre-Louis Bossart Link: https://lore.kernel.org/r/20190923162940.199580-1-yuhsuan@chromium.org Signed-off-by: Mark Brown Signed-off-by: Sasha Levin --- sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c b/sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c index 41cb1fefbd42..405196283688 100644 --- a/sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c +++ b/sound/soc/intel/boards/kbl_rt5663_rt5514_max98927.c @@ -422,6 +422,9 @@ static int kabylake_dmic_startup(struct snd_pcm_substream *substream) snd_pcm_hw_constraint_list(runtime, 0, SNDRV_PCM_HW_PARAM_CHANNELS, dmic_constraints); + runtime->hw.formats = SNDRV_PCM_FMTBIT_S16_LE; + snd_pcm_hw_constraint_msbits(runtime, 0, 16, 16); + return snd_pcm_hw_constraint_list(substream->runtime, 0, SNDRV_PCM_HW_PARAM_RATE, &constraints_rates); } -- 2.20.1