mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-09 02:24:58 -06:00
target/riscv: Only support a single VSXL length
Signed-off-by: Alistair Francis <alistair.francis@wdc.com> Message-id: f3f4fd2ec22a07cc1d750e96895d6813f131de4d.1597259519.git.alistair.francis@wdc.com Message-Id: <f3f4fd2ec22a07cc1d750e96895d6813f131de4d.1597259519.git.alistair.francis@wdc.com>
This commit is contained in:
parent
543ba53157
commit
f8dc878efc
1 changed files with 9 additions and 0 deletions
|
@ -836,12 +836,21 @@ static int write_satp(CPURISCVState *env, int csrno, target_ulong val)
|
||||||
static int read_hstatus(CPURISCVState *env, int csrno, target_ulong *val)
|
static int read_hstatus(CPURISCVState *env, int csrno, target_ulong *val)
|
||||||
{
|
{
|
||||||
*val = env->hstatus;
|
*val = env->hstatus;
|
||||||
|
#ifdef TARGET_RISCV64
|
||||||
|
/* We only support 64-bit VSXL */
|
||||||
|
*val = set_field(*val, HSTATUS_VSXL, 2);
|
||||||
|
#endif
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int write_hstatus(CPURISCVState *env, int csrno, target_ulong val)
|
static int write_hstatus(CPURISCVState *env, int csrno, target_ulong val)
|
||||||
{
|
{
|
||||||
env->hstatus = val;
|
env->hstatus = val;
|
||||||
|
#ifdef TARGET_RISCV64
|
||||||
|
if (get_field(val, HSTATUS_VSXL) != 2) {
|
||||||
|
qemu_log_mask(LOG_UNIMP, "QEMU does not support mixed HSXLEN options.");
|
||||||
|
}
|
||||||
|
#endif
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue