linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
To: Linux Doc Mailing List <linux-doc@vger.kernel.org>
Cc: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>,
	linux-kernel@vger.kernel.org, Jonathan Corbet <corbet@lwn.net>,
	Jeff Layton <jlayton@kernel.org>,
	"J. Bruce Fields" <bfields@fieldses.org>,
	Alexander Viro <viro@zeniv.linux.org.uk>,
	linux-fsdevel@vger.kernel.org
Subject: [PATCH v2 17/29] docs: filesystems: convert mandatory-locking.txt to ReST
Date: Tue, 21 Apr 2020 18:54:28 +0200	[thread overview]
Message-ID: <e3094aef0253df8d0599735894ad5bfa08eff25e.1587487612.git.mchehab+huawei@kernel.org> (raw)
In-Reply-To: <cover.1587487612.git.mchehab+huawei@kernel.org>

- Add a SPDX header;
- Adjust document title;
- Some whitespace fixes and new line breaks;
- Use notes markups;
- Add it to filesystems/index.rst.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
---
 Documentation/filesystems/index.rst           |  1 +
 Documentation/filesystems/locks.rst           |  2 +-
 ...tory-locking.txt => mandatory-locking.rst} | 25 ++++++++++++-------
 fs/locks.c                                    |  2 +-
 4 files changed, 19 insertions(+), 11 deletions(-)
 rename Documentation/filesystems/{mandatory-locking.txt => mandatory-locking.rst} (91%)

diff --git a/Documentation/filesystems/index.rst b/Documentation/filesystems/index.rst
index 96190e268c11..02d52b536baf 100644
--- a/Documentation/filesystems/index.rst
+++ b/Documentation/filesystems/index.rst
@@ -29,6 +29,7 @@ algorithms work.
    fiemap
    files
    locks
+   mandatory-locking
 
    automount-support
 
diff --git a/Documentation/filesystems/locks.rst b/Documentation/filesystems/locks.rst
index 10f67fb9ce07..c5ae858b1aac 100644
--- a/Documentation/filesystems/locks.rst
+++ b/Documentation/filesystems/locks.rst
@@ -58,7 +58,7 @@ fcntl(), with all the problems that implies.
 ---------------------------------------
 
 Mandatory locking, as described in
-'Documentation/filesystems/mandatory-locking.txt' was prior to this release a
+'Documentation/filesystems/mandatory-locking.rst' was prior to this release a
 general configuration option that was valid for all mounted filesystems.  This
 had a number of inherent dangers, not the least of which was the ability to
 freeze an NFS server by asking it to read a file for which a mandatory lock
diff --git a/Documentation/filesystems/mandatory-locking.txt b/Documentation/filesystems/mandatory-locking.rst
similarity index 91%
rename from Documentation/filesystems/mandatory-locking.txt
rename to Documentation/filesystems/mandatory-locking.rst
index a251ca33164a..9ce73544a8f0 100644
--- a/Documentation/filesystems/mandatory-locking.txt
+++ b/Documentation/filesystems/mandatory-locking.rst
@@ -1,8 +1,13 @@
-	Mandatory File Locking For The Linux Operating System
+.. SPDX-License-Identifier: GPL-2.0
+
+=====================================================
+Mandatory File Locking For The Linux Operating System
+=====================================================
 
 		Andy Walker <andy@lysaker.kvaerner.no>
 
 			   15 April 1996
+
 		     (Updated September 2007)
 
 0. Why you should avoid mandatory locking
@@ -53,15 +58,17 @@ possible on existing user code. The scheme is based on marking individual files
 as candidates for mandatory locking, and using the existing fcntl()/lockf()
 interface for applying locks just as if they were normal, advisory locks.
 
-Note 1: In saying "file" in the paragraphs above I am actually not telling
-the whole truth. System V locking is based on fcntl(). The granularity of
-fcntl() is such that it allows the locking of byte ranges in files, in addition
-to entire files, so the mandatory locking rules also have byte level
-granularity.
+.. Note::
 
-Note 2: POSIX.1 does not specify any scheme for mandatory locking, despite
-borrowing the fcntl() locking scheme from System V. The mandatory locking
-scheme is defined by the System V Interface Definition (SVID) Version 3.
+   1. In saying "file" in the paragraphs above I am actually not telling
+      the whole truth. System V locking is based on fcntl(). The granularity of
+      fcntl() is such that it allows the locking of byte ranges in files, in
+      addition to entire files, so the mandatory locking rules also have byte
+      level granularity.
+
+   2. POSIX.1 does not specify any scheme for mandatory locking, despite
+      borrowing the fcntl() locking scheme from System V. The mandatory locking
+      scheme is defined by the System V Interface Definition (SVID) Version 3.
 
 2. Marking a file for mandatory locking
 ---------------------------------------
diff --git a/fs/locks.c b/fs/locks.c
index b8a31c1c4fff..1d4f4d5da704 100644
--- a/fs/locks.c
+++ b/fs/locks.c
@@ -61,7 +61,7 @@
  *
  *  Initial implementation of mandatory locks. SunOS turned out to be
  *  a rotten model, so I implemented the "obvious" semantics.
- *  See 'Documentation/filesystems/mandatory-locking.txt' for details.
+ *  See 'Documentation/filesystems/mandatory-locking.rst' for details.
  *  Andy Walker (andy@lysaker.kvaerner.no), April 06, 1996.
  *
  *  Don't allow mandatory locks on mmap()'ed files. Added simple functions to
-- 
2.25.2


  parent reply	other threads:[~2020-04-21 16:56 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-21 16:54 [PATCH v2 00/29] fs: convert remaining docs to ReST file format Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 01/29] docs: filesystems: convert caching/object.txt to ReST Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 02/29] docs: filesystems: convert caching/fscache.txt to ReST format Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 03/29] docs: filesystems: caching/netfs-api.txt: convert it to ReST Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 04/29] docs: filesystems: caching/operations.txt: " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 05/29] docs: filesystems: caching/cachefiles.txt: convert " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 06/29] docs: filesystems: caching/backend-api.txt: convert it " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 07/29] docs: filesystems: convert cifs/cifsroot.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 08/29] docs: filesystems: convert configfs.txt " Mauro Carvalho Chehab
2020-04-21 16:55   ` Christoph Hellwig
2020-04-21 17:02     ` Matthew Wilcox
2020-04-21 17:23       ` Christoph Hellwig
2020-04-21 22:39         ` Theodore Y. Ts'o
2020-04-21 22:53         ` Jonathan Corbet
2020-04-27 12:53           ` Christoph Hellwig
2020-04-27 21:08           ` Mauro Carvalho Chehab
2020-04-24 17:28         ` Peter Lister
2020-04-24 18:01           ` Jonathan Corbet
2020-04-27 12:51           ` Christoph Hellwig
2020-04-22  6:02   ` Felipe Balbi
2020-04-24 17:34   ` Peter Lister
2020-04-27 21:02     ` Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 09/29] docs: filesystems: convert automount-support.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 10/29] docs: filesystems: convert coda.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 11/29] docs: filesystems: convert devpts.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 12/29] docs: filesystems: convert dnotify.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 13/29] docs: filesystems: convert fiemap.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 14/29] docs: filesystems: convert files.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 15/29] docs: filesystems: convert fuse-io.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 16/29] docs: filesystems: convert locks.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` Mauro Carvalho Chehab [this message]
2020-04-21 16:54 ` [PATCH v2 18/29] docs: filesystems: convert mount_api.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 19/29] docs: filesystems: convert quota.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 20/29] docs: filesystems: convert seq_file.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 21/29] docs: filesystems: convert sharedsubtree.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 22/29] docs: filesystems: split spufs.txt into 3 separate files Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 23/29] docs: filesystems: convert spufs/spu_create.txt to ReST Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 24/29] docs: filesystems: convert spufs/spufs.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 25/29] docs: filesystems: convert spufs/spu_run.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 26/29] docs: filesystems: convert sysfs-pci.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 27/29] docs: filesystems: convert sysfs-tagging.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 28/29] docs: filesystems: convert xfs-delayed-logging-design.txt " Mauro Carvalho Chehab
2020-04-21 16:54 ` [PATCH v2 29/29] docs: filesystems: convert xfs-self-describing-metadata.txt " Mauro Carvalho Chehab

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=e3094aef0253df8d0599735894ad5bfa08eff25e.1587487612.git.mchehab+huawei@kernel.org \
    --to=mchehab+huawei@kernel.org \
    --cc=bfields@fieldses.org \
    --cc=corbet@lwn.net \
    --cc=jlayton@kernel.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=viro@zeniv.linux.org.uk \
    /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).