Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp5556473pxu; Thu, 22 Oct 2020 05:39:22 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxl8a0GIgB9PIV+KoP7+XSLNSKMAbck2FkwpeYEwzIG046bSjqRzVaJkDPESAGE1Bi9RlIA X-Received: by 2002:a17:906:8053:: with SMTP id x19mr1991174ejw.139.1603370361939; Thu, 22 Oct 2020 05:39:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603370361; cv=none; d=google.com; s=arc-20160816; b=ulLkm9gNhDpYFsDEHzPrBF2nRQJ9Sf04iQJUxoEJbWR9J7er42FAqhdC0N3IwBQBiN jkOrh8Ul2R0OM8R6DfpOne5bwctDZ2gXxgJ6V2OKcpf68qlkB5A4dZn2xkGMiBThZag9 bhXrVr/V9DbDQW+5Un4oUsE9/KvLh+uVz2NzCtHSnzM38/bk/90e9arfj8fKMlxkdR+1 tsX5dk6W/af+RnhYQD9FG9cWJmc1pbmM+QWd/dCKynZXMNxrf1JNQArtMxDJxAlZTnVW WqSNTt02TMv1RmM7C4GT0FvwQMGLomA9e94gRFp+81z36yjj35wIv8VViLoh4TacsCzA 6zVg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from :dkim-signature; bh=xErA7tGVQTTJTfkYqLQRWA6Hey2ktgCsIWr/FG0tGeA=; b=X6Ydb5o9pkpDTsWvNYlNnkrcsWWjULMicqgupXkQUE8upjl5YtOMB7wYpdj+DuLQtA +QddOi5TgEH0EIW9rGQRO5I0M0kzJ+wFzImCjbx0QCa8wnRSHE5NeQu30eqqkkjyv2C6 z2sy6JUZR6dlXcBro6kAWbkriNvQpJqY6Wq2+rg9M63l/wXuKNp1ixAIPz0RZHsHaQFM mqz8Gme/VuCYflBLVmjjNxgy/C+Pilxd8pTl9Swfe6/n6G/6M88UFTni1yTdEn3mKASZ nPB1dRRKcLnCqMXuzk3gnSMOPN2KPr/ZHe5gpNjS6zFQhL0Rhh7fp3TQ2t+rR2Op6ydU s8Lw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amazon.com header.s=amazon201209 header.b=CpG3KbI+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a13si854576edx.563.2020.10.22.05.38.58; Thu, 22 Oct 2020 05:39:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@amazon.com header.s=amazon201209 header.b=CpG3KbI+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2442261AbgJUTcU (ORCPT + 99 others); Wed, 21 Oct 2020 15:32:20 -0400 Received: from smtp-fw-9101.amazon.com ([207.171.184.25]:61413 "EHLO smtp-fw-9101.amazon.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2411427AbgJUTcT (ORCPT ); Wed, 21 Oct 2020 15:32:19 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amazon.com; i=@amazon.com; q=dns/txt; s=amazon201209; t=1603308739; x=1634844739; h=from:to:cc:subject:date:message-id:mime-version; bh=xErA7tGVQTTJTfkYqLQRWA6Hey2ktgCsIWr/FG0tGeA=; b=CpG3KbI+xkc//2asM8AQRjb6zd8UJTvkOsFNeNyy+EteW4aG0240YIZj vd6VED89ESIwwNMNr60LnUSaRyBFJP4YSE8ZbZgkZfNjKUjdbSybsxD0o PHPlS8H7DW7UfjPcJLwcl7vD8117pTqcH8lDZweIhgoqnoxm2JYUQ6VEF Y=; X-IronPort-AV: E=Sophos;i="5.77,401,1596499200"; d="scan'208";a="78949982" Received: from sea32-co-svc-lb4-vlan3.sea.corp.amazon.com (HELO email-inbound-relay-2b-5bdc5131.us-west-2.amazon.com) ([10.47.23.38]) by smtp-border-fw-out-9101.sea19.amazon.com with ESMTP; 21 Oct 2020 19:25:40 +0000 Received: from EX13D31EUB001.ant.amazon.com (pdx4-ws-svc-p6-lb7-vlan3.pdx.amazon.com [10.170.41.166]) by email-inbound-relay-2b-5bdc5131.us-west-2.amazon.com (Postfix) with ESMTPS id 5001CA18DB; Wed, 21 Oct 2020 19:25:39 +0000 (UTC) Received: from u3f2cd687b01c55.ant.amazon.com (10.43.160.125) by EX13D31EUB001.ant.amazon.com (10.43.166.210) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Wed, 21 Oct 2020 19:25:33 +0000 From: SeongJae Park To: , CC: SeongJae Park , , , , , , Subject: [PATCH] Documentation: kunit: Update Kconfig parts for KUNIT's module support Date: Wed, 21 Oct 2020 21:25:18 +0200 Message-ID: <20201021192518.31187-1-sjpark@amazon.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.43.160.125] X-ClientProxiedBy: EX13D05UWB004.ant.amazon.com (10.43.161.208) To EX13D31EUB001.ant.amazon.com (10.43.166.210) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: SeongJae Park If 'CONFIG_KUNIT=m', letting kunit tests that do not support loadable module build depends on 'KUNIT' instead of 'KUNIT=y' result in compile errors. This commit updates the document for this. Fixes: 9fe124bf1b77 ("kunit: allow kunit to be loaded as a module") Signed-off-by: SeongJae Park Reviewed-by: David Gow --- Changes from v2 (https://lore.kernel.org/linux-kselftest/20201013063743.32179-1-sjpark@amazon.com/) - Fix a grammar issue (David Gow) - Add 'Reviewed-by: David Gow ' Changes from v1 (https://lore.kernel.org/linux-kselftest/20201012105420.5945-1-sjpark@amazon.com/) - Fix a typo (Marco Elver) --- Documentation/dev-tools/kunit/start.rst | 2 +- Documentation/dev-tools/kunit/usage.rst | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/Documentation/dev-tools/kunit/start.rst b/Documentation/dev-tools/kunit/start.rst index d23385e3e159..454f307813ea 100644 --- a/Documentation/dev-tools/kunit/start.rst +++ b/Documentation/dev-tools/kunit/start.rst @@ -197,7 +197,7 @@ Now add the following to ``drivers/misc/Kconfig``: config MISC_EXAMPLE_TEST bool "Test for my example" - depends on MISC_EXAMPLE && KUNIT + depends on MISC_EXAMPLE && KUNIT=y and the following to ``drivers/misc/Makefile``: diff --git a/Documentation/dev-tools/kunit/usage.rst b/Documentation/dev-tools/kunit/usage.rst index 961d3ea3ca19..62142a47488c 100644 --- a/Documentation/dev-tools/kunit/usage.rst +++ b/Documentation/dev-tools/kunit/usage.rst @@ -561,6 +561,11 @@ Once the kernel is built and installed, a simple ...will run the tests. +.. note:: + Note that you should make sure your test depends on ``KUNIT=y`` in Kconfig + if the test does not support module build. Otherwise, it will trigger + compile errors if ``CONFIG_KUNIT`` is ``m``. + Writing new tests for other architectures ----------------------------------------- -- 2.17.1