lkml.org 
[lkml]   [2022]   [Jul]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH V5 06/16] Documentation/rv: Add a basic documentation
On Wed, Jul 13, 2022 at 11:17:22PM +0200, Daniel Bristot de Oliveira wrote:
> Add the runtime-verification.rst document, explaining the basics of RV
> and how to use the interface.
>
> Cc: Wim Van Sebroeck <wim@linux-watchdog.org>
> Cc: Guenter Roeck <linux@roeck-us.net>
> Cc: Jonathan Corbet <corbet@lwn.net>
> Cc: Steven Rostedt <rostedt@goodmis.org>
> Cc: Ingo Molnar <mingo@redhat.com>
> Cc: Thomas Gleixner <tglx@linutronix.de>
> Cc: Peter Zijlstra <peterz@infradead.org>
> Cc: Will Deacon <will@kernel.org>
> Cc: Catalin Marinas <catalin.marinas@arm.com>
> Cc: Marco Elver <elver@google.com>
> Cc: Dmitry Vyukov <dvyukov@google.com>
> Cc: "Paul E. McKenney" <paulmck@kernel.org>
> Cc: Shuah Khan <skhan@linuxfoundation.org>
> Cc: Gabriele Paoloni <gpaoloni@redhat.com>
> Cc: Juri Lelli <juri.lelli@redhat.com>
> Cc: Clark Williams <williams@redhat.com>
> Cc: Tao Zhou <tao.zhou@linux.dev>
> Cc: Randy Dunlap <rdunlap@infradead.org>
> Cc: linux-doc@vger.kernel.org
> Cc: linux-kernel@vger.kernel.org
> Cc: linux-trace-devel@vger.kernel.org
> Signed-off-by: Daniel Bristot de Oliveira <bristot@kernel.org>
> ---
> Documentation/trace/index.rst | 1 +
> Documentation/trace/rv/index.rst | 9 +
> .../trace/rv/runtime-verification.rst | 233 ++++++++++++++++++
> kernel/trace/rv/Kconfig | 3 +
> kernel/trace/rv/rv.c | 3 +
> 5 files changed, 249 insertions(+)
> create mode 100644 Documentation/trace/rv/index.rst
> create mode 100644 Documentation/trace/rv/runtime-verification.rst
> + runtime-verification.rst

[snip]

> +The user interface
> +==================
> +
> +The user interface resembles the tracing interface (on purpose). It is
> +currently at "/sys/kernel/tracing/rv/".
> +
> +The following files/folders are currently available:
> +
> +**available_monitors**
> +
> +- Reading list the available monitors, one per line
> +
> +For example::
> +
> + # cat available_monitors
> + wip
> + wwnr
> +
> +**available_reactors**
> +
> +- Reading shows the available reactors, one per line.
> +
> +For example::
> +
> + # cat available_reactors
> + nop
> + panic
> + printk
> +
> +**enabled_monitors**:
> +
> +- Reading lists the enabled monitors, one per line
> +- Writing to it enables a given monitor
> +- Writing a monitor name with a '-' prefix disables it

s/-/!/

> +- Truncating the file disables all enabled monitors
> +
> +For example::
> +
> + # cat enabled_monitors
> + # echo wip > enabled_monitors
> + # echo wwnr >> enabled_monitors
> + # cat enabled_monitors
> + wip
> + wwnr
> + # echo '!wip' >> enabled_monitors
> + # cat enabled_monitors
> + wwnr
> + # echo > enabled_monitors
> + # cat enabled_monitors
> + #
> +
> +Note that it is possible to enable more than one monitor concurrently.
> +
> +
> +**monitoring_on**
> +
> +This is an on/off general switcher for monitoring. It resembles the
> +"tracing_on" switcher in the trace interface.
> +
> +- Writing "0" stops the monitoring
> +- Writing "1" continues the monitoring
> +- Reading returns the current status of the monitoring
> +
> +Note that it does not disable enabled monitors but stop the per-entity
> +monitors monitoring the events received from the system.
> +
> +**reacting_on**
> +
> +- Writing "0" prevents reactions for happening
> +- Writing "1" enable reactions
> +- Reading returns the current status of the monitoring

s/monitoring/reaction/

\
 
 \ /
  Last update: 2022-07-17 17:21    [W:0.201 / U:0.048 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site