From patchwork Tue Dec 19 16:22:32 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Binding X-Patchwork-Id: 755993 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 alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 214C2C41535 for ; Tue, 19 Dec 2023 16:24:07 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 04471DF6; Tue, 19 Dec 2023 17:23:55 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 04471DF6 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1703003045; bh=pU09p2rFamtHFZhGJRUNPXk2JnuIazbGtZhELzfiS/E=; h=From:To:CC:Subject:Date:In-Reply-To:References:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=EgdoE1xtnbTitZmv6H2XYYx63NM09sqC3ktBGQwQXBQI/QzV3KL3z+4WLn7mlK95G fkTV0sGonhK/cScltftemllilViF5ml1mz9klWqhX0EMT/vngOH56WY0oQmNQSxtMA 2+VYG9Y+JjcbFjSDizGEgzpr65hvbparQ8u5SHak= Received: by alsa1.perex.cz (Postfix, from userid 50401) id 11A09F805E8; Tue, 19 Dec 2023 17:23:05 +0100 (CET) Received: from mailman-core.alsa-project.org (mailman-core.alsa-project.org [10.254.200.10]) by alsa1.perex.cz (Postfix) with ESMTP id 31F4AF805ED; Tue, 19 Dec 2023 17:23:05 +0100 (CET) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 4E71AF80212; Tue, 19 Dec 2023 17:22:58 +0100 (CET) Received: from mx0b-001ae601.pphosted.com (mx0a-001ae601.pphosted.com [67.231.149.25]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id E8FF0F80425 for ; Tue, 19 Dec 2023 17:22:50 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz E8FF0F80425 Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key, unprotected) header.d=cirrus.com header.i=@cirrus.com header.a=rsa-sha256 header.s=PODMain02222019 header.b=WMCIphRa Received: from pps.filterd (m0077473.ppops.net [127.0.0.1]) by mx0a-001ae601.pphosted.com (8.17.1.24/8.17.1.24) with ESMTP id 3BJ6vo3B022423; Tue, 19 Dec 2023 10:22:48 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cirrus.com; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:content-type; s= PODMain02222019; bh=BoVaGh/eH7nGZeEelaU0i1uh/HBS9k3X4xBMik9sYek=; b= WMCIphRaeyGQRQFZZyGmYxGArGpBbrgP27CTR5/VHMj25AcWvM4YvtTF3Wsvf935 ZfZeJPYbKIZIH+enzPcKCsmWQO2MEUFvFj5pqGooSpJqDxlKLq4CiLMXbaXINekM Ebu0qAaMA6CQ8J8q/Tf/E/WOxoy/dM9P1LpYbvKhdVhl5WI5bSpjwT9YVlz1dEqm oHD2vqrDT5loHhvUyYbDFtVz1QpoC/nN3MOrajSLp0fG+6la04+/J+/S+Jc72hJ1 iBwrY+t/UR0FHDooruvX6vV+FFMn2jQiLEkCK0/NyZ9sQk8ezv0sR3UOWFAtZRF+ OpVY4TgSgRuEpPTm/CeWFw== Received: from ediex01.ad.cirrus.com ([84.19.233.68]) by mx0a-001ae601.pphosted.com (PPS) with ESMTPS id 3v1a6249gs-3 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 19 Dec 2023 10:22:48 -0600 (CST) Received: from ediex02.ad.cirrus.com (198.61.84.81) by ediex01.ad.cirrus.com (198.61.84.80) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.40; Tue, 19 Dec 2023 16:22:43 +0000 Received: from ediswmail.ad.cirrus.com (198.61.86.93) by anon-ediex02.ad.cirrus.com (198.61.84.81) with Microsoft SMTP Server id 15.2.1118.40 via Frontend Transport; Tue, 19 Dec 2023 16:22:43 +0000 Received: from sbinding-cirrus-dsktp2.ad.cirrus.com (unknown [198.90.238.77]) by ediswmail.ad.cirrus.com (Postfix) with ESMTP id 451DE11D1; Tue, 19 Dec 2023 16:22:43 +0000 (UTC) From: Stefan Binding To: Jaroslav Kysela , Takashi Iwai CC: , , , , "Stefan Binding" , kernel test robot Subject: [PATCH v1 2/2] ALSA: hda: cs35l41: Only add SPI CS GPIO if SPI is enabled in kernel Date: Tue, 19 Dec 2023 16:22:32 +0000 Message-ID: <20231219162232.790358-3-sbinding@opensource.cirrus.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231219162232.790358-1-sbinding@opensource.cirrus.com> References: <20231219162232.790358-1-sbinding@opensource.cirrus.com> MIME-Version: 1.0 X-Proofpoint-GUID: yc_jk4S_5prVHkTVfhZhHYzieyQxFs6b X-Proofpoint-ORIG-GUID: yc_jk4S_5prVHkTVfhZhHYzieyQxFs6b X-Proofpoint-Spam-Reason: safe Message-ID-Hash: EVWONUWN3M2RLCAU323UJDIMN74WMYGP X-Message-ID-Hash: EVWONUWN3M2RLCAU323UJDIMN74WMYGP X-MailFrom: prvs=7717b54677=sbinding@opensource.cirrus.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-alsa-devel.alsa-project.org-0; header-match-alsa-devel.alsa-project.org-1; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.9 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: If CONFIG_SPI is not set in the kernel, there is no point in trying to set the chip selects. We can selectively compile it. Fixes: 8c4c216db8fb ("ALSA: hda: cs35l41: Add config table to support many laptops without _DSD") Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202312192256.lJelQEoZ-lkp@intel.com/ Signed-off-by: Stefan Binding --- sound/pci/hda/cs35l41_hda_property.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sound/pci/hda/cs35l41_hda_property.c b/sound/pci/hda/cs35l41_hda_property.c index 73b304e6c83c..194e1179a253 100644 --- a/sound/pci/hda/cs35l41_hda_property.c +++ b/sound/pci/hda/cs35l41_hda_property.c @@ -210,6 +210,8 @@ static int generic_dsd_config(struct cs35l41_hda *cs35l41, struct device *physde if (cfg->bus == SPI) { cs35l41->index = id; + +#if IS_ENABLED(CONFIG_SPI) /* * Manually set the Chip Select for the second amp in the node. * This is only supported for systems with 2 amps, since we cannot expand the @@ -249,6 +251,7 @@ static int generic_dsd_config(struct cs35l41_hda *cs35l41, struct device *physde spi_setup(spi); } } +#endif } else { if (cfg->num_amps > 2) /*