summaryrefslogtreecommitdiff
path: root/Documentation/core-api/kernel-api.rst
diff options
context:
space:
mode:
Diffstat (limited to 'Documentation/core-api/kernel-api.rst')
-rw-r--r--Documentation/core-api/kernel-api.rst246
1 files changed, 165 insertions, 81 deletions
diff --git a/Documentation/core-api/kernel-api.rst b/Documentation/core-api/kernel-api.rst
index 17b00914c6ab..e8211c4ca662 100644
--- a/Documentation/core-api/kernel-api.rst
+++ b/Documentation/core-api/kernel-api.rst
@@ -2,14 +2,6 @@
The Linux Kernel API
====================
-Data Types
-==========
-
-Doubly Linked Lists
--------------------
-
-.. kernel-doc:: include/linux/list.h
- :internal:
Basic C Library Functions
=========================
@@ -26,128 +18,173 @@ String Conversions
.. kernel-doc:: lib/vsprintf.c
:export:
-.. kernel-doc:: include/linux/kernel.h
- :functions: kstrtol
-
-.. kernel-doc:: include/linux/kernel.h
- :functions: kstrtoul
+.. kernel-doc:: include/linux/kstrtox.h
+ :functions: kstrtol kstrtoul
.. kernel-doc:: lib/kstrtox.c
:export:
+.. kernel-doc:: lib/string_helpers.c
+ :export:
+
String Manipulation
-------------------
+.. kernel-doc:: include/linux/fortify-string.h
+ :internal:
+
.. kernel-doc:: lib/string.c
:export:
-Bit Operations
---------------
-
-.. kernel-doc:: arch/x86/include/asm/bitops.h
+.. kernel-doc:: include/linux/string.h
:internal:
+.. kernel-doc:: mm/util.c
+ :functions: kstrdup kstrdup_const kstrndup kmemdup kmemdup_nul memdup_user
+ vmemdup_user strndup_user memdup_user_nul
+
Basic Kernel Library Functions
==============================
The Linux kernel provides more basic utility functions.
+Bit Operations
+--------------
+
+.. kernel-doc:: include/asm-generic/bitops/instrumented-atomic.h
+ :internal:
+
+.. kernel-doc:: include/asm-generic/bitops/instrumented-non-atomic.h
+ :internal:
+
+.. kernel-doc:: include/asm-generic/bitops/instrumented-lock.h
+ :internal:
+
Bitmap Operations
-----------------
.. kernel-doc:: lib/bitmap.c
+ :doc: bitmap introduction
+
+.. kernel-doc:: include/linux/bitmap.h
+ :doc: declare bitmap
+
+.. kernel-doc:: include/linux/bitmap.h
+ :doc: bitmap overview
+
+.. kernel-doc:: include/linux/bitmap.h
+ :doc: bitmap bitops
+
+.. kernel-doc:: lib/bitmap.c
:export:
.. kernel-doc:: lib/bitmap.c
:internal:
+.. kernel-doc:: include/linux/bitmap.h
+ :internal:
+
Command-line Parsing
--------------------
.. kernel-doc:: lib/cmdline.c
:export:
-CRC Functions
--------------
+Error Pointers
+--------------
-.. kernel-doc:: lib/crc7.c
- :export:
+.. kernel-doc:: include/linux/err.h
+ :internal:
-.. kernel-doc:: lib/crc16.c
+Sorting
+-------
+
+.. kernel-doc:: lib/sort.c
:export:
-.. kernel-doc:: lib/crc-itu-t.c
+.. kernel-doc:: lib/list_sort.c
:export:
-.. kernel-doc:: lib/crc32.c
+Text Searching
+--------------
+
+.. kernel-doc:: lib/textsearch.c
+ :doc: ts_intro
-.. kernel-doc:: lib/crc-ccitt.c
+.. kernel-doc:: lib/textsearch.c
:export:
-idr/ida Functions
------------------
+.. kernel-doc:: include/linux/textsearch.h
+ :functions: textsearch_find textsearch_next \
+ textsearch_get_pattern textsearch_get_pattern_len
+
+CRC and Math Functions in Linux
+===============================
+
+Arithmetic Overflow Checking
+----------------------------
-.. kernel-doc:: include/linux/idr.h
- :doc: idr sync
+.. kernel-doc:: include/linux/overflow.h
+ :internal:
-.. kernel-doc:: lib/idr.c
- :doc: IDA description
+CRC Functions
+-------------
-.. kernel-doc:: lib/idr.c
+.. kernel-doc:: lib/crc/crc4.c
:export:
-Memory Management in Linux
-==========================
+.. kernel-doc:: lib/crc/crc7.c
+ :export:
-The Slab Cache
---------------
+.. kernel-doc:: lib/crc/crc8.c
+ :export:
-.. kernel-doc:: include/linux/slab.h
- :internal:
+.. kernel-doc:: lib/crc/crc16.c
+ :export:
-.. kernel-doc:: mm/slab.c
+.. kernel-doc:: lib/crc/crc-ccitt.c
:export:
-.. kernel-doc:: mm/util.c
+.. kernel-doc:: lib/crc/crc-itu-t.c
:export:
-User Space Memory Access
-------------------------
+.. kernel-doc:: include/linux/crc32.h
+
+.. kernel-doc:: include/linux/crc64.h
-.. kernel-doc:: arch/x86/include/asm/uaccess.h
+Base 2 log and power Functions
+------------------------------
+
+.. kernel-doc:: include/linux/log2.h
:internal:
-.. kernel-doc:: arch/x86/lib/usercopy_32.c
- :export:
+Integer log and power Functions
+-------------------------------
-More Memory Management Functions
---------------------------------
+.. kernel-doc:: include/linux/int_log.h
-.. kernel-doc:: mm/readahead.c
+.. kernel-doc:: lib/math/int_pow.c
:export:
-.. kernel-doc:: mm/filemap.c
+.. kernel-doc:: lib/math/int_sqrt.c
:export:
-.. kernel-doc:: mm/memory.c
- :export:
+Division Functions
+------------------
-.. kernel-doc:: mm/vmalloc.c
- :export:
+.. kernel-doc:: include/asm-generic/div64.h
+ :functions: do_div
-.. kernel-doc:: mm/page_alloc.c
+.. kernel-doc:: include/linux/math64.h
:internal:
-.. kernel-doc:: mm/mempool.c
+.. kernel-doc:: lib/math/gcd.c
:export:
-.. kernel-doc:: mm/dmapool.c
- :export:
-
-.. kernel-doc:: mm/page-writeback.c
- :export:
+UUID/GUID
+---------
-.. kernel-doc:: mm/truncate.c
+.. kernel-doc:: lib/uuid.c
:export:
Kernel IPC facilities
@@ -187,26 +224,38 @@ relay interface
Module Support
==============
-Module Loading
---------------
+Kernel module auto-loading
+--------------------------
-.. kernel-doc:: kernel/kmod.c
+.. kernel-doc:: kernel/module/kmod.c
:export:
+Module debugging
+----------------
+
+.. kernel-doc:: kernel/module/stats.c
+ :doc: module debugging statistics overview
+
+dup_failed_modules - tracks duplicate failed modules
+****************************************************
+
+.. kernel-doc:: kernel/module/stats.c
+ :doc: dup_failed_modules - tracks duplicate failed modules
+
+module statistics debugfs counters
+**********************************
+
+.. kernel-doc:: kernel/module/stats.c
+ :doc: module statistics debugfs counters
+
Inter Module support
--------------------
-Refer to the file kernel/module.c for more information.
+Refer to the files in kernel/module/ for more information.
Hardware Interfaces
===================
-Interrupt Handling
-------------------
-
-.. kernel-doc:: kernel/irq/manage.c
- :export:
-
DMA Channels
------------
@@ -225,7 +274,7 @@ Resources Management
MTRR Handling
-------------
-.. kernel-doc:: arch/x86/kernel/cpu/mtrr/main.c
+.. kernel-doc:: arch/x86/kernel/cpu/mtrr/mtrr.c
:export:
Security Framework
@@ -258,6 +307,7 @@ Accounting Framework
Block Devices
=============
+.. kernel-doc:: include/linux/bio.h
.. kernel-doc:: block/blk-core.c
:export:
@@ -273,21 +323,12 @@ Block Devices
.. kernel-doc:: block/blk-settings.c
:export:
-.. kernel-doc:: block/blk-exec.c
- :export:
-
.. kernel-doc:: block/blk-flush.c
:export:
.. kernel-doc:: block/blk-lib.c
:export:
-.. kernel-doc:: block/blk-tag.c
- :export:
-
-.. kernel-doc:: block/blk-tag.c
- :internal:
-
.. kernel-doc:: block/blk-integrity.c
:export:
@@ -300,6 +341,9 @@ Block Devices
.. kernel-doc:: block/genhd.c
:export:
+.. kernel-doc:: block/bdev.c
+ :export:
+
Char devices
============
@@ -344,3 +388,43 @@ codecs, and devices with strict requirements for interface clocking.
.. kernel-doc:: include/linux/clk.h
:internal:
+
+Synchronization Primitives
+==========================
+
+Read-Copy Update (RCU)
+----------------------
+
+.. kernel-doc:: include/linux/rcupdate.h
+
+.. kernel-doc:: kernel/rcu/tree.c
+
+.. kernel-doc:: kernel/rcu/tree_exp.h
+
+.. kernel-doc:: kernel/rcu/update.c
+
+.. kernel-doc:: include/linux/srcu.h
+
+.. kernel-doc:: kernel/rcu/srcutree.c
+
+.. kernel-doc:: include/linux/rculist_bl.h
+
+.. kernel-doc:: include/linux/rculist.h
+
+.. kernel-doc:: include/linux/rculist_nulls.h
+
+.. kernel-doc:: include/linux/rcu_sync.h
+
+.. kernel-doc:: kernel/rcu/sync.c
+
+.. kernel-doc:: kernel/rcu/tasks.h
+
+.. kernel-doc:: kernel/rcu/tree_stall.h
+
+.. kernel-doc:: include/linux/rcupdate_trace.h
+
+.. kernel-doc:: include/linux/rcupdate_wait.h
+
+.. kernel-doc:: include/linux/rcuref.h
+
+.. kernel-doc:: include/linux/rcutree.h