From patchwork Sun Feb 26 12:49:57 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mark Brown X-Patchwork-Id: 13152397 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 D360BC6FA8E for ; Sun, 26 Feb 2023 12:51:30 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id E129C852; Sun, 26 Feb 2023 13:50:38 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz E129C852 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1677415889; bh=JEDiIUtaX6g3tzXr94u0tVLuH331wW8Kksrsq52VVaw=; h=From:Date:Subject:References:In-Reply-To:To:CC:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=uomsSBWnhwh2aatkWENVC5QpfCMgRLQRDNJxZ23iBOz5o1PgaBJSz372L2Z8CysG5 qBSHETXePFwOTjDjEjqhSSJ68U1mNPhLPFdoFl+h80vc/Qrp4Z0Jbge44TmHl9CKis 7L9Cq9BAaUgMeyD0lE01X22R17bFkbNwzZXGNOcA= Received: from mailman-core.alsa-project.org (mailman-core.alsa-project.org [10.254.200.10]) by alsa1.perex.cz (Postfix) with ESMTP id BCA42F804FE; Sun, 26 Feb 2023 13:50:25 +0100 (CET) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 3C024F80527; Sun, 26 Feb 2023 13:50:21 +0100 (CET) Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 75D8EF800DF for ; Sun, 26 Feb 2023 13:50:18 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 75D8EF800DF Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key, unprotected) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20201202 header.b=KJDl+HGr Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id B4837B80159; Sun, 26 Feb 2023 12:50:17 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id BB669C4339E; Sun, 26 Feb 2023 12:50:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1677415816; bh=JEDiIUtaX6g3tzXr94u0tVLuH331wW8Kksrsq52VVaw=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=KJDl+HGre8yXeUx2qaDrDi2wZvNZ2dIYmMUG1rcPYUNvYuSzehbaEh/fOnI5/IWNt qd1XCLGO/mvCyeWMu1+YPB2h/n2SjS7KNu0prq0VQ2EGUQies2if/laQpoMK/VkfKL 4als1i4T3HaS4Bea6b8FXV9R2FwynDxiowMh3L6MB3lPDDKvAAvuzCDb3nGvQg2wSj 9GGiOKXHVtZs8jFhn9qG5MEyLb16B5OpWUmpd7vSCZBIIqzR/A/rraz2ujnZt2DyfU nVcL9+iBGAPKuELGEKic7vJlBeqQU2b1VqRtpsyU3xHkJwgyI8FGVG9n/xJiCtBtUp XY3gaYU+0A8TQ== From: Mark Brown Date: Sun, 26 Feb 2023 12:49:57 +0000 Subject: [PATCH 2/2] ASoC: mt8183: Fix event generation for I2S DAI operations MIME-Version: 1.0 Message-Id: <20230224-asoc-mt8183-quick-fixes-v1-2-041f29419ed5@kernel.org> References: <20230224-asoc-mt8183-quick-fixes-v1-0-041f29419ed5@kernel.org> In-Reply-To: <20230224-asoc-mt8183-quick-fixes-v1-0-041f29419ed5@kernel.org> To: Liam Girdwood , Matthias Brugger , AngeloGioacchino Del Regno X-Mailer: b4 0.13-dev-ada30 X-Developer-Signature: v=1; a=openpgp-sha256; l=1295; i=broonie@kernel.org; h=from:subject:message-id; bh=JEDiIUtaX6g3tzXr94u0tVLuH331wW8Kksrsq52VVaw=; b=owEBbQGS/pANAwAKASTWi3JdVIfQAcsmYgBj+1WAnugavWTX+9Hg/IvfRmt51ua6j+yicn0pEbPH asQEgkeJATMEAAEKAB0WIQSt5miqZ1cYtZ/in+ok1otyXVSH0AUCY/tVgAAKCRAk1otyXVSH0CYYB/ 0YSxCulCFXlrJOmzm6bM8diam+8P0CaA2QdRk+4WzbchuF3GPtZYVkpLATCYcFkge0COsUx4/f25Ng DEm6IaKvDx3uPBKT6F2o2utQBxHYPzaotQ0l6AzJ/CakQC+7h0FKRcwjK5yEWYGT0Y4LoVeZStSKfu rvLgBlDdRsXMEDGzXAhDzzpuU9y22LBshUeP/DQZnhpzYxFtUOlvCA+Xzavgn7FpA9Wxeut5Ztpq3f xsAVW6NAEr6b4xUwsgMfUazDH6Hh2dwnDuj9DzhaVKP+QLRrMZeKKBNHRjjCE/RTJRSODi+FkaI/nE 4tr+kl9q1aYhrH7pGqFNzIEqt7tVnq X-Developer-Key: i=broonie@kernel.org; a=openpgp; fpr=3F2568AAC26998F9E813A1C5C3F436CA30F5D8EB Message-ID-Hash: 3NU7B44NBXSF6EEVNZFKQQG5A6RXAWAU X-Message-ID-Hash: 3NU7B44NBXSF6EEVNZFKQQG5A6RXAWAU X-MailFrom: broonie@kernel.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-alsa-devel.alsa-project.org-0; header-match-alsa-devel.alsa-project.org-1; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: =?utf-8?b?TsOtY29sYXMgRi4gUi4gQS4gUHJhZG8=?= , alsa-devel@alsa-project.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org, Mark Brown X-Mailman-Version: 3.3.8 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: ALSA control put() operations should return 0 if the value changed so that events can be generated appropriately for userspace but the custom control in the MT8183 I2S DAI driver doesn't do that, fix it. Signed-off-by: Mark Brown Reviewed-by: AngeloGioacchino Del Regno --- sound/soc/mediatek/mt8183/mt8183-dai-i2s.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sound/soc/mediatek/mt8183/mt8183-dai-i2s.c b/sound/soc/mediatek/mt8183/mt8183-dai-i2s.c index 38f7fa38ee95..8645ab686970 100644 --- a/sound/soc/mediatek/mt8183/mt8183-dai-i2s.c +++ b/sound/soc/mediatek/mt8183/mt8183-dai-i2s.c @@ -141,7 +141,7 @@ static int mt8183_i2s_hd_set(struct snd_kcontrol *kcontrol, struct mtk_base_afe *afe = snd_soc_component_get_drvdata(cmpnt); struct mtk_afe_i2s_priv *i2s_priv; struct soc_enum *e = (struct soc_enum *)kcontrol->private_value; - int hd_en; + int hd_en, change; if (ucontrol->value.enumerated.item[0] >= e->items) return -EINVAL; @@ -155,9 +155,10 @@ static int mt8183_i2s_hd_set(struct snd_kcontrol *kcontrol, return -EINVAL; } + change = i2s_priv->low_jitter_en != hd_en; i2s_priv->low_jitter_en = hd_en; - return 0; + return change; } static const struct snd_kcontrol_new mtk_dai_i2s_controls[] = {