<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/Documentation/dev-tools/kunit, branch v5.17</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v5.17</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v5.17'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2022-02-08T20:16:20Z</updated>
<entry>
<title>Documentation: KUnit: Fix usage bug</title>
<updated>2022-02-08T20:16:20Z</updated>
<author>
<name>Akira Kawata</name>
<email>akirakawata1@gmail.com</email>
</author>
<published>2022-02-07T11:20:44Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=92a68053c3468705e2c7c752c9a3f256304a35a6'/>
<id>urn:sha1:92a68053c3468705e2c7c752c9a3f256304a35a6</id>
<content type='text'>
Fix a bug of kunit documentation.
Link: https://bugzilla.kernel.org/show_bug.cgi?id=205773

: Quoting Steve Pfetsch:
:
: kunit documentation is incorrect:
: https://kunit.dev/third_party/stable_kernel/docs/usage.html
: struct rectangle *self = container_of(this, struct shape, parent);
:
:
: Shouldn't it be:
: struct rectangle *self = container_of(this, struct rectangle, parent);
: ?

Signed-off-by: Akira Kawata &lt;akirakawata1@gmail.com&gt;
Reviewed-by: Brendan Higgins &lt;brendanhiggins@google.com&gt;
Signed-off-by: Shuah Khan &lt;skhan@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>Merge tag 'docs-5.17' of git://git.lwn.net/linux</title>
<updated>2022-01-11T18:00:04Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2022-01-11T18:00:04Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=6f38be8f2ccd9babf04b9b23539108542a59fcb8'/>
<id>urn:sha1:6f38be8f2ccd9babf04b9b23539108542a59fcb8</id>
<content type='text'>
Pull documentation updates from Jonathan Corbet:
 "This isn't a hugely busy cycle for documentation, but a few
  significant things still showed up:

   - A documentation section for ARC processors

   - Reworked and enhanced KUnit documentation

   - The ability to pick your own theme for HTML builds; if the default
     "Read the Docs" theme isn't ugly enough for you, you can now pick
     an uglier one.

   - More Chinese translation work

  Plus the usual assortment of fixes and cleanups"

* tag 'docs-5.17' of git://git.lwn.net/linux: (53 commits)
  scripts: sphinx-pre-install: Fix ctex support on Debian
  docs: discourage use of list tables
  docs: 5.Posting.rst: describe Fixes: and Link: tags
  Documentation: kgdb: Replace deprecated remotebaud
  docs: automarkup.py: Fix invalid HTML link output and broken URI fragments
  Documentation: refer to config RANDOMIZE_BASE for kernel address-space randomization
  Documentation: kgdb: properly capitalize the MAGIC_SYSRQ config
  docs/zh_CN: Update and fix a couple of typos
  scripts: sphinx-pre-install: add required ctex dependency
  Documentation: KUnit: Restyled Frequently Asked Questions
  Documentation: KUnit: Restyle Test Style and Nomenclature page
  Documentation: KUnit: Rework writing page to focus on writing tests
  Documentation: kunit: Reorganize documentation related to running tests
  Documentation: KUnit: Added KUnit Architecture
  Documentation: KUnit: Rewrite getting started
  Documentation: KUnit: Rewrite main page
  docs/zh_CN: Add zh_CN/accounting/delay-accounting.rst
  Documentation/sphinx: fix typos of "its"
  docs/zh_CN: Add sched-domains translation
  doc: fs: remove bdev_try_to_free_page related doc
  ...
</content>
</entry>
<entry>
<title>Documentation: KUnit: Restyled Frequently Asked Questions</title>
<updated>2021-12-23T19:49:43Z</updated>
<author>
<name>Harinder Singh</name>
<email>sharinder@google.com</email>
</author>
<published>2021-12-17T04:49:11Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=b36064425a18e29a3bad9c007b4dd1223f8aadc5'/>
<id>urn:sha1:b36064425a18e29a3bad9c007b4dd1223f8aadc5</id>
<content type='text'>
Reword to align with other chapters.

Signed-off-by: Harinder Singh &lt;sharinder@google.com&gt;
Reviewed-by: Brendan Higgins &lt;brendanhiggins@google.com&gt;
Link: https://lore.kernel.org/r/20211217044911.798817-8-sharinder@google.com
Signed-off-by: Jonathan Corbet &lt;corbet@lwn.net&gt;
</content>
</entry>
<entry>
<title>Documentation: KUnit: Restyle Test Style and Nomenclature page</title>
<updated>2021-12-23T19:49:43Z</updated>
<author>
<name>Harinder Singh</name>
<email>sharinder@google.com</email>
</author>
<published>2021-12-17T04:49:10Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=39150e80edf8bf8865a7d023e014f6dd13ef8a12'/>
<id>urn:sha1:39150e80edf8bf8865a7d023e014f6dd13ef8a12</id>
<content type='text'>
Rewrite page to enhance content consistency.

Signed-off-by: Harinder Singh &lt;sharinder@google.com&gt;
Reviewed-by: Brendan Higgins &lt;brendanhiggins@google.com&gt;
Link: https://lore.kernel.org/r/20211217044911.798817-7-sharinder@google.com
Signed-off-by: Jonathan Corbet &lt;corbet@lwn.net&gt;
</content>
</entry>
<entry>
<title>Documentation: KUnit: Rework writing page to focus on writing tests</title>
<updated>2021-12-23T19:49:43Z</updated>
<author>
<name>Harinder Singh</name>
<email>sharinder@google.com</email>
</author>
<published>2021-12-17T04:49:09Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=9535743906345f02f7bea2469a2137509db0ac4c'/>
<id>urn:sha1:9535743906345f02f7bea2469a2137509db0ac4c</id>
<content type='text'>
We now have dedicated pages on running tests. Therefore refocus the
usage page on writing tests and add content from tips page and
information on other architectures.

Signed-off-by: Harinder Singh &lt;sharinder@google.com&gt;
Reviewed-by: Tim Bird &lt;tim.bird@sony.com&gt;
Reviewed-by: Brendan Higgins &lt;brendanhiggins@google.com&gt;
Link: https://lore.kernel.org/r/20211217044911.798817-6-sharinder@google.com
Signed-off-by: Jonathan Corbet &lt;corbet@lwn.net&gt;
</content>
</entry>
<entry>
<title>Documentation: kunit: Reorganize documentation related to running tests</title>
<updated>2021-12-23T19:49:43Z</updated>
<author>
<name>Harinder Singh</name>
<email>sharinder@google.com</email>
</author>
<published>2021-12-17T04:49:08Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=46201d47d6c4be594c1d57b7f3251c371626a9c4'/>
<id>urn:sha1:46201d47d6c4be594c1d57b7f3251c371626a9c4</id>
<content type='text'>
Consolidate documentation running tests into two pages: "run tests with
kunit_tool" and "run tests without kunit_tool".

Signed-off-by: Harinder Singh &lt;sharinder@google.com&gt;
Reviewed-by: Tim Bird &lt;tim.bird@sony.com&gt;
Reviewed-by: Brendan Higgins &lt;brendanhiggins@google.com&gt;
Link: https://lore.kernel.org/r/20211217044911.798817-5-sharinder@google.com
Signed-off-by: Jonathan Corbet &lt;corbet@lwn.net&gt;
</content>
</entry>
<entry>
<title>Documentation: KUnit: Added KUnit Architecture</title>
<updated>2021-12-23T19:49:06Z</updated>
<author>
<name>Harinder Singh</name>
<email>sharinder@google.com</email>
</author>
<published>2021-12-17T04:49:07Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=bc145b370c11b92e497315f54636253f5af4323a'/>
<id>urn:sha1:bc145b370c11b92e497315f54636253f5af4323a</id>
<content type='text'>
Describe the components of KUnit and how the kernel mode parts
interact with kunit_tool.

Signed-off-by: Harinder Singh &lt;sharinder@google.com&gt;
Co-developed-by: Marco Elver &lt;elver@google.com&gt;
Signed-off-by: Marco Elver &lt;elver@google.com&gt;
Reviewed-by: Brendan Higgins &lt;brendanhiggins@google.com&gt;
Link: https://lore.kernel.org/r/20211217044911.798817-4-sharinder@google.com
Signed-off-by: Jonathan Corbet &lt;corbet@lwn.net&gt;
</content>
</entry>
<entry>
<title>Documentation: KUnit: Rewrite getting started</title>
<updated>2021-12-23T19:46:20Z</updated>
<author>
<name>Harinder Singh</name>
<email>sharinder@google.com</email>
</author>
<published>2021-12-17T04:49:06Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=c48b9ef1f7949e9024121702031775735e5d7418'/>
<id>urn:sha1:c48b9ef1f7949e9024121702031775735e5d7418</id>
<content type='text'>
Clarify the purpose of kunit_tool and fixed consistency issues

Signed-off-by: Harinder Singh &lt;sharinder@google.com&gt;
Reviewed-by: Brendan Higgins &lt;brendanhiggins@google.com&gt;
Link: https://lore.kernel.org/r/20211217044911.798817-3-sharinder@google.com
Signed-off-by: Jonathan Corbet &lt;corbet@lwn.net&gt;
</content>
</entry>
<entry>
<title>Documentation: KUnit: Rewrite main page</title>
<updated>2021-12-23T19:46:20Z</updated>
<author>
<name>Harinder Singh</name>
<email>sharinder@google.com</email>
</author>
<published>2021-12-17T04:49:05Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=6c6213f4a29b60d321ab2f2f20cdccd7604a7f95'/>
<id>urn:sha1:6c6213f4a29b60d321ab2f2f20cdccd7604a7f95</id>
<content type='text'>
Add a section on advantages of unit testing, how to write unit tests,
KUnit features and Prerequisites.

Signed-off-by: Harinder Singh &lt;sharinder@google.com&gt;
Reviewed-by: Brendan Higgins &lt;brendanhiggins@google.com&gt;
Link: https://lore.kernel.org/r/20211217044911.798817-2-sharinder@google.com
Signed-off-by: Jonathan Corbet &lt;corbet@lwn.net&gt;
</content>
</entry>
<entry>
<title>kunit: tool: reconfigure when the used kunitconfig changes</title>
<updated>2021-12-13T20:59:03Z</updated>
<author>
<name>Daniel Latypov</name>
<email>dlatypov@google.com</email>
</author>
<published>2021-11-19T23:23:16Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=4c2911f1e140b393d2c9920875911c992f8dda2c'/>
<id>urn:sha1:4c2911f1e140b393d2c9920875911c992f8dda2c</id>
<content type='text'>
Problem: currently, if you remove something from your kunitconfig,
kunit.py will not regenerate the .config file.
The same thing happens if you did --kunitconfig_add=CONFIG_KASAN=y [1]
and then ran again without it. Your new run will still have KASAN.

The reason is that kunit.py won't regenerate the .config file if it's a
superset of the kunitconfig. This speeds it up a bit for iterating.

This patch adds an additional check that forces kunit.py to regenerate
the .config file if the current kunitconfig doesn't match the previous
one.

What this means:
* deleting entries from .kunitconfig works as one would expect
* dropping  a --kunitconfig_add also triggers a rebuild
* you can still edit .config directly to turn on new options

We implement this by creating a `last_used_kunitconfig` file in the
build directory (so .kunit, by default) after we generate the .config.
When comparing the kconfigs, we compare python sets, so duplicates and
permutations don't trip us up.

The majority of this patch is adding unit tests for the existing logic
and for the new case where `last_used_kunitconfig` differs.

[1] https://lore.kernel.org/linux-kselftest/20211106013058.2621799-2-dlatypov@google.com/

Signed-off-by: Daniel Latypov &lt;dlatypov@google.com&gt;
Reviewed-by: David Gow &lt;davidgow@google.com&gt;
Reviewed-by: Brendan Higgins &lt;brendanhiggins@google.com&gt;
Signed-off-by: Shuah Khan &lt;skhan@linuxfoundation.org&gt;
</content>
</entry>
</feed>
