]> git.baikalelectronics.ru Git - uboot.git/commit
riscv: cpu: ax25: Simplify cache enabling logic in harts_early_init()
authorYu Chien Peter Lin <peterlin@andestech.com>
Mon, 6 Feb 2023 08:10:47 +0000 (16:10 +0800)
committerLeo Yu-Chi Liang <ycliang@andestech.com>
Fri, 17 Feb 2023 11:07:48 +0000 (19:07 +0800)
commiteeca564137fb9d52049e808b86f9d0637e32bec8
tree57185976e0b05d9ccfe860e7602a6f94275343ed
parenta17fb5669465925c74e7ada7228dfd120bfbcd95
riscv: cpu: ax25: Simplify cache enabling logic in harts_early_init()

As the OpenSBI v1.2 does not enable the cache [0], we enable
the i/d-cache in harts_early_init() and do not disable in
cleanup_before_linux(). This patch also simplifies the logic
and moves the CSR encoding to include/asm/arch-andes/csr.h.

[0] https://github.com/riscv-software-src/opensbi/commit/bd7ef4139829da5c30fa980f7498d385124408fa

Signed-off-by: Yu Chien Peter Lin <peterlin@andestech.com>
Reviewed-by: Leo Yu-Chi Liang <ycliang@andestech.com>
Reviewed-by: Rick Chen <rick@andestech.com>
arch/riscv/cpu/ax25/cpu.c
arch/riscv/include/asm/arch-andes/csr.h [new file with mode: 0644]