OpenSBI Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/4] RISC-V SBI watchdog support
@ 2026-10-02  8:30 Prajwal N
  2026-10-02  8:30 ` [PATCH 1/4] lib: sbi: Add timer tick to time conversion helper Prajwal N
                   ` (3 more replies)
  0 siblings, 4 replies; 8+ messages in thread
From: Prajwal N @ 2026-10-02  8:30 UTC (permalink / raw)
  To: anup; +Cc: opensbi, prajwal.n.oss, Prajwal N

This series introduces support for the RISC-V SBI watchdog extension,
which provides the watchdog functionality for the Supervisor software.

The SBI watchdog extension exposes watchdog functionality including
start, stop, pat, read and write attributes to the S-mode software via
SBI calls. The extension manages the watchdog timer in M-mode using the
system timer.

The S-mode software can also optionally subscribe for
watchdog pretimeout notification which is delivered as a Message
Signaled Interrupt (MSI) before the current watch period expires.
On watchdog expiry, a platform system reset is triggered.

The series consists of the following changes:

- Patch 1 adds helper function to convert timer tick delta to a
  specified time unit and a wrapper to convert the time tick to
  microsecond.

- Patch 2 adds the SBI watchdog extension ID and function IDs
  for supported operations, including start, stop, pat, and
  atrribute read and write.

- Patch 3 implements the SBI watchdog functionality including
  start, stop, pat, read and write attributes, pretimeout and
  timeout handlers.

- Patch 4 implements ecall handler functionality to delegate
  the ecall to SBI watchdog framework

Prajwal N (4):
  lib: sbi: Add timer tick to time conversion helper
  include: sbi: Add SBI watchdog extension definitions
  lib: sbi: Add SBI watchdog framework
  lib: sbi: Add ecall handler for SBI watchdog

 include/sbi/sbi_ecall_interface.h |  33 +++
 include/sbi/sbi_timer.h           |  12 +
 include/sbi/sbi_wdt.h             |  72 +++++
 lib/sbi/Kconfig                   |   4 +
 lib/sbi/objects.mk                |   4 +
 lib/sbi/sbi_ecall_wdt.c           |  79 ++++++
 lib/sbi/sbi_init.c                |   8 +
 lib/sbi/sbi_timer.c               |   5 +
 lib/sbi/sbi_wdt.c                 | 455 ++++++++++++++++++++++++++++++
 9 files changed, 672 insertions(+)
 create mode 100644 include/sbi/sbi_wdt.h
 create mode 100644 lib/sbi/sbi_ecall_wdt.c
 create mode 100644 lib/sbi/sbi_wdt.c

-- 
2.43.0


-- 
opensbi mailing list
opensbi@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/opensbi

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

end of thread, other threads:[~2026-10-23  5:02 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-02  8:30 [PATCH 0/4] RISC-V SBI watchdog support Prajwal N
2026-10-02  8:30 ` [PATCH 1/4] lib: sbi: Add timer tick to time conversion helper Prajwal N
2026-10-02  8:30 ` [PATCH 2/4] include: sbi: Add SBI watchdog extension definitions Prajwal N
2026-10-02  8:30 ` [PATCH 3/4] lib: sbi: Add SBI watchdog framework Prajwal N
2026-10-05  3:33   ` Rahul Pathak
2026-10-05  9:16   ` Rahul Pathak
2026-10-23  4:55   ` Himanshu Chauhan
2026-10-02  8:30 ` [PATCH 4/4] lib: sbi: Add ecall handler for SBI watchdog Prajwal N

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