public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] hung_task: Provide runtime reset interface for hung task detector
@ 2025-12-09  4:12 Aaron Tomlin
  2025-12-09  4:12 ` [PATCH 1/2] hung_task: Consolidate hung task warning into an atomic log block Aaron Tomlin
  2025-12-09  4:12 ` [PATCH 2/2] hung_task: Provide runtime reset interface for hung task detector Aaron Tomlin
  0 siblings, 2 replies; 11+ messages in thread
From: Aaron Tomlin @ 2025-12-09  4:12 UTC (permalink / raw)
  To: akpm, lance.yang, mhiramat, gregkh; +Cc: sean, linux-kernel

Introduce a write-only sysfs attribute,
/sys/kernel/hung_task_detect_count_reset, to reset the total count of
detected hung tasks at runtime.

The attribute requires writing the value "1" to trigger the reset and returns
-EINVAL for any other input, ensuring robustness.

This addition is primarily justified by the need for enhanced
administrative control and improved diagnostics workflow in a running
production environment. It addresses a key limitation of the existing
mechanism: the inability to clear persistent state without resorting to a
full system reboot. The sysfs interface provides a non-disruptive, runtime
method to manage the diagnostic state.

After a system administrator investigates a potential hang and corrects the issue,
it is now possible to clear the history back to zero. This provides a clean
slate for subsequent monitoring, ensuring that any new recurrence of a hung
task is immediately reflected by a counter value greater than zero,
streamlining the post-mortem diagnostic phase.


Aaron Tomlin (2):
  hung_task: Consolidate hung task warning into an atomic log block
  hung_task: Provide runtime reset interface for hung task detector

 .../sysfs-kernel-hung_task_detect_count_reset |  8 +++
 kernel/hung_task.c                            | 68 ++++++++++++++++---
 2 files changed, 66 insertions(+), 10 deletions(-)
 create mode 100644 Documentation/ABI/testing/sysfs-kernel-hung_task_detect_count_reset

-- 
2.51.0


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2025-12-10 13:08 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-12-09  4:12 [PATCH 0/2] hung_task: Provide runtime reset interface for hung task detector Aaron Tomlin
2025-12-09  4:12 ` [PATCH 1/2] hung_task: Consolidate hung task warning into an atomic log block Aaron Tomlin
2025-12-09  5:12   ` Lance Yang
2025-12-09  6:56     ` Greg KH
2025-12-09 22:14       ` Aaron Tomlin
2025-12-10  7:37         ` Greg KH
2025-12-10 13:08         ` Petr Mladek
2025-12-09 22:11     ` Aaron Tomlin
2025-12-09  4:12 ` [PATCH 2/2] hung_task: Provide runtime reset interface for hung task detector Aaron Tomlin
2025-12-09  4:54   ` Lance Yang
2025-12-09 22:06     ` Aaron Tomlin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox