From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id A8EEAC7EE29 for ; Tue, 6 Jun 2023 16:12:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232681AbjFFQMz (ORCPT ); Tue, 6 Jun 2023 12:12:55 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48060 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237307AbjFFQMq (ORCPT ); Tue, 6 Jun 2023 12:12:46 -0400 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 36EA110D7; Tue, 6 Jun 2023 09:12:45 -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-out1.suse.de (Postfix) with ESMTPS id E05D921998; Tue, 6 Jun 2023 16:12:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1686067963; 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=tDS8AHR+6l5pU0D3pqB/j9UJ3eqzXU7CXq0Fenh1CAE=; b=OptcxMpQcKnCWmaZR2xro+4sgXmK9PuvO1jzEY0syZscIKVRr/nLOkwliN61O8845uNXi5 GT5dkptMzUzFqL2lXMw/QfdkFc7iFeTu+cXRsuOHegpiD36MwXwqpjseNeVsV28If0kpK3 SPLj+lUESLCfZj5Urxzl9XWDoTlLsiA= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1686067963; 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=tDS8AHR+6l5pU0D3pqB/j9UJ3eqzXU7CXq0Fenh1CAE=; b=tvPzVWUiurx4PtC5gkrfOcMaMPl2TYleMBtyaUPenBzIeoMg4O7lBsU99ycSSRTPFw9jjx TePHsGARLn5i6aBQ== 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 7700913519; Tue, 6 Jun 2023 16:12:43 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id Qf0zG/taf2RtNQAAMHmgww (envelope-from ); Tue, 06 Jun 2023 16:12:43 +0000 Date: Tue, 06 Jun 2023 18:12:43 +0200 Message-ID: <871qiofu2s.wl-tiwai@suse.de> From: Takashi Iwai To: Mark Brown Cc: Shenghao Ding <13916275206@139.com>, devicetree@vger.kernel.org, krzysztof.kozlowski+dt@linaro.org, robh+dt@kernel.org, lgirdwood@gmail.com, perex@perex.cz, pierre-louis.bossart@linux.intel.com, kevin-lu@ti.com, shenghao-ding@ti.com, alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org, x1077012@ti.com, peeyush@ti.com, navada@ti.com, gentuser@gmail.com, Ryan_Chu@wistron.com, Sam_Wu@wistron.com Subject: Re: [PATCH v4 5/6] ALSA: hda/tas2781: Add tas2781 HDA driver In-Reply-To: <65ef4914-dc0e-4f0f-a6f8-3016931488bd@sirena.org.uk> References: <20230527223613.11106-1-13916275206@139.com> <874jnkfu98.wl-tiwai@suse.de> <65ef4914-dc0e-4f0f-a6f8-3016931488bd@sirena.org.uk> 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 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 06 Jun 2023 18:10:13 +0200, Mark Brown wrote: > > On Tue, Jun 06, 2023 at 06:08:51PM +0200, Takashi Iwai wrote: > > Shenghao Ding wrote: > > > > + //Lenovo devices > > > + if ((subid == 0x387d) || (subid == 0x387e) || (subid == 0x3881) > > > + || (subid == 0x3884) || (subid == 0x3886) || (subid == 0x38a7) > > > + || (subid == 0x38a8) || (subid == 0x38ba) || (subid == 0x38bb) > > > + || (subid == 0x38be) || (subid == 0x38bf) || (subid == 0x38c3) > > > + || (subid == 0x38cb) || (subid == 0x38cd)) > > > + tas_priv->catlog_id = LENOVO; > > > + else > > > + tas_priv->catlog_id = OTHERS; > > > Hmm, I don't like checking subid here, but we can live with it for > > now... > > Might be more idiomatically/neatly written as a switch statement though. Yes, it'll make it easier to add a new entry, too. thanks, Takashi