summaryrefslogtreecommitdiff
path: root/lib/sbi/sbi_system.c
diff options
context:
space:
mode:
authorAtish Patra <atish.patra@wdc.com>2019-11-25 10:33:47 +0300
committerAnup Patel <anup@brainfault.org>2019-12-23 06:42:13 +0300
commit9777aeef41a613b3c27056a695d4d6007760b3a8 (patch)
treea50c68b24fa6caf5932f0b96aafaf2509cc6be62 /lib/sbi/sbi_system.c
parent109266397a6d8a37f4450c5ff80ea3737a6acd3e (diff)
downloadopensbi-9777aeef41a613b3c27056a695d4d6007760b3a8.tar.xz
lib: Add IPI extension in SBI
This patch adds new IPI extension which replaces ipi related v0.1 extensions. This also adds a new API for ipi sending as trap handling is not necessary in v0.2 SBI IPI related extensions. It also modifies the IPI sending code which now accepts hart mask as a value instead of S-mode virtual address. Thus, the caller should set it to exact hart mask value everytime. Signed-off-by: Atish Patra <atish.patra@wdc.com> Reviewed-by: Anup Patel <anup.patel@wdc.com>
Diffstat (limited to 'lib/sbi/sbi_system.c')
-rw-r--r--lib/sbi/sbi_system.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/sbi/sbi_system.c b/lib/sbi/sbi_system.c
index 2cb30d4..cdc85d6 100644
--- a/lib/sbi/sbi_system.c
+++ b/lib/sbi/sbi_system.c
@@ -39,7 +39,8 @@ sbi_system_shutdown(struct sbi_scratch *scratch, u32 type)
/* If that fails (or is not implemented) send an IPI on every
* hart to hang and then hang the current hart */
- sbi_ipi_send_many(scratch, NULL, NULL, SBI_IPI_EVENT_HALT, NULL);
+ sbi_ipi_send_many(scratch, sbi_hart_available_mask(), 0,
+ SBI_IPI_EVENT_HALT, NULL);
sbi_hart_hang();
}