|
@@ -32,7 +32,6 @@
|
|
#include "hw/qdev-properties.h"
|
|
#include "hw/qdev-properties.h"
|
|
#include "hw/qdev-clock.h"
|
|
#include "hw/qdev-clock.h"
|
|
#include "semihosting/semihost.h"
|
|
#include "semihosting/semihost.h"
|
|
-#include "qapi/qapi-commands-machine-target.h"
|
|
|
|
#include "fpu_helper.h"
|
|
#include "fpu_helper.h"
|
|
|
|
|
|
const char regnames[32][3] = {
|
|
const char regnames[32][3] = {
|
|
@@ -624,34 +623,6 @@ static void mips_cpu_register_types(void)
|
|
|
|
|
|
type_init(mips_cpu_register_types)
|
|
type_init(mips_cpu_register_types)
|
|
|
|
|
|
-static void mips_cpu_add_definition(gpointer data, gpointer user_data)
|
|
|
|
-{
|
|
|
|
- ObjectClass *oc = data;
|
|
|
|
- CpuDefinitionInfoList **cpu_list = user_data;
|
|
|
|
- CpuDefinitionInfo *info;
|
|
|
|
- const char *typename;
|
|
|
|
-
|
|
|
|
- typename = object_class_get_name(oc);
|
|
|
|
- info = g_malloc0(sizeof(*info));
|
|
|
|
- info->name = g_strndup(typename,
|
|
|
|
- strlen(typename) - strlen("-" TYPE_MIPS_CPU));
|
|
|
|
- info->q_typename = g_strdup(typename);
|
|
|
|
-
|
|
|
|
- QAPI_LIST_PREPEND(*cpu_list, info);
|
|
|
|
-}
|
|
|
|
-
|
|
|
|
-CpuDefinitionInfoList *qmp_query_cpu_definitions(Error **errp)
|
|
|
|
-{
|
|
|
|
- CpuDefinitionInfoList *cpu_list = NULL;
|
|
|
|
- GSList *list;
|
|
|
|
-
|
|
|
|
- list = object_class_get_list(TYPE_MIPS_CPU, false);
|
|
|
|
- g_slist_foreach(list, mips_cpu_add_definition, &cpu_list);
|
|
|
|
- g_slist_free(list);
|
|
|
|
-
|
|
|
|
- return cpu_list;
|
|
|
|
-}
|
|
|
|
-
|
|
|
|
/* Could be used by generic CPU object */
|
|
/* Could be used by generic CPU object */
|
|
MIPSCPU *mips_cpu_create_with_clock(const char *cpu_type, Clock *cpu_refclk)
|
|
MIPSCPU *mips_cpu_create_with_clock(const char *cpu_type, Clock *cpu_refclk)
|
|
{
|
|
{
|