linux-doc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: Jonathan Corbet <corbet@lwn.net>
Cc: Stephen Rothwell <sfr@canb.auug.org.au>,
	linux-doc@vger.kernel.org,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Linux Next Mailing List <linux-next@vger.kernel.org>
Subject: [PATCH] ftrace/documentation: Fix RST C code blocks
Date: Wed, 18 Nov 2020 10:35:02 -0500	[thread overview]
Message-ID: <20201118103502.24e90f7c@gandalf.local.home> (raw)
In-Reply-To: <20201116132929.7f59943e@lwn.net>

From: "Steven Rostedt (VMware)" <rostedt@goodmis.org>

Some C code in the ftrace-users.rst document is missing RST C block
annotation, which has to be added.

Link: https://lore.kernel.org/r/20201116173502.392a769c@canb.auug.org.au

Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
---
 Documentation/trace/ftrace-uses.rst | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/Documentation/trace/ftrace-uses.rst b/Documentation/trace/ftrace-uses.rst
index 5981d5691745..f7d98ae5b885 100644
--- a/Documentation/trace/ftrace-uses.rst
+++ b/Documentation/trace/ftrace-uses.rst
@@ -116,6 +116,8 @@ called by a callback may also be traced, and call that same callback,
 recursion protection must be used. There are two helper functions that
 can help in this regard. If you start your code with:
 
+.. code-block:: c
+
 	int bit;
 
 	bit = ftrace_test_recursion_trylock(ip, parent_ip);
@@ -124,6 +126,8 @@ can help in this regard. If you start your code with:
 
 and end it with:
 
+.. code-block:: c
+
 	ftrace_test_recursion_unlock(bit);
 
 The code in between will be safe to use, even if it ends up calling a
@@ -145,6 +149,8 @@ protection, it is best to make sure that RCU is "watching", otherwise
 that data or critical section will not be protected as expected. In this
 case add:
 
+.. code-block:: c
+
 	if (!rcu_is_watching())
 		return;
 
-- 
2.25.4


  parent reply	other threads:[~2020-11-18 15:35 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20201116173502.392a769c@canb.auug.org.au>
2020-11-16 17:43 ` linux-next: build warning after merge of the ftrace tree Steven Rostedt
2020-11-16 19:24   ` Jonathan Corbet
2020-11-16 20:25     ` Steven Rostedt
2020-11-16 20:29       ` Jonathan Corbet
2020-11-16 20:35         ` Steven Rostedt
2020-11-18 15:35         ` Steven Rostedt [this message]
2020-11-18 15:51           ` [PATCH] ftrace/documentation: Fix RST C code blocks Steven Rostedt
2020-11-18 16:24             ` Jonathan Corbet
2020-11-18 16:26               ` Steven Rostedt
2020-11-18 16:28                 ` Jonathan Corbet
2020-11-18 16:44                   ` Steven Rostedt

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20201118103502.24e90f7c@gandalf.local.home \
    --to=rostedt@goodmis.org \
    --cc=corbet@lwn.net \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=sfr@canb.auug.org.au \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).