mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-07 17:53:56 -06:00
cpu: Factor out cpu_generic_init()
All targets using it gain the ability to set -cpu name,key=value,... options via the default TYPE_CPU CPUClass::parse_features() implementation. Signed-off-by: Andreas Färber <afaerber@suse.de>
This commit is contained in:
parent
1590bbcb02
commit
9262685b81
10 changed files with 62 additions and 103 deletions
|
@ -351,6 +351,17 @@ void cpu_reset(CPUState *cpu);
|
|||
*/
|
||||
ObjectClass *cpu_class_by_name(const char *typename, const char *cpu_model);
|
||||
|
||||
/**
|
||||
* cpu_generic_init:
|
||||
* @typename: The CPU base type.
|
||||
* @cpu_model: The model string including optional parameters.
|
||||
*
|
||||
* Instantiates a CPU, processes optional parameters and realizes the CPU.
|
||||
*
|
||||
* Returns: A #CPUState or %NULL if an error occurred.
|
||||
*/
|
||||
CPUState *cpu_generic_init(const char *typename, const char *cpu_model);
|
||||
|
||||
/**
|
||||
* cpu_has_work:
|
||||
* @cpu: The vCPU to check.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue