From patchwork Wed Jul 12 15:40:35 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mark Brown X-Patchwork-Id: 701866 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 205EDC0015E for ; Wed, 12 Jul 2023 15:42:44 +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 0B8B8851; Wed, 12 Jul 2023 17:41:52 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 0B8B8851 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1689176562; bh=zjgQNRJt1XUpdg7Bhx4u4P1bq8NwhLvKyp3fTanEiyY=; h=From:Date:Subject:References:In-Reply-To:To:Cc:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=F7SmKj0pO7pZ1GN+Q9+3p3Sz6SGi+YvBx2996qSA8rM/UpemJKnUpFmrDI0PpwK1J lR4XKs4nNrDfBj0miV6k9gh4FXu2sgvQm6TEY6AAOLx6f6OBc62tpgl2JSNwLPzmm1 LbcsceUP15SPmZIGp5yQEkwZ2TGlh0heOmnTFSQs= Received: by alsa1.perex.cz (Postfix, from userid 50401) id 864A0F80567; Wed, 12 Jul 2023 17:41:03 +0200 (CEST) Received: from mailman-core.alsa-project.org (mailman-core.alsa-project.org [10.254.200.10]) by alsa1.perex.cz (Postfix) with ESMTP id BBA80F80549; Wed, 12 Jul 2023 17:41:02 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 6DCEEF8024E; Wed, 12 Jul 2023 17:40:59 +0200 (CEST) Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id B13E4F80236 for ; Wed, 12 Jul 2023 17:40:52 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz B13E4F80236 Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key, unprotected) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20201202 header.b=CZ5D9Sdw Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 7525C61828; Wed, 12 Jul 2023 15:40:50 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4FEF1C433B6; Wed, 12 Jul 2023 15:40:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1689176449; bh=zjgQNRJt1XUpdg7Bhx4u4P1bq8NwhLvKyp3fTanEiyY=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=CZ5D9Sdwfu9ZqoJ/LYu8HriOln5IMNmUHz/6YmC20LP+oPnaMwty8/emtBbS6hwvE j2t3CeVTI7hU71R3l1K3BO0yDh5HX7thtIPRX1z5ICD1zFwRev3LwAaXr0i+sRreP1 5j3QGeHX5BB0YC6rOfGYiFMXiVqHPuEzdOvnhUsphsEcmwSsZNoL0fq4llV6bKBjsK dcPCnJkWtkz0aDmO2mIyr1UQDaRugAf+PX0SgRGcEpLn+GQ55kNJD9aYIdXyGiPWYF L7NZDCJ1/+ae4ZyZVVJMUs4h24908pmC4YKmh4fMunIC4Ps09BaCdRDHDR14XAvr2c zwiSbOxXNLt6g== From: Mark Brown Date: Wed, 12 Jul 2023 16:40:35 +0100 Subject: [PATCH 2/2] ASoC: topology: Add explicit build option MIME-Version: 1.0 Message-Id: <20230712-asoc-topology-kunit-enable-v1-2-b9f2da9dca23@kernel.org> References: <20230712-asoc-topology-kunit-enable-v1-0-b9f2da9dca23@kernel.org> In-Reply-To: <20230712-asoc-topology-kunit-enable-v1-0-b9f2da9dca23@kernel.org> To: Liam Girdwood , Brendan Higgins , David Gow , Jaroslav Kysela , Takashi Iwai Cc: alsa-devel@alsa-project.org, linux-kselftest@vger.kernel.org, kunit-dev@googlegroups.com, Mark Brown X-Mailer: b4 0.13-dev-099c9 X-Developer-Signature: v=1; a=openpgp-sha256; l=1838; i=broonie@kernel.org; h=from:subject:message-id; bh=zjgQNRJt1XUpdg7Bhx4u4P1bq8NwhLvKyp3fTanEiyY=; b=owEBbQGS/pANAwAKASTWi3JdVIfQAcsmYgBkrsl3xmJL5BTeryZ75BFB5e0i9AgK2lJCAkivk qP/R7QRI2yJATMEAAEKAB0WIQSt5miqZ1cYtZ/in+ok1otyXVSH0AUCZK7JdwAKCRAk1otyXVSH 0JYsB/4ou0Z9CImBZWr0Ez9ziPcsF/+y/vnFExcwXXU1IsZnAw+0K9e0qQZQr+Dd3OXCYRlgioA NR8ahixDmhaApTUWVuEsn2gE+50dpTCWnydz+MVYnh5UBf6M390EOE1opDa0aUxlFic/PHZ/mvt TsGumyLM/UsODs36QvXw6Tj/pecV86uvTY7jg6SSC+tqiRRuEnvrIVgKEK02NlC/RRmv+fVuwHV sLvdWU+9XWjZ2zg+zSorYazJYteZkpqUay3/tZOR019Z7KLvCXt/EAJ07tOfI3aYdHrAr8URxLD umYvw3uptTrTp5aYQSg0FtSNM4PoEbLReDKFHR5Z+HVBQxvj X-Developer-Key: i=broonie@kernel.org; a=openpgp; fpr=3F2568AAC26998F9E813A1C5C3F436CA30F5D8EB Message-ID-Hash: RMR4IYKZJFQT47H77E7JHEZSQVTZ333Z X-Message-ID-Hash: RMR4IYKZJFQT47H77E7JHEZSQVTZ333Z X-MailFrom: broonie@kernel.org 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.8 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: The default KUnit build options are not supposed to enable any subsystems that were not already enabled but the topology code is a library which is generally selected by drivers that want to use it. Since KUnit is frequently run in virtual environments with minimal driver support this makes it difficult to enable the toplogy tests so provide an explicit Kconfig option which can be directly enabled when using KUnit, and also include this in the KUnit all_tests.config. Signed-off-by: Mark Brown Reviewed-by: David Gow --- sound/soc/Kconfig | 11 +++++++++++ tools/testing/kunit/configs/all_tests.config | 1 + 2 files changed, 12 insertions(+) diff --git a/sound/soc/Kconfig b/sound/soc/Kconfig index bfa9622e1ab1..439fa631c342 100644 --- a/sound/soc/Kconfig +++ b/sound/soc/Kconfig @@ -38,6 +38,17 @@ config SND_SOC_TOPOLOGY bool select SND_DYNAMIC_MINORS +config SND_SOC_TOPOLOGY_BUILD + bool "Build topology core" + select SND_SOC_TOPOLOGY + depends on KUNIT + help + This option exists to facilitate running the KUnit tests for + the topology core, KUnit is frequently tested in virtual + environments with minimal drivers enabled but the topology + core is usually selected by drivers. There is little reason + to enable it if not doing a KUnit build. + config SND_SOC_TOPOLOGY_KUNIT_TEST tristate "KUnit tests for SoC topology" depends on KUNIT diff --git a/tools/testing/kunit/configs/all_tests.config b/tools/testing/kunit/configs/all_tests.config index 13d15bc693fb..b8adb59455ef 100644 --- a/tools/testing/kunit/configs/all_tests.config +++ b/tools/testing/kunit/configs/all_tests.config @@ -39,3 +39,4 @@ CONFIG_SECURITY_APPARMOR=y CONFIG_SOUND=y CONFIG_SND=y CONFIG_SND_SOC=y +CONFIG_SND_SOC_TOPOLOGY_BUILD=y