Received: by 2002:a05:7412:8d09:b0:fa:4c10:6cad with SMTP id bj9csp339444rdb; Tue, 16 Jan 2024 01:41:34 -0800 (PST) X-Google-Smtp-Source: AGHT+IGZJZu2BGHN2AkOOdW/f8CAT/JUOOWHH6odiVj5ZcjhPFLJDgrTBPLQX5yY2gdi5Dpc0znY X-Received: by 2002:a17:906:1407:b0:a2b:d12c:ee41 with SMTP id p7-20020a170906140700b00a2bd12cee41mr2204546ejc.165.1705398094687; Tue, 16 Jan 2024 01:41:34 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1705398094; cv=none; d=google.com; s=arc-20160816; b=wEspbt2DKytKEHLhLLX7KfV8fm4rBKjz6bTFCe0FxquPmTeXN4aTX9ClJAib9z60vJ p0YxUr9MHHUA3Fkw7JYxLdkkyhWU7tUBvt1bxmQH8ERmvmWoUMFPHuJbl60NP6QXKZaX RNvCnxDRmpblL4Vw5mOKLPpKQerFXva1QznQAdAWIG/lZZQa5zQ2T6BR7GH7Heuev9rY kDPGy3cAhTUbHNz/EQrrBOnLbV9tXrGd9qD13B9ptmDtW+azQ2Rs3+PrfJUvJrjmbCef mh9BHP71iB45u93SWbLSTafeUZjfC+ppaIRkYxKK+F5CXEJKQo+ejzHp9LB5fC8jGZdf dXsg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from:dkim-signature; bh=k9S46FFOIcTtDktJtyTrgqPlqpA2gA1uXywl5vx698U=; fh=KKP8zTcQJ3oaRk5kFpZOVuVwNJRF3rULozot/hU/FVs=; b=UOmx57PVcK3ZU35DIF7Dd0qAxU020Pm1tA43hkrmYoxHmeneni1tECVwR93nsQP7Tm mCc3ItoI2jRsocDFGrWkEOB6PWtLQeba8NkE4bZ2jpp3gYmfpFX42xodOVzyr8ovJRjf NulFp8UthCwCVMP6DT14I0LMVnzSMfKQKQVGmFRWRSCQOvnFh2WcUIbeXf6rHGaz6FMP BymHb/quCDG9bkbq25ePWX9PltVEVmaGcI9mCc6Wkn9TFs4o9W++7rzLxSvHya96qU4i KSB5+0+YkUSA1il/QDteoiNFHrXqkkl08DaIoNB6soTjj4PaK1Oo5GJjBurUxc3iF6li kIhA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=H17B+xkE; spf=pass (google.com: domain of linux-kernel+bounces-27193-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-27193-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id l8-20020a170906230800b00a2bd212444asi4615176eja.281.2024.01.16.01.41.34 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 16 Jan 2024 01:41:34 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-27193-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=H17B+xkE; spf=pass (google.com: domain of linux-kernel+bounces-27193-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-27193-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 69D251F23D63 for ; Tue, 16 Jan 2024 09:41:34 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 0501C1B807; Tue, 16 Jan 2024 09:39:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="H17B+xkE" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3AEC9134A3; Tue, 16 Jan 2024 09:39:41 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 992B4C433B2; Tue, 16 Jan 2024 09:39:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1705397981; bh=TlySBWSiIs011eAGAHEWyYI6qGjt/pk2rn1iN0irWl4=; h=From:To:Cc:Subject:Date:From; b=H17B+xkEGVHEtGKliDYxogZ/iFp93RpvoeyRCC7L/U1116iXZwx/DRwOxAASDVsoC 8ikYJKhnMiaL8PzdFETwseq332b3/6CeIz25F9M7VXGVvQelUz7gH11CLshfUzwn5q r7+3bdX9o5WKNZNajjt1eBDxVAFFxXVvffcwzYKvcCZ5bzrhWwzeiA+ynr7nwod5an /lcqcTdH5ms0d658RIBUt0Sa71CDWlk45YZYzkeS0OeinrrwHwR0nq5g2OOHDxVy9S /CU6JdkdYqIXmxJunhEBr03ztRv7UsO2gmYjNgBrMCp2S2Y6kOnpsAUOgnYTj9hFx+ aOjuqKhW0uJZA== Received: from johan by xi.lan with local (Exim 4.96.2) (envelope-from ) id 1rPfv5-00053P-1G; Tue, 16 Jan 2024 10:39:44 +0100 From: Johan Hovold To: Mark Brown Cc: Srinivas Kandagatla , Banajit Goswami , Liam Girdwood , Jaroslav Kysela , Takashi Iwai , alsa-devel@alsa-project.org, linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org, Johan Hovold Subject: [PATCH 0/7] ASoC: qcom: volume fixes and codec cleanups Date: Tue, 16 Jan 2024 10:38:56 +0100 Message-ID: <20240116093903.19403-1-johan+linaro@kernel.org> X-Mailer: git-send-email 2.41.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit To reduce the risk of speaker damage the PA gain needs to be limited on machines like the Lenovo Thinkpad X13s until we have active speaker protection in place. Limit the gain to the current default setting provided by the UCM configuration which most user have so far been been using (due to a bug in the configuration files which prevented hardware volume control [1]). Included is also a related fix for the LPASS WSA macro driver, which was changing the digital gain setting behind the back of user space and which can result in excessive (or too low) digital gain. There are further Qualcomm codec driver that appear to manipulate various gain settings, but on closer inspection this turned out to be effectively dead code which can be removed. Johan [1] https://github.com/alsa-project/alsa-ucm-conf/pull/382 Johan Hovold (7): ASoC: qcom: sc8280xp: limit speaker volumes ASoC: codecs: lpass-wsa-macro: fix compander volume hack ASoC: codecs: lpass-wsa-macro: drop dead mixer-path gain hack ASoC: codecs: lpass-rx-macro: drop dead mixer-path gain hack ASoC: codecs: wcd9335: drop dead gain hacks ASoC: codecs: wcd934x: drop dead gain hacks ASoC: codecs: msm8916-wcd-digital: drop dead gain hacks sound/soc/codecs/lpass-rx-macro.c | 16 +--- sound/soc/codecs/lpass-wsa-macro.c | 19 +--- sound/soc/codecs/msm8916-wcd-digital.c | 26 +----- sound/soc/codecs/wcd9335.c | 115 ++++--------------------- sound/soc/codecs/wcd934x.c | 102 +++++----------------- sound/soc/qcom/sc8280xp.c | 8 +- 6 files changed, 53 insertions(+), 233 deletions(-) -- 2.41.0