sbi_emulate_csr.h 469 B

1234567891011121314151617181920212223
  1. /*
  2. * SPDX-License-Identifier: BSD-2-Clause
  3. *
  4. * Copyright (c) 2019 Western Digital Corporation or its affiliates.
  5. *
  6. * Authors:
  7. * Anup Patel <anup.patel@wdc.com>
  8. */
  9. #ifndef __SBI_EMULATE_CSR_H__
  10. #define __SBI_EMULATE_CSR_H__
  11. #include <sbi/sbi_types.h>
  12. struct sbi_trap_regs;
  13. int sbi_emulate_csr_read(int csr_num, struct sbi_trap_regs *regs,
  14. ulong *csr_val);
  15. int sbi_emulate_csr_write(int csr_num, struct sbi_trap_regs *regs,
  16. ulong csr_val);
  17. #endif