diff options
author | Brian Gianforcaro <bgianf@serenityos.org> | 2021-04-24 14:20:49 -0700 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-04-25 09:38:27 +0200 |
commit | c248bbc7fda3211b0491309a8c3dd73fa51487c6 (patch) | |
tree | 6a8f1f75d338c0f5fb7ed8e67d9282be952f8cf0 /Kernel/FileSystem/ProcFS.cpp | |
parent | 7481789eace972840e73ea7e323be104cd848534 (diff) | |
download | serenity-c248bbc7fda3211b0491309a8c3dd73fa51487c6.zip |
Kernel: Add lock_count to procfs$all when LOCK_DEBUG is enabled.
Diffstat (limited to 'Kernel/FileSystem/ProcFS.cpp')
-rw-r--r-- | Kernel/FileSystem/ProcFS.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Kernel/FileSystem/ProcFS.cpp b/Kernel/FileSystem/ProcFS.cpp index 63a505ad94..486dc7e13b 100644 --- a/Kernel/FileSystem/ProcFS.cpp +++ b/Kernel/FileSystem/ProcFS.cpp @@ -801,6 +801,9 @@ static bool procfs$all(InodeIdentifier, KBufferBuilder& builder) auto thread_array = process_object.add_array("threads"); process.for_each_thread([&](const Thread& thread) { auto thread_object = thread_array.add_object(); +#if LOCK_DEBUG + thread_object.add("lock_count", thread.lock_count()); +#endif thread_object.add("tid", thread.tid().value()); thread_object.add("name", thread.name()); thread_object.add("times_scheduled", thread.times_scheduled()); |