Received: by 2002:ac0:aed5:0:0:0:0:0 with SMTP id t21csp2809261imb; Mon, 4 Mar 2019 15:03:06 -0800 (PST) X-Google-Smtp-Source: APXvYqxQYnNmpey539zlQXpPaMWFNAl1bf2Oc7DUMq2g0yTmFrfzAZ4a/a5lgL87oCT3A/5t/K8A X-Received: by 2002:a65:5108:: with SMTP id f8mr20665178pgq.441.1551740586681; Mon, 04 Mar 2019 15:03:06 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1551740586; cv=none; d=google.com; s=arc-20160816; b=bju6qN0keoOEYSROe5NR0DDLIVvycij+lfa6y/1jATjScmUMxmHtnF9QpMY52qpjwx +5EUvZ7NQWifMN42RcgOlmcXl4Nf+iz7fP98zFFelHzVqUsUkOvMMAuE4ObBfDmn4PiC O0uxS/VBjRpOZtZxitQd88r7asgfdoDthG83PRjOfua1h7QtlMuXQl/VWFU+MCgXl5wF rjUG/UFtUFBB8wU9jdYkQ5dFyAtuk6c0HVrN4k8XzWXpF16xrA2auOOgervzIHfBoFrX X93eDtkaMDnt15MZNdhsAsr4NnISq/C6BBcw3vVDitU8eqTqUTOSqWIF+3AMpBqtTzkt U9nA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=38oyutlsQ5kexa/+WoHvvQ0F1ScYRkzlE3zqMhCY8j0=; b=YQCkKXm1jYwkCiFA0HamE6QbxcgPM+mVubGo+mq4WYNo6SUC0fzBq5yHb9u3/ahvYx DOl0p6HBuoKqxdY7iKqw1qKq79gbcWi3BRsPoUKSR+jMDB2CabyLVMqVl8XI84U8upCH g8JLKV54s2fUCgcr6yyCjo0NQpqfpY9yZW3nXBautpONlVC2rZMVIUQa4FUfD5Uw1rDU gUUO6rW7vsYrWNxHgUPE+zu7XpTXiqG5v4h7hAkXjjsLVTt2q33ujy6BIkh7QIKiqQvO HA6wqD4KKRPTwc1rt9oYDYVWVMVYOjGdW1PrjQtMz9ZnPu9yEOxgeG237t91dqoUrNy7 MgAA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=fectyLr4; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f193si6104614pgc.510.2019.03.04.15.02.51; Mon, 04 Mar 2019 15:03:06 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=fectyLr4; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726585AbfCDXCI (ORCPT + 99 others); Mon, 4 Mar 2019 18:02:08 -0500 Received: from mail-ot1-f67.google.com ([209.85.210.67]:42999 "EHLO mail-ot1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726095AbfCDXCI (ORCPT ); Mon, 4 Mar 2019 18:02:08 -0500 Received: by mail-ot1-f67.google.com with SMTP id i5so5743723oto.9 for ; Mon, 04 Mar 2019 15:02:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=38oyutlsQ5kexa/+WoHvvQ0F1ScYRkzlE3zqMhCY8j0=; b=fectyLr4ji+lZzoSd5s2XiSOhpWmzcElGHNhfEqvtJcmjlA9E0GIjPl+tUEEVwXCuF 8i+uo5RvZBf4Dv1AAs4Inuv8TmGuSBjG5TpP7xF3aiohut6AxNNN+xHgk/4NkNKAZVly e2Y5tm0nDc9b7ow3UD1mQNDSV0Z9PizBvijjxqDMmfbl5obEmcA8hO3UIrUhHcMjPY29 JaNJTgbRg+cdDAqR6lRxVCS1yJ51TW+um02GQZG2c99ZQSoaFy+ifhaY7Gnae0XU1uO7 O3Da1j+OTHRmBOQ6mej1JbnzuyWTBP0Zb2Di46xMsu0seGxhLnknamE0u7Amp/hwN9aE KwqA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=38oyutlsQ5kexa/+WoHvvQ0F1ScYRkzlE3zqMhCY8j0=; b=cvYDvrvY0c8qfbURUTH8FAt7nXqor4kVhDd7XILxUwf9xpIj9GqnhYknSPHTZWL9TE iooKxJzC37glQnxcUpHqSkBVZsPbprnYnM41Ibulx5jzOkrbyuVuG2g50aaymE9QC7at 0sgtxFAdDYJWT/a89tFnIBGRPLNApMje4By338b2oLu5QVZAyHZaZfIwKgTSda+e4Aji 3Y/G3lcRAse6wOhr2b2ZJeOz1nisXV8a3LVO7/bDEXRjqH6BEE/6tD5GNYN8nTjdIphl dcN0SiyjobGk5VISP55EqUnLam6ooTFOyhLWLZrmpZRQKBCyj+Pb4vq8g6FRECqJ4dFZ rfLg== X-Gm-Message-State: APjAAAUgFryr+vIEaGxsbSeznaF4VhT8T0/GYVMNZucXcjaOPdrX6coh MmcONK3EbzrjEJY6GMpqAQ4hLgDx4Tb2xFwEmrS+Ug== X-Received: by 2002:a9d:7a87:: with SMTP id l7mr13492167otn.98.1551740526569; Mon, 04 Mar 2019 15:02:06 -0800 (PST) MIME-Version: 1.0 References: <20190214213729.21702-1-brendanhiggins@google.com> In-Reply-To: <20190214213729.21702-1-brendanhiggins@google.com> From: Brendan Higgins Date: Mon, 4 Mar 2019 15:01:55 -0800 Message-ID: Subject: Re: [RFC v4 00/17] kunit: introduce KUnit, the Linux kernel unit testing framework To: Kees Cook , Luis Chamberlain , shuah@kernel.org, Rob Herring , Kieran Bingham , Frank Rowand Cc: Greg KH , Joel Stanley , Michael Ellerman , Joe Perches , brakmo@fb.com, Steven Rostedt , "Bird, Timothy" , Kevin Hilman , Julia Lawall , linux-kselftest@vger.kernel.org, kunit-dev@googlegroups.com, Linux Kernel Mailing List , Jeff Dike , Richard Weinberger , linux-um@lists.infradead.org, Daniel Vetter , dri-devel , Dan Williams , linux-nvdimm , Knut Omang , devicetree , Petr Mladek , Sasha Levin , Amir Goldstein , Dan Carpenter , wfg@linux.intel.com Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Feb 14, 2019 at 1:38 PM Brendan Higgins wrote: > > This patch set proposes KUnit, a lightweight unit testing and mocking > framework for the Linux kernel. > > ## More information on KUnit > > There is a bunch of documentation near the end of this patch set that > describes how to use KUnit and best practices for writing unit tests. > For convenience I am hosting the compiled docs here: > https://google.github.io/kunit-docs/third_party/kernel/docs/ > Additionally for convenience, I have applied these patches to a branch: > https://kunit.googlesource.com/linux/+/kunit/rfc/5.0-rc5/v4 > The repo may be cloned with: > git clone https://kunit.googlesource.com/linux > This patchset is on the kunit/rfc/5.0-rc5/v4 branch. > > ## Changes Since Last Version > > - Got KUnit working on (hypothetically) all architectures (tested on > x86), as per Rob's (and other's) request > - Punting all KUnit features/patches depending on UML for now. > - Broke out UML specific support into arch/um/* as per "[RFC v3 01/19] > kunit: test: add KUnit test runner core", as requested by Luis. > - Added support to kunit_tool to allow it to build kernels in external > directories, as suggested by Kieran. > - Added a UML defconfig, and a config fragment for KUnit as suggested > by Kieran and Luis. > - Cleaned up, and reformatted a bunch of stuff. > > -- > 2.21.0.rc0.258.g878e2cd30e-goog > Someone suggested I should send the next revision out as "PATCH" instead of "RFC" since there seems to be general consensus about everything at a high level, with a couple exceptions. At this time I am planning on sending the next revision out as "[PATCH v1 00/NN] kunit: introduce KUnit, the Linux kernel unit testing framework". Initially I wasn't sure if the next revision should be "[PATCH v1 ...]" or "[PATCH v5 ...]". Please let me know if you have a strong objection to the former. In the next revision, I will be dropping the last two of three patches for the DT unit tests as there doesn't seem to be enough features currently available to justify the heavy refactoring I did; however, I will still include the patch that just converts everything over to KUnit without restructuring the test cases: https://lkml.org/lkml/2019/2/14/1133 I should have the next revision out in a week or so.