diff options
| author | Bo Gan <[email protected]> | 2024-03-05 18:35:36 -0800 |
|---|---|---|
| committer | Anup Patel <[email protected]> | 2024-03-11 10:36:39 +0530 |
| commit | a17600c186e80bca6d8641757d7ff1ccbf8fface (patch) | |
| tree | 6df0e6c7bc77c217ceba254774005c0e139d043f /lib | |
| parent | 2471cf2e6ce1429bad3b000941f95957be8da9c0 (diff) | |
lib: sbi: change prototype of sbi_trap_redirect
sbi_trap_redirect now uses const pointer to `trap`.
This ensures the caller that we never change `trap` in sbi_trap_redirect.
Signed-off-by: Bo Gan <[email protected]>
Reviewed-by: Anup Patel <[email protected]>
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/sbi/sbi_trap.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/sbi/sbi_trap.c b/lib/sbi/sbi_trap.c index 145db4b4..10249811 100644 --- a/lib/sbi/sbi_trap.c +++ b/lib/sbi/sbi_trap.c @@ -84,7 +84,7 @@ static void __noreturn sbi_trap_error(const char *msg, int rc, * @return 0 on success and negative error code on failure */ int sbi_trap_redirect(struct sbi_trap_regs *regs, - struct sbi_trap_info *trap) + const struct sbi_trap_info *trap) { ulong hstatus, vsstatus, prev_mode; #if __riscv_xlen == 32 |
