Received: by 2002:a05:6358:7058:b0:131:369:b2a3 with SMTP id 24csp4548640rwp; Sun, 16 Jul 2023 05:58:41 -0700 (PDT) X-Google-Smtp-Source: APBJJlHomeqWSPPmZzNOhjftLgq4al8kB7XC9KfpfO+ro/DJ6jFin7DnbJq3w5atosy2fEkS1tSw X-Received: by 2002:a17:90a:68c8:b0:263:4815:cb9a with SMTP id q8-20020a17090a68c800b002634815cb9amr8917067pjj.41.1689512320753; Sun, 16 Jul 2023 05:58:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689512320; cv=none; d=google.com; s=arc-20160816; b=lQzOwIf+kxH8HHjceYi1TSquPe5fhrAlayRUdS+ZIdEe/gowFYGQrsw/5zeyWHDeqb GJ4Q4h2NVjBWjRZuh9gUyaHI/GbfaiZOz0Ek3SeZ0UPchEcSnC6WfGOqjJnSMMOQknUD AuSXzFP9LbQ/2LoPe5xy275UHgkDaBgXt8Aq6TyoQ/IPYJSDdbFxhK21rUDDedGfMjvp 8RBl2QCsltOhpIjB4n/iWyCfP1QXAO0mlz5zQEcfWTsqDeMyhrGpJ+1+YY0tnAKVW6dr vEFW9mEbwySQEu9u+cUSso1LxDKsuDJ+4bvxhPGm3O7nz5c3KNVq4LDnR6LU7B3eaGSx vUDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:user-agent:references:in-reply-to :subject:cc:to:from:message-id:date:dkim-signature:dkim-signature; bh=5iMTPDb4EAC5F/3a1KEzow3eeMPXGxYwXkQm53JlpR0=; fh=nbF4g+99YHDqB7RWtH7pz704/ceFHRt5DaRKL8DBsfs=; b=K3m6B8vPFJXML4+MtxgiCfE0aYSm4s9B++lH8Fd5yRVSbCvuJZwkxuFsNjHipfS4kc ub8iRK9QC0nEgG4hej/AERIFYwpuH862JpMiUrn1ZXSzOZKwhNFIwVq/yTeLR49831RF 0Rb/Y4EIldrNbjJ7FdVVPc+6gNznfanG23gA6OAz0Om5+fffrOcKER+frV/dQ0ygC8NN Z36p8n8zDKfFyK6swndMzcF7S3e3QD6fBjCeOPtAvUJHViVH9IC4/WswVpnV2MaGwEqf X9NjAXzLJPnxNpRWumgz4E+dsXN/QquPqXng0VakLh7s77amBofvrE8M/F8WJmVa9Dzn +5jA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=U6GnsSjk; dkim=neutral (no key) header.i=@suse.de; 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=suse.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id z11-20020a63d00b000000b0054f93b05b51si10500649pgf.96.2023.07.16.05.58.26; Sun, 16 Jul 2023 05:58:40 -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=@suse.de header.s=susede2_rsa header.b=U6GnsSjk; dkim=neutral (no key) header.i=@suse.de; 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=suse.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229471AbjGPMtY (ORCPT + 99 others); Sun, 16 Jul 2023 08:49:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50722 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229449AbjGPMtX (ORCPT ); Sun, 16 Jul 2023 08:49:23 -0400 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 170B490 for ; Sun, 16 Jul 2023 05:49:22 -0700 (PDT) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id AD8811F8BB; Sun, 16 Jul 2023 12:49:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1689511759; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=5iMTPDb4EAC5F/3a1KEzow3eeMPXGxYwXkQm53JlpR0=; b=U6GnsSjkB8EA2oqYEdpn9YsPhisH99afJCxcs2lQcOCQjwMKp+sY9lNIiSN3JZ5Gibkp8A UW3NaYJvNU7WpQVJfCGfYw1T1OPwE9KScUvdIHIMgBzyv0aYwzuFOlHNt/kDZmIwgJkFs8 EG8lHV/zBT8JU5A9r+J2ZQZ4j3+4Ohk= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1689511759; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=5iMTPDb4EAC5F/3a1KEzow3eeMPXGxYwXkQm53JlpR0=; b=kM/QMplGPX+11kosa/FGDTR6+A+YQeOCk7EzKmYXxppia6ZkgqIC3FU5BswNIKuHK7QTbB hjdsLTVTrXpzb4Ag== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 5E4D313252; Sun, 16 Jul 2023 12:49:19 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id n88vFk/ns2RyeQAAMHmgww (envelope-from ); Sun, 16 Jul 2023 12:49:19 +0000 Date: Sun, 16 Jul 2023 14:49:18 +0200 Message-ID: <87zg3waunl.wl-tiwai@suse.de> From: Takashi Iwai To: David Xu Cc: James Schulman , David Rhodes , Richard Fitzgerald , Jaroslav Kysela , Takashi Iwai , "Luke D. Jones" , Stefan Binding , Andy Chi , Tim Crawford , Philipp Jungkamp , Kacper =?ISO-8859-2?Q?Michaj=B3ow?= , Matthew Anderson , Yuchi Yang , Yang Yingliang , alsa-devel@alsa-project.org, patches@opensource.cirrus.com, linux-kernel@vger.kernel.org Subject: Re: [PATCH 0/2] Fix CSC3551 speaker sound problem for machines without a valid ACPI _DSD In-Reply-To: References: User-Agent: Wanderlust/2.15.9 (Almost Unreal) Emacs/27.2 Mule/6.0 MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, 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 On Thu, 13 Jul 2023 18:29:53 +0200, David Xu wrote: > > > As the comments added in commit 4d4c4bff4f8ed79d95e05 ("ALSA: hda: > cs35l41: Clarify support for CSC3551 without _DSD Properties"), CSC3551 > requires a valid _DSD to work and the current implementation just > fails when no _DSD can be found for CSC3551. However it is a fact > that many OEMs hardcoded the configurations needed by CSC3551 into their > proprietary software for various 2022 and later laptop models, > and this makes the Linux installations on these models cannot make > any speaker sound. Meanwhile, at this point of time, we see no hope > that these OEMs would ever fix this problem via a BIOS update. > > To address the problem, this patch series contains two patches: > > Patch 1 for cs35l41 hda driver: a fixup mechanism is introduced that > when the driver found there is no valid _DSD that contains the > configurations, a fixup function would try to find a fixup entry that > contains a proper cs35l41 configuration from a pre-defined fixup table > by matching the CSC3551 ACPI _SUB id. If found, the fixup function > would apply the cs35l41 configurations retrived from the entry. > In this patch the fixup table only contains some entries for three > Lenovo laptop models: namely 16IAH7, 16IAX7 and 16ARHA7. However > as is known, several other laptop models from ASUS and HP also suffer > from this no valid _DSD problem and could have it addressed with this > fixup mechanism when proper fixup entries are inserted. > > > Patch 2 for realtek hda driver: add quirks for Lenovo 16IAH7, 16IAX7 > and 16ARHA7 so that cs35l41 playback hook could be registered. Please > note that for these quirks to work patch 1 has to be applied. Thanks for the patches. I've seen the lots of pains with CS35L41 codec stuff on the recent machines. But, first of all, it still needs to be agreed by Cirrus people whether this approach is acceptable. Judging from the current situation, such workaround appears inevitable, but we need a consensus. So, Cirrus people, please check this. Also, some ideas about the current patch set: - Do we need yet another listing and check of each ID in another place? The existing entry in the SSID quirk table is already unique enough to identify which configuration is taken, I suppose. - The quirk entries can be gathered in patch_realtek.c, and the hw_cfg and other items are overwritten in cs35l41_no_acpi_dsd() when no _DSD is found. In that way, we can avoid fixing two places for each update. - The workaround is a workaround, and it's fundamentally dangerous. We should warn it in a kernel message. Takashi