mirror of
https://github.com/qemu/qemu.git
synced 2026-02-04 05:35:39 +00:00
hw/arm: Register TYPE_TARGET_ARM/AARCH64_MACHINE QOM interfaces
Define the TYPE_TARGET_ARM_MACHINE and TYPE_TARGET_AARCH64_MACHINE QOM interface names to allow machines to implement them. Register these interfaces in common code in target_info-qom.c used by all binaries because QOM interfaces must be registered before being checked (see next commit with the 'none' machine). Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Acked-by: Peter Maydell <peter.maydell@linaro.org> Message-Id: <20251021205741.57109-2-philmd@linaro.org>
This commit is contained in:
18
include/hw/arm/machines-qom.h
Normal file
18
include/hw/arm/machines-qom.h
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
/*
|
||||||
|
* QOM type definitions for ARM / Aarch64 machines
|
||||||
|
*
|
||||||
|
* Copyright (c) Linaro
|
||||||
|
*
|
||||||
|
* SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef HW_ARM_MACHINES_QOM_H
|
||||||
|
#define HW_ARM_MACHINES_QOM_H
|
||||||
|
|
||||||
|
#define TYPE_TARGET_ARM_MACHINE \
|
||||||
|
"target-info-arm-machine"
|
||||||
|
|
||||||
|
#define TYPE_TARGET_AARCH64_MACHINE \
|
||||||
|
"target-info-aarch64-machine"
|
||||||
|
|
||||||
|
#endif
|
||||||
@@ -3911,6 +3911,7 @@ common_ss.add(pagevary)
|
|||||||
specific_ss.add(files('page-vary-target.c'))
|
specific_ss.add(files('page-vary-target.c'))
|
||||||
|
|
||||||
common_ss.add(files('target-info.c'))
|
common_ss.add(files('target-info.c'))
|
||||||
|
system_ss.add(files('target-info-qom.c'))
|
||||||
specific_ss.add(files('target-info-stub.c'))
|
specific_ss.add(files('target-info-stub.c'))
|
||||||
|
|
||||||
subdir('backends')
|
subdir('backends')
|
||||||
|
|||||||
24
target-info-qom.c
Normal file
24
target-info-qom.c
Normal file
@@ -0,0 +1,24 @@
|
|||||||
|
/*
|
||||||
|
* QEMU binary/target API (QOM types)
|
||||||
|
*
|
||||||
|
* Copyright (c) Linaro
|
||||||
|
*
|
||||||
|
* SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include "qemu/osdep.h"
|
||||||
|
#include "qom/object.h"
|
||||||
|
#include "hw/arm/machines-qom.h"
|
||||||
|
|
||||||
|
static const TypeInfo target_info_types[] = {
|
||||||
|
{
|
||||||
|
.name = TYPE_TARGET_ARM_MACHINE,
|
||||||
|
.parent = TYPE_INTERFACE,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
.name = TYPE_TARGET_AARCH64_MACHINE,
|
||||||
|
.parent = TYPE_INTERFACE,
|
||||||
|
},
|
||||||
|
};
|
||||||
|
|
||||||
|
DEFINE_TYPES(target_info_types)
|
||||||
Reference in New Issue
Block a user