hc
2024-10-12 a5969cabbb4660eab42b6ef0412cbbd1200cf14d
kernel/Documentation/vm/page_owner.rst
....@@ -18,7 +18,7 @@
1818 using it for analyzing who allocate each page is rather complex. We need
1919 to enlarge the trace buffer for preventing overlapping until userspace
2020 program launched. And, launched program continually dump out the trace
21
-buffer for later analysis and it would change system behviour with more
21
+buffer for later analysis and it would change system behaviour with more
2222 possibility rather than just keeping it in memory, so bad for debugging.
2323
2424 page owner can also be used for various purposes. For example, accurate
....@@ -41,17 +41,17 @@
4141 - Without page owner::
4242
4343 text data bss dec hex filename
44
- 40662 1493 644 42799 a72f mm/page_alloc.o
44
+ 48392 2333 644 51369 c8a9 mm/page_alloc.o
4545
4646 - With page owner::
4747
4848 text data bss dec hex filename
49
- 40892 1493 644 43029 a815 mm/page_alloc.o
50
- 1427 24 8 1459 5b3 mm/page_ext.o
51
- 2722 50 0 2772 ad4 mm/page_owner.o
49
+ 48800 2445 644 51889 cab1 mm/page_alloc.o
50
+ 6662 108 29 6799 1a8f mm/page_owner.o
51
+ 1025 8 8 1041 411 mm/page_ext.o
5252
53
-Although, roughly, 4 KB code is added in total, page_alloc.o increase by
54
-230 bytes and only half of it is in hotpath. Building the kernel with
53
+Although, roughly, 8 KB code is added in total, page_alloc.o increase by
54
+520 bytes and less than half of it is in hotpath. Building the kernel with
5555 page owner and turning it on if needed would be great option to debug
5656 kernel memory problem.
5757
....@@ -83,8 +83,7 @@
8383 4) Analyze information from page owner::
8484
8585 cat /sys/kernel/debug/page_owner > page_owner_full.txt
86
- grep -v ^PFN page_owner_full.txt > page_owner.txt
87
- ./page_owner_sort page_owner.txt sorted_page_owner.txt
86
+ ./page_owner_sort page_owner_full.txt sorted_page_owner.txt
8887
8988 See the result about who allocated each page
9089 in the ``sorted_page_owner.txt``.