]> asedeno.scripts.mit.edu Git - linux.git/blobdiff - lib/Kconfig.debug
refcount_t: Introduce a special purpose refcount type
[linux.git] / lib / Kconfig.debug
index 5b37821632a25a07326bb4344fc284eb23a8fa58..8f1f0e609891c40071a81d278f59b0d45a084b63 100644 (file)
@@ -716,6 +716,19 @@ source "lib/Kconfig.kmemcheck"
 
 source "lib/Kconfig.kasan"
 
+config DEBUG_REFCOUNT
+       bool "Verbose refcount checks"
+       help
+         Say Y here if you want reference counters (refcount_t and kref) to
+         generate WARNs on dubious usage. Without this refcount_t will still
+         be a saturating counter and avoid Use-After-Free by turning it into
+         a resource leak Denial-Of-Service.
+
+         Use of this option will increase kernel text size but will alert the
+         admin of potential abuse.
+
+         If in doubt, say "N".
+
 endmenu # "Memory Debugging"
 
 config ARCH_HAS_KCOV