| // Copyright lowRISC contributors. | |
| // Licensed under the Apache License, Version 2.0, see LICENSE for details. | |
| // SPDX-License-Identifier: Apache-2.0 | |
| #include "sw/device/silicon_creator/lib/drivers/ibex.h" | |
| #include "sw/device/lib/base/abs_mmio.h" | |
| #include "hw/top_earlgrey/sw/autogen/top_earlgrey.h" | |
| #include "rv_core_ibex_regs.h" | |
| enum { | |
| kBase = TOP_EARLGREY_RV_CORE_IBEX_CFG_BASE_ADDR, | |
| }; | |
| uint32_t ibex_fpga_version(void) { | |
| return abs_mmio_read32(kBase + RV_CORE_IBEX_FPGA_INFO_REG_OFFSET); | |
| } |