blob: cbd19d5e625f389e9beb91e67de4c0a7ed8d9a92 [file] [log] [blame]
Mike Rapoport3a3f7e22018-04-18 11:07:48 +03001=================
2Memory Management
3=================
4
5Linux memory management subsystem is responsible, as the name implies,
Andrew Klychkov751d5b22020-12-04 10:28:48 +03006for managing the memory in the system. This includes implementation of
Mike Rapoport3a3f7e22018-04-18 11:07:48 +03007virtual memory and demand paging, memory allocation both for kernel
Andrew Klychkov751d5b22020-12-04 10:28:48 +03008internal structures and user space programs, mapping of files into
Mike Rapoport3a3f7e22018-04-18 11:07:48 +03009processes address space and many other cool things.
10
11Linux memory management is a complex system with many configurable
12settings. Most of these settings are available via ``/proc``
13filesystem and can be quired and adjusted using ``sysctl``. These APIs
Mauro Carvalho Chehab57043242019-04-22 16:48:00 -030014are described in Documentation/admin-guide/sysctl/vm.rst and in `man 5 proc`_.
Mike Rapoport3a3f7e22018-04-18 11:07:48 +030015
16.. _man 5 proc: http://man7.org/linux/man-pages/man5/proc.5.html
17
Mike Rapoportf4629512018-05-29 14:37:25 +030018Linux memory management has its own jargon and if you are not yet
19familiar with it, consider reading
20:ref:`Documentation/admin-guide/mm/concepts.rst <mm_concepts>`.
21
Mike Rapoport3a3f7e22018-04-18 11:07:48 +030022Here we document in detail how to interact with various mechanisms in
23the Linux memory management.
Mike Rapoport1ad13352018-04-18 11:07:49 +030024
25.. toctree::
26 :maxdepth: 1
27
Mike Rapoportf4629512018-05-29 14:37:25 +030028 concepts
Mauro Carvalho Chehab4f4cfa62019-06-27 14:56:51 -030029 cma_debugfs
SeongJae Parkc4ba6012021-09-07 19:57:05 -070030 damon/index
Mike Rapoport1ad13352018-04-18 11:07:49 +030031 hugetlbpage
32 idle_page_tracking
Mike Rapoportc9161082018-04-24 09:40:28 +030033 ksm
Mike Rapoport6bf53992018-10-05 01:11:00 +030034 memory-hotplug
Daniel W. S. Almeida2b7295c2020-07-18 13:50:55 -030035 nommu-mmap
Mike Rapoport3ecf53e2018-05-08 10:02:10 +030036 numa_memory_policy
Jonathan Corbet8867f612019-05-22 13:35:13 -060037 numaperf
Mike Rapoport1ad13352018-04-18 11:07:49 +030038 pagemap
39 soft-dirty
Mike Rapoport45c9a742018-05-14 11:13:40 +030040 transhuge
Mike Rapoport1ad13352018-04-18 11:07:49 +030041 userfaultfd