Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp6139771iog; Thu, 23 Jun 2022 12:10:23 -0700 (PDT) X-Google-Smtp-Source: AGRyM1ut3hf0MiOKE9g/LNa/Auq6toaBic3QfuYm+ER1G7U487m5pNu1WGXTOUffNkcOCSQ7Ahqs X-Received: by 2002:a17:902:d4c8:b0:16a:480b:b781 with SMTP id o8-20020a170902d4c800b0016a480bb781mr9834663plg.79.1656011423260; Thu, 23 Jun 2022 12:10:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1656011423; cv=none; d=google.com; s=arc-20160816; b=vMOIo02DnqFVv6+PR2Ts83v6H9vsJ9MYkKcU4kaYNv+oL+3UD04/tonYOK66WkANpa k1GWa4YTk3IesE1RJSlYM7D2sZXiNIS5z5xf0GCtN0mB5nTHtm5eYiDEccqZJOjitpOV uKQI5UbRhMxlRLmBNmrUOBMUPRMkUC64f3EOgnBk2L63Ik5eEX8QyFw+pgUEyYnlFiUV IBgLJ3nVoUIgP/T+j673BR/FAmsKv7juFwUeDXtg5r5tDUiBWf8NNauUGjTw4Jfpy4We YOs9QeIOjiKV7mzBV6+85RsYWKWnjTmWULsyi6nXjkj+TCR7nS6HctodAdDLHZRNrYEb WIPg== 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=0EjuxEZU1QX8cd4j0dxdOG1klLuY0pRhTZfJIHrB9Pg=; b=g2CWB8zuoEU0uPk2b/FhdfhHzno/WhxA4G2y/ZqLe7NrrnTbjKY2TK2GoezZ778qYa BmdJoRIkTJ2K0NdDrZ9gvsbpRHdZF2tFp2qsUTHTx8NDetQPyka20aRxYjxjRIqGjOk5 3DPTERmcGmXzNaTerky61CxyDX+wyrO+0ZLeM0MZKD1DneNIsCy7utUudXu6mMScxXH9 Z3kACrIJcPB50WdY2QazTmYFF+CCp3+Auu1925yJfNu1Dk9ypKSToDCRhTM6ZRbDbMKb T8S3s/D/eN7fkBc7GeuOOgIFSZwF8cLzKSY7LrZS4CF22YB2HEI0EVBw/a6HbF/mRkb4 Onpg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=hh4lXVn9; 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 p20-20020a17090ad31400b001ead1c2f859si3691236pju.187.2022.06.23.12.10.12; Thu, 23 Jun 2022 12:10:23 -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=hh4lXVn9; 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 S236745AbiFWSQJ (ORCPT + 99 others); Thu, 23 Jun 2022 14:16:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42026 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236632AbiFWSP2 (ORCPT ); Thu, 23 Jun 2022 14:15:28 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E77C982893; Thu, 23 Jun 2022 10:21:51 -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 A65DBB82490; Thu, 23 Jun 2022 17:21:50 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 04CADC3411B; Thu, 23 Jun 2022 17:21:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1656004909; bh=ADtRrt3V39JZgtjHY/+41M5NR/geQPE2msmcwBrkHyw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=hh4lXVn93+so+ELIl35w55mv4iLJjlPDNQmfwYdrVnY4ou3jlQwIG4wu1uP4KWu+J pJROITnoxMmwWp4R3RE0XndpPLZCagWb02f0YyfT3FKc74ihe+Dkgp2/cau0VowdXT BQnJGVPediLl5Q5S4Eymsa/n6ukdNd8lqMJ0nqaM= 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 4.19 189/234] ASoC: wm_adsp: Fix event generation for wm_adsp_fw_put() Date: Thu, 23 Jun 2022 18:44:16 +0200 Message-Id: <20220623164348.397071709@linuxfoundation.org> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220623164343.042598055@linuxfoundation.org> References: <20220623164343.042598055@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 02c557e1f779..c5b0b56d9c94 100644 --- a/sound/soc/codecs/wm_adsp.c +++ b/sound/soc/codecs/wm_adsp.c @@ -697,7 +697,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