mbox series

[0/5] cpus: Remove system reset() API from user emulation

Message ID 20221220145625.26392-1-philmd@linaro.org
Headers show
Series cpus: Remove system reset() API from user emulation | expand

Message

Philippe Mathieu-Daudé Dec. 20, 2022, 2:56 p.m. UTC
In user emulation, threads -- implemented as CPU -- are
created/destroyed, but never reset. There is no point in
allowing the user emulation access the sysemu/reset API.

Philippe Mathieu-Daudé (5):
  target/i386: Restrict qapi/qapi-events-run-state.h to system emulation
  target/i386: Restrict sysemu/reset.h to system emulation
  target/loongarch: Restrict sysemu/reset.h to system emulation
  target/s390x: Restrict sysemu/reset.h to system emulation
  hw/core: Only build CPU reset handlers with system emulation

 hw/core/meson.build    | 2 +-
 target/i386/cpu.c      | 2 +-
 target/i386/helper.c   | 2 +-
 target/loongarch/cpu.c | 2 ++
 target/s390x/cpu.c     | 4 +++-
 5 files changed, 8 insertions(+), 4 deletions(-)

Comments

Richard Henderson Dec. 21, 2022, 1:18 a.m. UTC | #1
On 12/20/22 06:56, Philippe Mathieu-Daudé wrote:
> In user emulation, threads -- implemented as CPU -- are
> created/destroyed, but never reset. There is no point in
> allowing the user emulation access the sysemu/reset API.
> 
> Philippe Mathieu-Daudé (5):
>    target/i386: Restrict qapi/qapi-events-run-state.h to system emulation
>    target/i386: Restrict sysemu/reset.h to system emulation
>    target/loongarch: Restrict sysemu/reset.h to system emulation
>    target/s390x: Restrict sysemu/reset.h to system emulation
>    hw/core: Only build CPU reset handlers with system emulation

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>


r~
Wilfred Mallawa Dec. 21, 2022, 4 a.m. UTC | #2
On Tue, 2022-12-20 at 15:56 +0100, Philippe Mathieu-Daudé wrote:
> In user emulation, threads -- implemented as CPU -- are
> created/destroyed, but never reset. There is no point in
> allowing the user emulation access the sysemu/reset API.
> 
> Philippe Mathieu-Daudé (5):
>   target/i386: Restrict qapi/qapi-events-run-state.h to system
> emulation
>   target/i386: Restrict sysemu/reset.h to system emulation
>   target/loongarch: Restrict sysemu/reset.h to system emulation
>   target/s390x: Restrict sysemu/reset.h to system emulation
>   hw/core: Only build CPU reset handlers with system emulation
> 
Reviewed-by: Wilfred Mallawa <wilfred.mallawa@wdc.com>
>  hw/core/meson.build    | 2 +-
>  target/i386/cpu.c      | 2 +-
>  target/i386/helper.c   | 2 +-
>  target/loongarch/cpu.c | 2 ++
>  target/s390x/cpu.c     | 4 +++-
>  5 files changed, 8 insertions(+), 4 deletions(-)
>