summaryrefslogtreecommitdiff
path: root/include/sbi/sbi_ipi.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/sbi/sbi_ipi.h')
-rw-r--r--include/sbi/sbi_ipi.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/include/sbi/sbi_ipi.h b/include/sbi/sbi_ipi.h
index 617872c..fb7d658 100644
--- a/include/sbi/sbi_ipi.h
+++ b/include/sbi/sbi_ipi.h
@@ -18,6 +18,18 @@
/* clang-format on */
+/** IPI hardware device */
+struct sbi_ipi_device {
+ /** Name of the IPI device */
+ char name[32];
+
+ /** Send IPI to a target HART */
+ void (*ipi_send)(u32 target_hart);
+
+ /** Clear IPI for a target HART */
+ void (*ipi_clear)(u32 target_hart);
+};
+
struct sbi_scratch;
/** IPI event operations or callbacks */
@@ -63,6 +75,12 @@ int sbi_ipi_send_halt(ulong hmask, ulong hbase);
void sbi_ipi_process(void);
+void sbi_ipi_raw_send(u32 target_hart);
+
+const struct sbi_ipi_device *sbi_ipi_get_device(void);
+
+void sbi_ipi_set_device(const struct sbi_ipi_device *dev);
+
int sbi_ipi_init(struct sbi_scratch *scratch, bool cold_boot);
void sbi_ipi_exit(struct sbi_scratch *scratch);