Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

docs: mm: add enable_soft_offline sysctl

Add the documentation for soft offline behaviors / costs, and what the new
enable_soft_offline sysctl is for.

[jiaqiyan@google.com: fix kerneldoc warnings]
Link: https://lkml.kernel.org/r/CACw3F52=GxTCDw-PqFh3-GDM-fo3GbhGdu0hedxYXOTT4TQSTg@mail.gmail.com
[jiaqiyan@google.com: there are more blank lines needed]
Link: https://lkml.kernel.org/r/CACw3F52_obAB742XeDRNun4BHBYtrxtbvp5NkUincXdaob0j1g@mail.gmail.com
Link: https://lkml.kernel.org/r/20240626050818.2277273-5-jiaqiyan@google.com
Signed-off-by: Jiaqi Yan <jiaqiyan@google.com>
Acked-by: Oscar Salvador <osalvador@suse.de>
Acked-by: Miaohe Lin <linmiaohe@huawei.com>
Acked-by: David Rientjes <rientjes@google.com>
Cc: Frank van der Linden <fvdl@google.com>
Cc: Jane Chu <jane.chu@oracle.com>
Cc: Jonathan Corbet <corbet@lwn.net>
Cc: Lance Yang <ioworker0@gmail.com>
Cc: Muchun Song <muchun.song@linux.dev>
Cc: Naoya Horiguchi <nao.horiguchi@gmail.com>
Cc: Randy Dunlap <rdunlap@infradead.org>
Cc: Shuah Khan <shuah@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>

authored by

Jiaqi Yan and committed by
Andrew Morton
44195d1e 72ead83d

+38
+38
Documentation/admin-guide/sysctl/vm.rst
··· 36 36 - dirtytime_expire_seconds 37 37 - dirty_writeback_centisecs 38 38 - drop_caches 39 + - enable_soft_offline 39 40 - extfrag_threshold 40 41 - highmem_is_dirtyable 41 42 - hugetlb_shm_group ··· 268 267 These are informational only. They do not mean that anything is wrong 269 268 with your system. To disable them, echo 4 (bit 2) into drop_caches. 270 269 270 + enable_soft_offline 271 + =================== 272 + Correctable memory errors are very common on servers. Soft-offline is kernel's 273 + solution for memory pages having (excessive) corrected memory errors. 274 + 275 + For different types of page, soft-offline has different behaviors / costs. 276 + 277 + - For a raw error page, soft-offline migrates the in-use page's content to 278 + a new raw page. 279 + 280 + - For a page that is part of a transparent hugepage, soft-offline splits the 281 + transparent hugepage into raw pages, then migrates only the raw error page. 282 + As a result, user is transparently backed by 1 less hugepage, impacting 283 + memory access performance. 284 + 285 + - For a page that is part of a HugeTLB hugepage, soft-offline first migrates 286 + the entire HugeTLB hugepage, during which a free hugepage will be consumed 287 + as migration target. Then the original hugepage is dissolved into raw 288 + pages without compensation, reducing the capacity of the HugeTLB pool by 1. 289 + 290 + It is user's call to choose between reliability (staying away from fragile 291 + physical memory) vs performance / capacity implications in transparent and 292 + HugeTLB cases. 293 + 294 + For all architectures, enable_soft_offline controls whether to soft offline 295 + memory pages. When set to 1, kernel attempts to soft offline the pages 296 + whenever it thinks needed. When set to 0, kernel returns EOPNOTSUPP to 297 + the request to soft offline the pages. Its default value is 1. 298 + 299 + It is worth mentioning that after setting enable_soft_offline to 0, the 300 + following requests to soft offline pages will not be performed: 301 + 302 + - Request to soft offline pages from RAS Correctable Errors Collector. 303 + 304 + - On ARM, the request to soft offline pages from GHES driver. 305 + 306 + - On PARISC, the request to soft offline pages from Page Deallocation Table. 271 307 272 308 extfrag_threshold 273 309 =================