On Thu, Dec 16, 2021 at 11:15AM +0100, Marco Elver wrote:
On Thu, 16 Dec 2021 at 07:00, Harinder Singh sharinder@google.com wrote:
Describe the components of KUnit and how the kernel mode parts interact with kunit_tool.
Signed-off-by: Harinder Singh sharinder@google.com
.../dev-tools/kunit/architecture.rst | 204 ++++++++++++++++++ Documentation/dev-tools/kunit/index.rst | 2 + .../kunit/kunit_suitememorydiagram.png | Bin 0 -> 24174 bytes Documentation/dev-tools/kunit/start.rst | 1 + 4 files changed, 207 insertions(+) create mode 100644 Documentation/dev-tools/kunit/architecture.rst create mode 100644 Documentation/dev-tools/kunit/kunit_suitememorydiagram.png
In response to the other email: Adding binary blobs just creates problems, for comparing different versions, and general bloating the whole repo, where better alternatives exist.
I suppose an ASCII diagram is a bit primitive. :-)
However, SVG files on the other hand are not binary blobs, they are text-markup based (XML), and e.g. diffing them often provides useful information about what changed. SVG also has the benefit of being vector graphics, and not being limited to one resolution.
Looking at the diagram you added, I think this can easily be turned into vector graphics, and most likely will not use up 24KiB as a result.
I gave it a shot, see attached SVG file. I re-created the figure using Inkscape.
The attached SVG file is an "Optimized SVG", where Inkscape stripped as much useless info as possible and it should be as portable as possible. Some care is required to make it render the same everywhere, which I did by turning some objects into pure paths (like the arrows and '{', '}'). The text is still text, and should look similar enough with most Monospace fonts. The advantage of it still being text is reduced size, and also being able to edit it with a plain text editor should only small details need updating (like variable naming). If shapes need editing, it can be done with the help of Inkscape itself.
Also, kernel-doc has proper support for dealing with SVG: https://www.kernel.org/doc/html/latest/doc-guide/sphinx.html#image-output
In case you want to use my SVG as-is, you need to add: Signed-off-by: Marco Elver elver@google.com
Thanks, -- Marco