From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.223.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 65DDE8121A for ; Mon, 29 Apr 2024 15:02:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=195.135.223.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714402976; cv=none; b=RnUuh6hNTalE/GrgUJYFPqtkpqE6AZ+IDCzOeFKpHihiIjSJ4zNpXVI5UiSv9D/SWt7cOLVAFLKUZ5wtdudwSzmI0kfcWWFr/moCHquUAIML/1LiQYZFGZDUNBS+J8aY4Kj+QW4WPSrXQPAj+htENVPWvFOC7wLvMFzi79jizp4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714402976; c=relaxed/simple; bh=miTWxwVdZbDlZpdmKVl7wyYlLIVCGSI4AfkWRG9XsGs=; h=Date:Message-ID:From:To:Cc:Subject:In-Reply-To:References: MIME-Version:Content-Type; b=pPqKtTEarYTKwy++azs+p6o0Nqh/sq6OvK5oC1OrRmewKCL4wWyW03AjfWSknqepyRACyKCuhzHgLMZresOVjh6tR3k0akVJoY7s6rGbqa4aX+Qi5bj1gdJZZgwElUC88NfzQbRiOe6H8ljXscaFZ//EQrSS2ujms7hbOsoebDU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=suse.de; spf=pass smtp.mailfrom=suse.de; dkim=pass (1024-bit key) header.d=suse.de header.i=@suse.de header.b=rCnAq+p9; dkim=permerror (0-bit key) header.d=suse.de header.i=@suse.de header.b=Wh4NHGGF; dkim=pass (1024-bit key) header.d=suse.de header.i=@suse.de header.b=lpCbELZ3; dkim=permerror (0-bit key) header.d=suse.de header.i=@suse.de header.b=PgYvQ55k; arc=none smtp.client-ip=195.135.223.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=suse.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=suse.de Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=suse.de header.i=@suse.de header.b="rCnAq+p9"; dkim=permerror (0-bit key) header.d=suse.de header.i=@suse.de header.b="Wh4NHGGF"; dkim=pass (1024-bit key) header.d=suse.de header.i=@suse.de header.b="lpCbELZ3"; dkim=permerror (0-bit key) header.d=suse.de header.i=@suse.de header.b="PgYvQ55k" Received: from imap1.dmz-prg2.suse.org (imap1.dmz-prg2.suse.org [10.150.64.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id A25511F449; Mon, 29 Apr 2024 15:02:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1714402973; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=rhynKhGQ4JRaS+p7qeBOoKEeBflNlibc5Py6TFNuPSY=; b=rCnAq+p9D5b+dI02+/FS+IpKWGEMQNpZOVGWiTdijhGy501pz3tIOxAUeOn3QYvrNhe84B 4WYTmiGuPkq6CRjEMdge60HGc5TCbgi2zoGb0EU7lx51yp4lvozAfp0xqcXmzuHt24hmUA EWguxiL/ipGKV82fQFDV+xhkPMu6OC0= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1714402973; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=rhynKhGQ4JRaS+p7qeBOoKEeBflNlibc5Py6TFNuPSY=; b=Wh4NHGGF6ocVUqNMvsE6IbZvRwoQ1f1UXpSCAoqd8LQB5pzuPE/Meuq/KLSOC6hI30/+uz QUKYK3r9SNkRcmAw== Authentication-Results: smtp-out2.suse.de; none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1714402972; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=rhynKhGQ4JRaS+p7qeBOoKEeBflNlibc5Py6TFNuPSY=; b=lpCbELZ3ONDfQjS5d+T26NqEf8z6WF0f5zzZw6pmQyY09qmwp8sVnNB6HkCKyaMMiwHd7L dhjq6YCOlfZScATikMf7ctuJRaDTGv2H884SICt7C7/pi145zwn7w+yhre1EYS7oRQrkNQ SW1lNkhaSQu9BXHpOKFkUiPQju371kk= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1714402972; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=rhynKhGQ4JRaS+p7qeBOoKEeBflNlibc5Py6TFNuPSY=; b=PgYvQ55kKm4HSARxg/u1W8jqh9cXFFfnZTb5LUzaUCVCcTQmuOwIjtwxRxroElqw9YvzOU 6UgA9pOtinnv8mCg== Received: from imap1.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap1.dmz-prg2.suse.org (Postfix) with ESMTPS id 6E9C2138A7; Mon, 29 Apr 2024 15:02:52 +0000 (UTC) Received: from dovecot-director2.suse.de ([10.150.64.162]) by imap1.dmz-prg2.suse.org with ESMTPSA id 2k2xGZy2L2YvFgAAD6G6ig (envelope-from ); Mon, 29 Apr 2024 15:02:52 +0000 Date: Mon, 29 Apr 2024 17:03:04 +0200 Message-ID: <8734r4p5xz.wl-tiwai@suse.de> From: Takashi Iwai To: Pierre-Louis Bossart Cc: linux-sound@vger.kernel.org, alsa-devel@alsa-project.org, broonie@kernel.org, Mauro Carvalho Chehab , Bard Liao , =?ISO-8859-1?Q?P=E9ter?= Ujfalusi Subject: Re: [PATCH] ALSA: hda: intel-dsp-config: harden I2C/I2S codec detection In-Reply-To: <20240426152818.38443-1-pierre-louis.bossart@linux.intel.com> References: <20240426152818.38443-1-pierre-louis.bossart@linux.intel.com> User-Agent: Wanderlust/2.15.9 (Almost Unreal) Emacs/27.2 Mule/6.0 Precedence: bulk X-Mailing-List: linux-sound@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Spam-Flag: NO X-Spam-Score: -2.83 X-Spam-Level: X-Spamd-Result: default: False [-2.83 / 50.00]; BAYES_HAM(-2.53)[97.89%]; MID_CONTAINS_FROM(1.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_SHORT(-0.20)[-0.998]; MIME_GOOD(-0.10)[text/plain]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; RCPT_COUNT_SEVEN(0.00)[7]; RCVD_TLS_ALL(0.00)[]; FUZZY_BLOCKED(0.00)[rspamd.com]; TO_DN_SOME(0.00)[]; FROM_HAS_DN(0.00)[]; DKIM_SIGNED(0.00)[suse.de:s=susede2_rsa,suse.de:s=susede2_ed25519]; FROM_EQ_ENVFROM(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; RCVD_COUNT_TWO(0.00)[2]; DBL_BLOCKED_OPENRESOLVER(0.00)[intel.com:email] On Fri, 26 Apr 2024 17:28:18 +0200, Pierre-Louis Bossart wrote: > > The SOF driver is selected whenever specific I2C/I2S HIDs are reported > as 'present' in the ACPI DSDT. In some cases, an HID is reported but > the hardware does not actually rely on I2C/I2S. This false positive > leads to an invalid selection of the SOF driver and as a result an > invalid topology is loaded. > > This patch hardens the detection with a check that the NHLT table is > consistent with the report of an I2S-based codec in DSDT. This table > should expose at least one SSP endpoint configured for an I2S-codec > connection. > > Tested on Huawei Matebook D14 (NBLB-WAX9N) using an HDaudio codec with > an invalid ES8336 ACPI HID reported: > > [ 7.858249] snd_hda_intel 0000:00:1f.3: DSP detected with PCI class/subclass/prog-if info 0x040380 > [ 7.858312] snd_hda_intel 0000:00:1f.3: snd_intel_dsp_find_config: no valid SSP found for HID ESSX8336, skipped > > Reported-by: Mauro Carvalho Chehab > Tested-by: Mauro Carvalho Chehab > Closes: https://github.com/thesofproject/linux/issues/4934 > Signed-off-by: Pierre-Louis Bossart > Reviewed-by: Bard Liao > Reviewed-by: Péter Ujfalusi Applied now. Thanks. Takashi