History | View | Annotate | Download (4.4 kB)
cpu: Partially revert "cpu: Change qemu_init_vcpu() argument to CPUState"
Commit c643bed99 moved qemu_init_vcpu() calls to common CPUState code.This causes x86 cpu-add to fail with "KVM: setting VAPIC address failed".
The reason for the failure is that CPUClass::kvm_fd is not yet...
cpu: Turn cpu_get_phys_page_debug() into a CPUClass hook
Change breakpoint_invalidate() argument to CPUState alongside.
Since all targets now assign a softmmu-only field, we can drop helperscpu_class_set_{do_unassigned_access,vmsd}() and device_class_set_vmsd()....
target-unicore32: Implement CPUClass::set_pc()
This adds support for GDB's c addr (Continue) and s addr (Single Step).
Prepares for dropping cpu_pc_from_tb().
Signed-off-by: Andreas Färber <afaerber@suse.de>
cpu: Change qemu_init_vcpu() argument to CPUState
This allows to move the call into CPUState's realizefn.Therefore move the stub into libqemustub.a.
Reviewed-by: Richard Henderson <rth@twiddle.net>Signed-off-by: Andreas Färber <afaerber@suse.de>
cpu: Turn cpu_dump_{state,statistics}() into CPUState hooks
Make cpustats monitor command available unconditionally.
Prepares for changing kvm_handle_internal_error() and kvm_cpu_exec()arguments to CPUState.
cpu: Replace do_interrupt() by CPUClass::do_interrupt method
This removes a global per-target function and thus takes us one stepcloser to compiling multiple targets into one executable.
It will also allow to override the interrupt handling for certain CPU...
cpu: Add CPUArchState pointer to CPUState
The target-specific ENV_GET_CPU() macros have allowed us to navigatefrom CPUArchState to CPUState. The reverse direction was not supported.Avoid introducing CPU_GET_ENV() macros by initializing an untypedpointer that is initialized in derived instance_init functions....
target-unicore32: Move TCG initialization to UniCore32CPU initfn
Normalize the "inited" logic and add a tcg_enabled() check to suppressit for qtest.
Ensures that a QOM-created UniCore32CPU is usable.
Acked-by: Guan Xuetao <gxt@mprc.pku.edu.cn>Signed-off-by: Andreas Färber <afaerber@suse.de>
target-unicore32: Introduce QOM realizefn for UniCore32CPU
Introduce a realizefn and set realized = true in uc32_cpu_init().
Acked-by: Guan Xuetao <gxt@mprc.pku.edu.cn>[AF: Invoke the parent's realizefn]Signed-off-by: Andreas Färber <afaerber@suse.de>
target-unicore32: Rename CPU subtypes
In the initial conversion of CPU models to QOM types, model names weremapped 1:1 to type names. As a side effect this gained us a type "any",which is now a device.
To avoid "-device any" silliness and to pave the way for compiling...
target-unicore32: Mark as unmigratable
CPU_SAVE_VERSION 2 was bogus as both save and load would just throw ahw_error(). Therefore we can without problems suppress registration of"cpu_common" VMState by dropping CPU_SAVE_VERSION define and provide anunmigratable "cpu" VMStateDescription for UniCore32CPU at device level...
target-unicore32: Catch attempt to instantiate abstract type in cpu_init()
Fixes -cpu unicore32-cpu asserting.
Cc: qemu-stable@nongnu.orgSigned-off-by: Andreas Färber <afaerber@suse.de>
target-unicore32: Use type_register() instead of type_register_static()
According to its documentation, type_register_static()'s TypeInfoargument should exist for the life type of the type.Therefore use type_register() when registering the list of CPU subtypes....
target-unicore32: Detect attempt to instantiate non-CPU type in cpu_init()
Consolidate model checking into a new uc32_cpu_class_by_name().
If the name matches an existing type, also check whether that type isactually (a sub-type of) TYPE_UNICORE32_CPU....
cpus: Pass CPUState to [qemu_]cpu_has_work()
For target-mips also change the return type to bool.
Make include paths for cpu-qom.h consistent for alpha and unicore32.
Signed-off-by: Andreas Färber <afaerber@suse.de>[AF: Updated new target-openrisc function accordingly]...
unicore32-softmmu: Make UniCore32 cpuid & exceptions correct and runable
This patch initializes the cpuid to exactly correct value becauselinux kernel will check it.In addition, the exception types are specified in proper situations.Then it could make exceptions generated correctly and timely....
target-unicore32: Move CPU-dependent init into initfn
Instead of setting values in a CPUID switch, do so in initfn functions.
Signed-off-by: Andreas Färber <afaerber@suse.de>Acked-by: Guan Xuetao <gxt@mprc.pku.edu.cn>
target-unicore32: QOM'ify CPU
Embed CPUUniCore32State as first member of UniCore32CPU.
Contributed under GPLv2+.