2015-09-09 14:03:14 +00:00
|
|
|
/*
|
|
|
|
* qemu_capspriv.h: private declarations for QEMU capabilities generation
|
|
|
|
*
|
|
|
|
* Copyright (C) 2015 Samsung Electronics Co. Ltd
|
|
|
|
* Copyright (C) 2015 Pavel Fedin
|
|
|
|
*
|
|
|
|
* This library is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU Lesser General Public
|
|
|
|
* License as published by the Free Software Foundation; either
|
|
|
|
* version 2.1 of the License, or (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This library is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
* Lesser General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU Lesser General Public
|
|
|
|
* License along with this library. If not, see
|
|
|
|
* <http://www.gnu.org/licenses/>.
|
|
|
|
*/
|
|
|
|
|
2018-12-13 14:53:50 +00:00
|
|
|
#ifndef LIBVIRT_QEMU_CAPSPRIV_H_ALLOW
|
2015-09-09 14:03:14 +00:00
|
|
|
# error "qemu_capspriv.h may only be included by qemu_capabilities.c or test suites"
|
2018-12-13 14:53:50 +00:00
|
|
|
#endif /* LIBVIRT_QEMU_CAPSPRIV_H_ALLOW */
|
2015-09-09 14:03:14 +00:00
|
|
|
|
2019-06-18 16:12:37 +00:00
|
|
|
#pragma once
|
2015-09-09 14:03:14 +00:00
|
|
|
|
2016-08-04 20:43:22 +00:00
|
|
|
virQEMUCapsPtr virQEMUCapsNewCopy(virQEMUCapsPtr qemuCaps);
|
|
|
|
|
2016-04-26 13:03:06 +00:00
|
|
|
virQEMUCapsPtr
|
2017-07-21 13:09:54 +00:00
|
|
|
virQEMUCapsNewForBinaryInternal(virArch hostArch,
|
2016-06-15 11:48:19 +00:00
|
|
|
const char *binary,
|
2016-04-26 13:03:06 +00:00
|
|
|
const char *libDir,
|
|
|
|
uid_t runUid,
|
|
|
|
gid_t runGid,
|
2020-05-15 20:00:29 +00:00
|
|
|
const char *hostCPUSignature,
|
2017-12-12 15:23:41 +00:00
|
|
|
unsigned int microcodeVersion,
|
2018-03-28 20:46:41 +00:00
|
|
|
const char *kernelVersion);
|
2016-04-26 13:03:06 +00:00
|
|
|
|
2017-07-21 13:09:54 +00:00
|
|
|
int virQEMUCapsLoadCache(virArch hostArch,
|
2016-06-15 12:35:18 +00:00
|
|
|
virQEMUCapsPtr qemuCaps,
|
2020-06-18 13:44:16 +00:00
|
|
|
const char *filename,
|
|
|
|
bool skipInvalidation);
|
2017-06-13 15:55:45 +00:00
|
|
|
char *virQEMUCapsFormatCache(virQEMUCapsPtr qemuCaps);
|
2016-04-28 13:01:02 +00:00
|
|
|
|
2016-06-10 15:16:21 +00:00
|
|
|
int
|
|
|
|
virQEMUCapsInitQMPMonitor(virQEMUCapsPtr qemuCaps,
|
|
|
|
qemuMonitorPtr mon);
|
|
|
|
|
|
|
|
int
|
|
|
|
virQEMUCapsInitQMPMonitorTCG(virQEMUCapsPtr qemuCaps,
|
|
|
|
qemuMonitorPtr mon);
|
|
|
|
|
2016-08-03 10:26:41 +00:00
|
|
|
void
|
|
|
|
virQEMUCapsSetArch(virQEMUCapsPtr qemuCaps,
|
|
|
|
virArch arch);
|
2016-06-15 12:35:18 +00:00
|
|
|
|
|
|
|
void
|
|
|
|
virQEMUCapsInitHostCPUModel(virQEMUCapsPtr qemuCaps,
|
2017-07-21 13:09:54 +00:00
|
|
|
virArch hostArch,
|
2017-02-22 15:51:50 +00:00
|
|
|
virDomainVirtType type);
|
2017-02-23 13:31:23 +00:00
|
|
|
|
|
|
|
int
|
|
|
|
virQEMUCapsInitCPUModel(virQEMUCapsPtr qemuCaps,
|
|
|
|
virDomainVirtType type,
|
2017-03-29 11:33:50 +00:00
|
|
|
virCPUDefPtr cpu,
|
|
|
|
bool migratable);
|
2017-02-23 13:31:23 +00:00
|
|
|
|
2017-04-05 13:38:37 +00:00
|
|
|
void
|
|
|
|
virQEMUCapsInitQMPBasicArch(virQEMUCapsPtr qemuCaps);
|
|
|
|
|
2019-02-25 09:01:34 +00:00
|
|
|
qemuMonitorCPUModelInfoPtr
|
|
|
|
virQEMUCapsGetCPUModelInfo(virQEMUCapsPtr qemuCaps,
|
|
|
|
virDomainVirtType type);
|
|
|
|
|
2017-02-23 13:31:23 +00:00
|
|
|
void
|
|
|
|
virQEMUCapsSetCPUModelInfo(virQEMUCapsPtr qemuCaps,
|
|
|
|
virDomainVirtType type,
|
|
|
|
qemuMonitorCPUModelInfoPtr modelInfo);
|
2017-03-08 12:32:46 +00:00
|
|
|
|
2019-02-25 08:39:17 +00:00
|
|
|
virCPUDataPtr
|
2019-06-17 11:54:53 +00:00
|
|
|
virQEMUCapsGetCPUModelX86Data(virQEMUCapsPtr qemuCaps,
|
|
|
|
qemuMonitorCPUModelInfoPtr model,
|
2019-02-25 08:39:17 +00:00
|
|
|
bool migratable);
|
|
|
|
|
2017-03-08 12:32:46 +00:00
|
|
|
virCPUDefPtr
|
2019-06-03 11:13:38 +00:00
|
|
|
virQEMUCapsProbeHostCPU(virArch hostArch,
|
2019-10-15 11:24:34 +00:00
|
|
|
virDomainCapsCPUModelsPtr models) G_GNUC_NO_INLINE;
|
2017-04-05 13:38:37 +00:00
|
|
|
|
|
|
|
void
|
|
|
|
virQEMUCapsSetGICCapabilities(virQEMUCapsPtr qemuCaps,
|
|
|
|
virGICCapability *capabilities,
|
|
|
|
size_t ncapabilities);
|
|
|
|
|
2018-06-08 14:40:51 +00:00
|
|
|
void
|
|
|
|
virQEMUCapsSetSEVCapabilities(virQEMUCapsPtr qemuCaps,
|
|
|
|
virSEVCapability *capabilities);
|
|
|
|
|
2017-09-26 19:08:37 +00:00
|
|
|
int
|
2019-10-23 12:08:16 +00:00
|
|
|
virQEMUCapsProbeCPUDefinitionsTest(virQEMUCapsPtr qemuCaps,
|
|
|
|
qemuMonitorPtr mon);
|
2017-12-12 15:23:41 +00:00
|
|
|
|
|
|
|
void
|
|
|
|
virQEMUCapsSetMicrocodeVersion(virQEMUCapsPtr qemuCaps,
|
|
|
|
unsigned int microcodeVersion);
|
2018-06-04 13:30:49 +00:00
|
|
|
|
|
|
|
void
|
|
|
|
virQEMUCapsStripMachineAliases(virQEMUCapsPtr qemuCaps);
|
2019-12-02 12:19:44 +00:00
|
|
|
|
2020-01-23 12:21:47 +00:00
|
|
|
bool
|
|
|
|
virQEMUCapsHasMachines(virQEMUCapsPtr qemuCaps);
|
|
|
|
|
2019-12-02 12:19:44 +00:00
|
|
|
void
|
|
|
|
virQEMUCapsAddMachine(virQEMUCapsPtr qemuCaps,
|
|
|
|
virDomainVirtType virtType,
|
|
|
|
const char *name,
|
|
|
|
const char *alias,
|
|
|
|
const char *defaultCPU,
|
|
|
|
int maxCpus,
|
|
|
|
bool hotplugCpus,
|
2020-05-14 11:11:01 +00:00
|
|
|
bool isDefault,
|
2020-05-25 17:13:43 +00:00
|
|
|
bool numaMemSupported,
|
2021-01-22 12:16:23 +00:00
|
|
|
const char *defaultRAMid,
|
|
|
|
bool deprecated);
|