linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
To: Frank Rowand <frowand.list@gmail.com>
Cc: Linux Doc Mailing List <linux-doc@vger.kernel.org>,
	linux-kernel@vger.kernel.org, Jonathan Corbet <corbet@lwn.net>,
	Rob Herring <robh+dt@kernel.org>,
	Lee Jones <lee.jones@linaro.org>,
	devicetree@vger.kernel.org
Subject: Re: [PATCH v2 02/12] docs: dt: convert usage-model.txt to ReST
Date: Tue, 3 Mar 2020 08:25:53 +0100	[thread overview]
Message-ID: <20200303082553.6698b29c@onda.lan> (raw)
In-Reply-To: <33664e07-c3e4-12fa-9cbe-a3225bb6f343@gmail.com>

Em Mon, 2 Mar 2020 15:18:51 -0600
Frank Rowand <frowand.list@gmail.com> escreveu:

> On 3/2/20 1:59 AM, Mauro Carvalho Chehab wrote:
> > - Add a SPDX header;
> > - Adjust document title;
> > - Use footnoote markups;
> > - Some whitespace fixes and new line breaks;
> > - Mark literal blocks as such;
> > - Add it to devicetree/index.rst.
> > 
> > Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
> > ---
> >  Documentation/devicetree/index.rst            |  1 +
> >  Documentation/devicetree/of_unittest.txt      |  2 +-
> >  .../{usage-model.txt => usage-model.rst}      | 35 +++++++++++--------
> >  include/linux/mfd/core.h                      |  2 +-
> >  4 files changed, 23 insertions(+), 17 deletions(-)
> >  rename Documentation/devicetree/{usage-model.txt => usage-model.rst} (97%)
> > 
> > diff --git a/Documentation/devicetree/index.rst b/Documentation/devicetree/index.rst
> > index a11efe26f205..7a6aad7d384a 100644
> > --- a/Documentation/devicetree/index.rst
> > +++ b/Documentation/devicetree/index.rst
> > @@ -7,4 +7,5 @@ Open Firmware and Device Tree
> >  .. toctree::
> >     :maxdepth: 1
> >  
> > +   usage-model
> >     writing-schema
> > diff --git a/Documentation/devicetree/of_unittest.txt b/Documentation/devicetree/of_unittest.txt
> > index 3e4e7d48ae93..9fdd2de9b770 100644
> > --- a/Documentation/devicetree/of_unittest.txt
> > +++ b/Documentation/devicetree/of_unittest.txt
> > @@ -11,7 +11,7 @@ architecture.
> >  
> >  It is recommended to read the following documents before moving ahead.
> >  
> > -[1] Documentation/devicetree/usage-model.txt
> > +[1] Documentation/devicetree/usage-model.rst
> >  [2] http://www.devicetree.org/Device_Tree_Usage
> >  
> >  OF Selftest has been designed to test the interface (include/linux/of.h)
> > diff --git a/Documentation/devicetree/usage-model.txt b/Documentation/devicetree/usage-model.rst
> > similarity index 97%
> > rename from Documentation/devicetree/usage-model.txt
> > rename to Documentation/devicetree/usage-model.rst
> > index 33a8aaac02a8..326d7af10c5b 100644
> > --- a/Documentation/devicetree/usage-model.txt
> > +++ b/Documentation/devicetree/usage-model.rst
> > @@ -1,14 +1,18 @@
> > +.. SPDX-License-Identifier: GPL-2.0
> > +
> > +=========================
> >  Linux and the Device Tree
> > --------------------------
> > +=========================
> > +
> >  The Linux usage model for device tree data
> >  
> > -Author: Grant Likely <grant.likely@secretlab.ca>
> > +:Author: Grant Likely <grant.likely@secretlab.ca>
> >  
> >  This article describes how Linux uses the device tree.  An overview of
> >  the device tree data format can be found on the device tree usage page
> > -at devicetree.org[1].
> > +at devicetree.org\ [1]_.
> >  
> > -[1] http://devicetree.org/Device_Tree_Usage
> > +.. [1] http://devicetree.org/Device_Tree_Usage  
> 
> I don't know the proper ReST syntax for footnotes, but on the html page
> you kindly provided in 00/12, '.. [1]' is shown as '1(1,2)'.
> 
> -Frank

The syntax is simple: just add an  underline at the end, when referencing
it, like [1]_. The definitions should start with "..", like ".. [1] something".

Sphinx will automatically generate the reverse reference(s) at the html output.

Yet, sometimes (like the above), it needs to be escaped by a "\ ", as ReST would
recognize "foo[1]_" as something else.

Ps.: it also accepts an "auto-numbered" references like [#]_, but such syntax
require some care, in order to avoid wrong cross-references.

Regards,
Mauro

  reply	other threads:[~2020-03-03  7:26 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-02  7:59 [PATCH v2 00/12] Convert some DT documentation files to ReST Mauro Carvalho Chehab
2020-03-02  7:59 ` [PATCH v2 01/12] docs: dt: add an index.rst file for devicetree Mauro Carvalho Chehab
2020-03-02  7:59 ` [PATCH v2 02/12] docs: dt: convert usage-model.txt to ReST Mauro Carvalho Chehab
2020-03-02 11:54   ` Lee Jones
2020-03-02 21:11   ` Frank Rowand
2020-03-03  7:13     ` Mauro Carvalho Chehab
2020-03-02 21:18   ` Frank Rowand
2020-03-03  7:25     ` Mauro Carvalho Chehab [this message]
2020-03-02  7:59 ` [PATCH v2 03/12] docs: dt: usage_model.rst: fix link for DT usage Mauro Carvalho Chehab
2020-03-02 21:11   ` Frank Rowand
2020-03-02 21:40     ` Rob Herring
2020-03-03  7:31       ` Mauro Carvalho Chehab
2020-03-02  7:59 ` [PATCH v2 04/12] docs: dt: convert booting-without-of.txt to ReST format Mauro Carvalho Chehab
2020-03-04 18:25   ` Rob Herring
2020-03-05  1:45     ` Alex Shi
2020-03-02  7:59 ` [PATCH v2 05/12] docs: dt: convert changesets to ReST Mauro Carvalho Chehab
2020-03-02  7:59 ` [PATCH v2 06/12] docs: dt: convert dynamic-resolution-notes.txt " Mauro Carvalho Chehab
2020-03-02  7:59 ` [PATCH v2 07/12] docs: dt: convert of_unittest.txt " Mauro Carvalho Chehab
2020-03-02 21:11   ` Frank Rowand
2020-03-03  7:15     ` Mauro Carvalho Chehab
2020-03-02  7:59 ` [PATCH v2 08/12] docs: dt: convert overlay-notes.txt to ReST format Mauro Carvalho Chehab
2020-03-02 21:13   ` Frank Rowand
2020-03-03  7:17     ` Mauro Carvalho Chehab
2020-03-02  7:59 ` [PATCH v2 09/12] docs: dt: minor adjustments at writing-schema.rst Mauro Carvalho Chehab
2020-03-02  7:59 ` [PATCH v2 10/12] docs: dt: convert ABI.txt to ReST format Mauro Carvalho Chehab
2020-03-02  7:59 ` [PATCH v2 11/12] docs: dt: convert submitting-patches.txt " Mauro Carvalho Chehab
2020-03-02  7:59 ` [PATCH v2 12/12] docs: dt: convert writing-bindings.txt to ReST Mauro Carvalho Chehab
2020-03-02 19:35 ` [PATCH v2 00/12] Convert some DT documentation files " Jonathan Corbet
2020-03-03  7:09   ` Mauro Carvalho Chehab
2020-03-03 16:20     ` Rob Herring
2020-03-03 17:01       ` Mauro Carvalho Chehab
2020-03-03 17:07         ` Mauro Carvalho Chehab
2020-03-02 21:10 ` Frank Rowand

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=20200303082553.6698b29c@onda.lan \
    --to=mchehab+huawei@kernel.org \
    --cc=corbet@lwn.net \
    --cc=devicetree@vger.kernel.org \
    --cc=frowand.list@gmail.com \
    --cc=lee.jones@linaro.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=robh+dt@kernel.org \
    /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).