mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-09-18 22:14:16 +00:00
Documentation: core-api: add generic parser docbook
Add the simple generic parser to the core-api docbook. It can be used for parsing all sorts of options throughout the kernel. Signed-off-by: Randy Dunlap <rdunlap@infradead.org> Cc: Alexander Viro <viro@zeniv.linux.org.uk> Cc: Eric Biggers <ebiggers@kernel.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Jonathan Corbet <corbet@lwn.net> Cc: linux-doc@vger.kernel.org Cc: linux-fsdevel@vger.kernel.org Signed-off-by: Jonathan Corbet <corbet@lwn.net> Link: https://lore.kernel.org/r/20241120060711.159783-1-rdunlap@infradead.org
This commit is contained in:
parent
bc7509446b
commit
28884915e6
3 changed files with 21 additions and 2 deletions
|
@ -53,6 +53,7 @@ Library functionality that is used throughout the kernel.
|
||||||
floating-point
|
floating-point
|
||||||
union_find
|
union_find
|
||||||
min_heap
|
min_heap
|
||||||
|
parser
|
||||||
|
|
||||||
Low level entry and exit
|
Low level entry and exit
|
||||||
========================
|
========================
|
||||||
|
|
17
Documentation/core-api/parser.rst
Normal file
17
Documentation/core-api/parser.rst
Normal file
|
@ -0,0 +1,17 @@
|
||||||
|
.. SPDX-License-Identifier: GPL-2.0+
|
||||||
|
|
||||||
|
==============
|
||||||
|
Generic parser
|
||||||
|
==============
|
||||||
|
|
||||||
|
Overview
|
||||||
|
========
|
||||||
|
|
||||||
|
The generic parser is a simple parser for parsing mount options,
|
||||||
|
filesystem options, driver options, subsystem options, etc.
|
||||||
|
|
||||||
|
Parser API
|
||||||
|
==========
|
||||||
|
|
||||||
|
.. kernel-doc:: lib/parser.c
|
||||||
|
:export:
|
|
@ -275,8 +275,9 @@ EXPORT_SYMBOL(match_hex);
|
||||||
*
|
*
|
||||||
* Description: Parse the string @str to check if matches wildcard
|
* Description: Parse the string @str to check if matches wildcard
|
||||||
* pattern @pattern. The pattern may contain two types of wildcards:
|
* pattern @pattern. The pattern may contain two types of wildcards:
|
||||||
* '*' - matches zero or more characters
|
*
|
||||||
* '?' - matches one character
|
* * '*' - matches zero or more characters
|
||||||
|
* * '?' - matches one character
|
||||||
*
|
*
|
||||||
* Return: If the @str matches the @pattern, return true, else return false.
|
* Return: If the @str matches the @pattern, return true, else return false.
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Add table
Reference in a new issue