]> bbs.cooldavid.org Git - net-next-2.6.git/blobdiff - Documentation/kmemleak.txt
kmemleak: Do not trigger a scan when reading the debug/kmemleak file
[net-next-2.6.git] / Documentation / kmemleak.txt
index c06f7ba6499353757ec35d65d076a613fd79b80c..89068030b01bbdb34392df6bf4fd8782d928ac57 100644 (file)
@@ -17,12 +17,16 @@ Usage
 
 CONFIG_DEBUG_KMEMLEAK in "Kernel hacking" has to be enabled. A kernel
 thread scans the memory every 10 minutes (by default) and prints the
-number of new unreferenced objects found. To trigger an intermediate
-scan and display the details of all the possible memory leaks:
+number of new unreferenced objects found. To display the details of all
+the possible memory leaks:
 
   # mount -t debugfs nodev /sys/kernel/debug/
   # cat /sys/kernel/debug/kmemleak
 
+To trigger an intermediate memory scan:
+
+  # echo scan > /sys/kernel/debug/kmemleak
+
 Note that the orphan objects are listed in the order they were allocated
 and one object at the beginning of the list may cause other subsequent
 objects to be reported as orphan.
@@ -37,6 +41,7 @@ Memory scanning parameters can be modified at run-time by writing to the
   scan=off     - stop the automatic memory scanning thread
   scan=<secs>  - set the automatic memory scanning period in seconds
                  (default 600, 0 to stop the automatic scanning)
+  scan         - trigger a memory scan
 
 Kmemleak can also be disabled at boot-time by passing "kmemleak=off" on
 the kernel command line.