Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp2931076iog; Mon, 20 Jun 2022 07:44:11 -0700 (PDT) X-Google-Smtp-Source: AGRyM1tLGn9JZ05LcCp/RAG0rE9usLDh5rtIoXw3gJ5VFHph3ki5oVE8N+cvOwdBvw9HoB3RdlWS X-Received: by 2002:a17:90a:4cc3:b0:1ec:7bda:2e68 with SMTP id k61-20020a17090a4cc300b001ec7bda2e68mr18794601pjh.33.1655736250748; Mon, 20 Jun 2022 07:44:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1655736250; cv=none; d=google.com; s=arc-20160816; b=OVWiwOkSn1jHRpZIylI/i2+87FmApL/GXGchHyAtPloP0X/hfjrVE007bOmxqvCccM 5+B9iBWFJT4HyKEJJEpFc2l7S6ox2WCKDFxgv6M7uy4Ywef4Lxr86+oZSJWi2nHI6g1N FAP1j6isOhmL6V+OFVlOHLSqqrqGKN4B9I2IwM42UVS3ziMCPCTJNljHeEZjGcWqd6ln xILLE6feOEHU8LYZjGALBf0aM2KOgr2DZwsqFD00FzA/2Q+nM/yScqr74NveQ7vUYDEk /vZO2Nz7fGFja+8wdz/48upWfRdmv7sQ0Eylf2x89+z/rmlKNpYY0P09CKcOJucWzyW2 4JXA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=ZNBWqyyFa+xOL30QOowr8Io8JOsWeav+f93UoQ7MXoQ=; b=mPvJbmMfQtQctphLVGkIMvi5cxamLxQ+8sPgQSVJPAeuc2syEJq+05Y1R8sVoiIYuZ k2I4nbbbfdX6aBpLTsT6qoXdVDiwhYUJNNosXxfoI1R+Ondqw7A7mUGAW2JY+S3+S9nl GOmZY1Q6RVAEVHCMeq8hXpeKPrNmqq28otHc0eD8wF9PvoOc2aLwXsHJPa2SG8aXvQO2 snqtg505yAa4gnfpBi5H/M2FLPXJaAgVy03iJoGd5o6f2QLzkEjs5oINsH/Rry/Lz/xH n2TPTGbpHKIRnXh0pJukZVq0hLcwfTWcCxkJJfAqnj7GS6mIyO6gLswiUgxWxAuwM2M0 BGvw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=B4reRu58; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q4-20020a635044000000b003fd679770adsi13447983pgl.694.2022.06.20.07.43.58; Mon, 20 Jun 2022 07:44:10 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=B4reRu58; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242528AbiFTMyf (ORCPT + 99 others); Mon, 20 Jun 2022 08:54:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37230 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242989AbiFTMx7 (ORCPT ); Mon, 20 Jun 2022 08:53:59 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 42E8B17E06; Mon, 20 Jun 2022 05:53:53 -0700 (PDT) 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 E3BB6B811A5; Mon, 20 Jun 2022 12:53:51 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 55736C3411C; Mon, 20 Jun 2022 12:53:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1655729630; bh=QyA7bmOpgTHe++ypbwOYleAT8DYMiXUQDDhCe7vK3cc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=B4reRu58WatLWps4L5lDAlW/o/JTocbGs046dasQIoygkUCO1/8tMs5iOBsTBkMYF lVTqaD1zLFLxHtQc4FzY/SAxKBxiGbnXmOGAfS4uRducsgkDDtNFo9p1lu/hOnm6KY cbr1piQcy2kXRGNf1Fs5LzrLXU1Oe6XFKxnyersg= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Mark Brown , Richard Fitzgerald , Sasha Levin Subject: [PATCH 5.18 024/141] ASoC: wm_adsp: Fix event generation for wm_adsp_fw_put() Date: Mon, 20 Jun 2022 14:49:22 +0200 Message-Id: <20220620124730.243537395@linuxfoundation.org> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220620124729.509745706@linuxfoundation.org> References: <20220620124729.509745706@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Mark Brown [ Upstream commit 2abdf9f80019e8244d3806ed0e1c9f725e50b452 ] Currently wm_adsp_fw_put() returns 0 rather than 1 when updating the value of the control, meaning that no event is generated to userspace. Fix this by setting the default return value to 1, the code already exits early with a return value of 0 if the value is unchanged. Signed-off-by: Mark Brown Reviewed-by: Richard Fitzgerald Link: https://lore.kernel.org/r/20220603115003.3865834-1-broonie@kernel.org Signed-off-by: Mark Brown Signed-off-by: Sasha Levin --- sound/soc/codecs/wm_adsp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/codecs/wm_adsp.c b/sound/soc/codecs/wm_adsp.c index e32c8ded181d..9cfd4f18493f 100644 --- a/sound/soc/codecs/wm_adsp.c +++ b/sound/soc/codecs/wm_adsp.c @@ -333,7 +333,7 @@ int wm_adsp_fw_put(struct snd_kcontrol *kcontrol, struct snd_soc_component *component = snd_soc_kcontrol_component(kcontrol); struct soc_enum *e = (struct soc_enum *)kcontrol->private_value; struct wm_adsp *dsp = snd_soc_component_get_drvdata(component); - int ret = 0; + int ret = 1; if (ucontrol->value.enumerated.item[0] == dsp[e->shift_l].fw) return 0; -- 2.35.1