diff options
author | Dan Williams <dan.j.williams@intel.com> | 2013-11-06 19:29:58 -0500 |
---|---|---|
committer | Dan Williams <dan.j.williams@intel.com> | 2013-11-14 14:04:39 -0500 |
commit | 872f05c6e9a37e9358fd58eb54deee7337863496 (patch) | |
tree | f6afc54f45ddff8941d236550f15c0d0a96865b2 /Documentation | |
parent | 7b61017822cdff9c18ae70005cf52d84e8dafe5d (diff) |
dmatest: replace stored results mechanism, with uniform messages
For long running tests the tracking results in a memory leak for the "ok"
results, and for the failures the kernel log should be sufficient. Provide a
uniform format for error messages so they can be easily parsed and remove the
debugfs file.
Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'Documentation')
-rw-r--r-- | Documentation/dmatest.txt | 27 |
1 files changed, 13 insertions, 14 deletions
diff --git a/Documentation/dmatest.txt b/Documentation/dmatest.txt index 8b7a5c879df9..45b8c95f1a21 100644 --- a/Documentation/dmatest.txt +++ b/Documentation/dmatest.txt | |||
@@ -16,9 +16,8 @@ be built as module or inside kernel. Let's consider those cases. | |||
16 | Part 2 - When dmatest is built as a module... | 16 | Part 2 - When dmatest is built as a module... |
17 | 17 | ||
18 | After mounting debugfs and loading the module, the /sys/kernel/debug/dmatest | 18 | After mounting debugfs and loading the module, the /sys/kernel/debug/dmatest |
19 | folder with nodes will be created. There are two important files located. First | 19 | folder with a file named 'run' nodes will be created. 'run' controls run and |
20 | is the 'run' node that controls run and stop phases of the test, and the second | 20 | stop phases of the test. |
21 | one, 'results', is used to get the test case results. | ||
22 | 21 | ||
23 | Note that in this case test will not run on load automatically. | 22 | Note that in this case test will not run on load automatically. |
24 | 23 | ||
@@ -32,8 +31,9 @@ Hint: available channel list could be extracted by running the following | |||
32 | command: | 31 | command: |
33 | % ls -1 /sys/class/dma/ | 32 | % ls -1 /sys/class/dma/ |
34 | 33 | ||
35 | After a while you will start to get messages about current status or error like | 34 | Once started a message like "dmatest: Started 1 threads using dma0chan0" is |
36 | in the original code. | 35 | emitted. After that only test failure messages are reported until the test |
36 | stops. | ||
37 | 37 | ||
38 | Note that running a new test will not stop any in progress test. | 38 | Note that running a new test will not stop any in progress test. |
39 | 39 | ||
@@ -62,19 +62,18 @@ case. You always could check them at run-time by running | |||
62 | 62 | ||
63 | Part 4 - Gathering the test results | 63 | Part 4 - Gathering the test results |
64 | 64 | ||
65 | The module provides a storage for the test results in the memory. The gathered | 65 | Test results are printed to the kernel log buffer with the format: |
66 | data could be used after test is done. | ||
67 | 66 | ||
68 | The special file 'results' in the debugfs represents gathered data of the in | 67 | "dmatest: result <channel>: <test id>: '<error msg>' with src_off=<val> dst_off=<val> len=<val> (<err code>)" |
69 | progress test. The messages collected are printed to the kernel log as well. | ||
70 | 68 | ||
71 | Example of output: | 69 | Example of output: |
72 | % cat /sys/kernel/debug/dmatest/results | 70 | % dmesg | tail -n 1 |
73 | dma0chan0-copy0: #1: No errors with src_off=0x7bf dst_off=0x8ad len=0x3fea (0) | 71 | dmatest: result dma0chan0-copy0: #1: No errors with src_off=0x7bf dst_off=0x8ad len=0x3fea (0) |
74 | 72 | ||
75 | The message format is unified across the different types of errors. A number in | 73 | The message format is unified across the different types of errors. A number in |
76 | the parens represents additional information, e.g. error code, error counter, | 74 | the parens represents additional information, e.g. error code, error counter, |
77 | or status. | 75 | or status. A test thread also emits a summary line at completion listing the |
76 | number of tests executed, number that failed, and a result code. | ||
78 | 77 | ||
79 | Note that the buffer comparison is done in the old way, i.e. data is not | 78 | The details of a data miscompare error are also emitted, but do not follow the |
80 | collected and just printed out. | 79 | above format. |