Re: [PATCH 2/7] target/riscv: env->misa_mxl is a constant

2025-03-18 Thread Alistair Francis
On Tue, Mar 11, 2025 at 4:18 PM Paolo Bonzini wrote: > > > > Il lun 10 mar 2025, 23:18 Alistair Francis ha scritto: >> >> On Tue, Mar 11, 2025 at 3:34 AM Paolo Bonzini wrote: >> > >> > On Fri, Mar 7, 2025 at 1:45 AM Alistair Francis >> > wrote: >> > > I'm not convinced that this is the thing t

Re: [PATCH 2/7] target/riscv: env->misa_mxl is a constant

2025-03-11 Thread Paolo Bonzini
On Fri, Mar 7, 2025 at 1:45 AM Alistair Francis wrote: > I'm not convinced that this is the thing that we should be checking > for. If someone can corrupt the migration data for an attack there are > better things to change then the MXL In principle you could have code that uses 2 << MXL to compu

Re: [PATCH 2/7] target/riscv: env->misa_mxl is a constant

2025-03-10 Thread Paolo Bonzini
Il lun 10 mar 2025, 23:18 Alistair Francis ha scritto: > On Tue, Mar 11, 2025 at 3:34 AM Paolo Bonzini wrote: > > > > On Fri, Mar 7, 2025 at 1:45 AM Alistair Francis > wrote: > > > I'm not convinced that this is the thing that we should be checking > > > for. If someone can corrupt the migratio

Re: [PATCH 2/7] target/riscv: env->misa_mxl is a constant

2025-03-10 Thread Alistair Francis
On Tue, Mar 11, 2025 at 3:34 AM Paolo Bonzini wrote: > > On Fri, Mar 7, 2025 at 1:45 AM Alistair Francis wrote: > > I'm not convinced that this is the thing that we should be checking > > for. If someone can corrupt the migration data for an attack there are > > better things to change then the M

Re: [PATCH 2/7] target/riscv: env->misa_mxl is a constant

2025-03-09 Thread Paolo Bonzini
On 3/6/25 02:16, Alistair Francis wrote: On Wed, Feb 19, 2025 at 3:01 AM Paolo Bonzini wrote: There is nothing that overwrites env->misa_mxl, so it is a constant. Do The idea is that misa_mxl can change, although that's not supported now. At run-time, or only at configuration time (before

Re: [PATCH 2/7] target/riscv: env->misa_mxl is a constant

2025-03-06 Thread Alistair Francis
On Thu, Mar 6, 2025 at 11:00 PM Paolo Bonzini wrote: > > On 3/6/25 02:16, Alistair Francis wrote: > > On Wed, Feb 19, 2025 at 3:01 AM Paolo Bonzini wrote: > >> > >> There is nothing that overwrites env->misa_mxl, so it is a constant. Do > > > > The idea is that misa_mxl can change, although that

Re: [PATCH 2/7] target/riscv: env->misa_mxl is a constant

2025-03-05 Thread Alistair Francis
On Wed, Feb 19, 2025 at 3:01 AM Paolo Bonzini wrote: > > There is nothing that overwrites env->misa_mxl, so it is a constant. Do The idea is that misa_mxl can change, although that's not supported now. > not let a corrupted migration stream change the value; changing misa_mxl Does this actuall

[PATCH 2/7] target/riscv: env->misa_mxl is a constant

2025-02-18 Thread Paolo Bonzini
There is nothing that overwrites env->misa_mxl, so it is a constant. Do not let a corrupted migration stream change the value; changing misa_mxl would have a snowball effect on, for example, the valid VM modes. Signed-off-by: Paolo Bonzini --- target/riscv/machine.c | 13 + 1 file c