2009-01-05 14:05:29 +00:00
|
|
|
#
|
2009-11-10 14:53:20 +00:00
|
|
|
# General private symbols. Add symbols here, and see Makefile.am for
|
|
|
|
# more details.
|
2009-01-05 14:05:29 +00:00
|
|
|
#
|
2010-10-20 17:10:45 +00:00
|
|
|
# Keep this file sorted by header name, then by symbols with each header.
|
|
|
|
#
|
2009-01-05 14:05:29 +00:00
|
|
|
|
2010-05-21 04:23:48 +00:00
|
|
|
# bitmap.h
|
2012-09-14 07:46:57 +00:00
|
|
|
virBitmapClearAll;
|
2010-05-21 04:23:48 +00:00
|
|
|
virBitmapClearBit;
|
2012-09-06 15:09:32 +00:00
|
|
|
virBitmapCopy;
|
2012-10-25 00:44:27 +00:00
|
|
|
virBitmapCountBits;
|
2012-09-14 07:46:57 +00:00
|
|
|
virBitmapEqual;
|
|
|
|
virBitmapFormat;
|
2010-10-20 17:10:45 +00:00
|
|
|
virBitmapFree;
|
2010-05-21 04:23:48 +00:00
|
|
|
virBitmapGetBit;
|
2012-09-14 07:46:57 +00:00
|
|
|
virBitmapIsAllSet;
|
2012-09-14 07:46:56 +00:00
|
|
|
virBitmapNew;
|
2012-09-14 07:46:57 +00:00
|
|
|
virBitmapNewCopy;
|
|
|
|
virBitmapNewData;
|
|
|
|
virBitmapNextSetBit;
|
|
|
|
virBitmapParse;
|
|
|
|
virBitmapSetAll;
|
2010-10-20 17:10:45 +00:00
|
|
|
virBitmapSetBit;
|
2012-09-14 07:46:57 +00:00
|
|
|
virBitmapSize;
|
2011-02-09 12:14:51 +00:00
|
|
|
virBitmapString;
|
2012-09-14 07:46:57 +00:00
|
|
|
virBitmapToData;
|
2010-05-21 04:23:48 +00:00
|
|
|
|
|
|
|
|
2009-01-05 14:05:29 +00:00
|
|
|
# buf.h
|
|
|
|
virBufferAdd;
|
|
|
|
virBufferAddChar;
|
2011-10-20 21:48:47 +00:00
|
|
|
virBufferAdjustIndent;
|
2011-04-30 16:44:42 +00:00
|
|
|
virBufferAsprintf;
|
2009-01-05 14:05:29 +00:00
|
|
|
virBufferContentAndReset;
|
2012-06-08 19:50:23 +00:00
|
|
|
virBufferCurrentContent;
|
2009-01-05 14:05:29 +00:00
|
|
|
virBufferError;
|
2011-09-20 04:13:42 +00:00
|
|
|
virBufferEscape;
|
2010-11-19 15:51:57 +00:00
|
|
|
virBufferEscapeSexpr;
|
2011-07-28 13:25:00 +00:00
|
|
|
virBufferEscapeShell;
|
2010-11-22 19:14:14 +00:00
|
|
|
virBufferEscapeString;
|
2009-12-09 23:00:50 +00:00
|
|
|
virBufferFreeAndReset;
|
2011-10-20 21:48:47 +00:00
|
|
|
virBufferGetIndent;
|
2010-10-12 11:23:18 +00:00
|
|
|
virBufferStrcat;
|
2012-05-22 15:35:06 +00:00
|
|
|
virBufferTrim;
|
2010-10-20 17:10:45 +00:00
|
|
|
virBufferURIEncodeString;
|
|
|
|
virBufferUse;
|
2011-04-30 16:44:42 +00:00
|
|
|
virBufferVasprintf;
|
2009-01-05 14:05:29 +00:00
|
|
|
|
|
|
|
|
|
|
|
# caps.h
|
|
|
|
virCapabilitiesAddGuest;
|
|
|
|
virCapabilitiesAddGuestDomain;
|
|
|
|
virCapabilitiesAddGuestFeature;
|
2010-10-20 17:10:45 +00:00
|
|
|
virCapabilitiesAddHostFeature;
|
2009-01-05 14:05:29 +00:00
|
|
|
virCapabilitiesAddHostMigrateTransport;
|
|
|
|
virCapabilitiesAddHostNUMACell;
|
2010-10-20 17:10:45 +00:00
|
|
|
virCapabilitiesAllocMachines;
|
2009-01-05 14:05:29 +00:00
|
|
|
virCapabilitiesDefaultGuestArch;
|
|
|
|
virCapabilitiesDefaultGuestEmulator;
|
|
|
|
virCapabilitiesDefaultGuestMachine;
|
|
|
|
virCapabilitiesFormatXML;
|
|
|
|
virCapabilitiesFree;
|
2010-10-20 17:10:45 +00:00
|
|
|
virCapabilitiesFreeMachines;
|
2009-06-29 10:41:56 +00:00
|
|
|
virCapabilitiesFreeNUMAInfo;
|
2009-03-02 20:19:13 +00:00
|
|
|
virCapabilitiesGenerateMac;
|
2009-06-16 15:27:33 +00:00
|
|
|
virCapabilitiesIsEmulatorRequired;
|
2010-10-20 17:10:45 +00:00
|
|
|
virCapabilitiesNew;
|
|
|
|
virCapabilitiesSetEmulatorRequired;
|
2009-12-18 13:44:55 +00:00
|
|
|
virCapabilitiesSetHostCPU;
|
2010-10-20 17:10:45 +00:00
|
|
|
virCapabilitiesSetMacPrefix;
|
2009-01-05 14:05:29 +00:00
|
|
|
|
|
|
|
|
Move all shared utility files to src/util/
* src/bridge.c, src/bridge.h, src/buf.c, src/buf.h, src/cgroup.c,
src/cgroup.h, src/conf.c, src/conf.h, src/event.c, src/event.h,
src/hash.c, src/hash.h, src/hostusb.c, src/hostusb.h,
src/iptables.c, src/iptables.h, src/logging.c, src/logging.h,
src/memory.c, src/memory.h, src/pci.c, src/pci.h, src/qparams.c,
src/qparams.h, src/stats_linux.c, src/stats_linux.h,
src/threads-pthread.c, src/threads-pthread.h, src/threads-win32.c,
src/threads-win32.h, src/threads.c, src/threads.h, src/util.c,
src/util.h, src/uuid.c, src/uuid.h, src/virterror.c,
src/virterror_internal.h, src/xml.c, src/xml.h: Move all files
into src/util/
* daemon/Makefile.am: Add -Isrc/util/ to build flags
* src/Makefile.am: Add -Isrc/util/ to build flags and update for
moved files
* src/libvirt_private.syms: Export cgroup APIs since they're now
in util rather than linking directly to drivers
* src/xen/xs_internal.c: Disable bogus virEventRemoveHandle call
when built under PROXY
* proxy/Makefile.am: Update for changed file locations. Remove
bogus build of event.c
* tools/Makefile.am, tests/Makefile.am: Add -Isrc/util/ to build flags
2009-09-16 15:28:46 +00:00
|
|
|
# cgroup.h
|
2010-10-20 17:10:45 +00:00
|
|
|
virCgroupAddTask;
|
2012-08-21 09:18:25 +00:00
|
|
|
virCgroupAddTaskController;
|
2012-07-18 16:03:17 +00:00
|
|
|
virCgroupAllowDevice;
|
2010-10-20 17:10:45 +00:00
|
|
|
virCgroupAllowDeviceMajor;
|
|
|
|
virCgroupAllowDevicePath;
|
|
|
|
virCgroupControllerTypeFromString;
|
|
|
|
virCgroupControllerTypeToString;
|
|
|
|
virCgroupDenyAllDevices;
|
2012-07-18 16:03:17 +00:00
|
|
|
virCgroupDenyDevice;
|
|
|
|
virCgroupDenyDeviceMajor;
|
2010-10-20 17:10:45 +00:00
|
|
|
virCgroupDenyDevicePath;
|
Move all shared utility files to src/util/
* src/bridge.c, src/bridge.h, src/buf.c, src/buf.h, src/cgroup.c,
src/cgroup.h, src/conf.c, src/conf.h, src/event.c, src/event.h,
src/hash.c, src/hash.h, src/hostusb.c, src/hostusb.h,
src/iptables.c, src/iptables.h, src/logging.c, src/logging.h,
src/memory.c, src/memory.h, src/pci.c, src/pci.h, src/qparams.c,
src/qparams.h, src/stats_linux.c, src/stats_linux.h,
src/threads-pthread.c, src/threads-pthread.h, src/threads-win32.c,
src/threads-win32.h, src/threads.c, src/threads.h, src/util.c,
src/util.h, src/uuid.c, src/uuid.h, src/virterror.c,
src/virterror_internal.h, src/xml.c, src/xml.h: Move all files
into src/util/
* daemon/Makefile.am: Add -Isrc/util/ to build flags
* src/Makefile.am: Add -Isrc/util/ to build flags and update for
moved files
* src/libvirt_private.syms: Export cgroup APIs since they're now
in util rather than linking directly to drivers
* src/xen/xs_internal.c: Disable bogus virEventRemoveHandle call
when built under PROXY
* proxy/Makefile.am: Update for changed file locations. Remove
bogus build of event.c
* tools/Makefile.am, tests/Makefile.am: Add -Isrc/util/ to build flags
2009-09-16 15:28:46 +00:00
|
|
|
virCgroupForDomain;
|
|
|
|
virCgroupForDriver;
|
2012-08-21 09:18:24 +00:00
|
|
|
virCgroupForEmulator;
|
2011-07-21 07:12:55 +00:00
|
|
|
virCgroupForVcpu;
|
Move all shared utility files to src/util/
* src/bridge.c, src/bridge.h, src/buf.c, src/buf.h, src/cgroup.c,
src/cgroup.h, src/conf.c, src/conf.h, src/event.c, src/event.h,
src/hash.c, src/hash.h, src/hostusb.c, src/hostusb.h,
src/iptables.c, src/iptables.h, src/logging.c, src/logging.h,
src/memory.c, src/memory.h, src/pci.c, src/pci.h, src/qparams.c,
src/qparams.h, src/stats_linux.c, src/stats_linux.h,
src/threads-pthread.c, src/threads-pthread.h, src/threads-win32.c,
src/threads-win32.h, src/threads.c, src/threads.h, src/util.c,
src/util.h, src/uuid.c, src/uuid.h, src/virterror.c,
src/virterror_internal.h, src/xml.c, src/xml.h: Move all files
into src/util/
* daemon/Makefile.am: Add -Isrc/util/ to build flags
* src/Makefile.am: Add -Isrc/util/ to build flags and update for
moved files
* src/libvirt_private.syms: Export cgroup APIs since they're now
in util rather than linking directly to drivers
* src/xen/xs_internal.c: Disable bogus virEventRemoveHandle call
when built under PROXY
* proxy/Makefile.am: Update for changed file locations. Remove
bogus build of event.c
* tools/Makefile.am, tests/Makefile.am: Add -Isrc/util/ to build flags
2009-09-16 15:28:46 +00:00
|
|
|
virCgroupFree;
|
2011-02-08 06:56:39 +00:00
|
|
|
virCgroupGetBlkioWeight;
|
2011-07-21 07:21:05 +00:00
|
|
|
virCgroupGetCpuCfsPeriod;
|
|
|
|
virCgroupGetCpuCfsQuota;
|
2012-03-02 02:54:23 +00:00
|
|
|
virCgroupGetCpuShares;
|
|
|
|
virCgroupGetCpuacctPercpuUsage;
|
2012-03-09 00:35:59 +00:00
|
|
|
virCgroupGetCpuacctStat;
|
Move all shared utility files to src/util/
* src/bridge.c, src/bridge.h, src/buf.c, src/buf.h, src/cgroup.c,
src/cgroup.h, src/conf.c, src/conf.h, src/event.c, src/event.h,
src/hash.c, src/hash.h, src/hostusb.c, src/hostusb.h,
src/iptables.c, src/iptables.h, src/logging.c, src/logging.h,
src/memory.c, src/memory.h, src/pci.c, src/pci.h, src/qparams.c,
src/qparams.h, src/stats_linux.c, src/stats_linux.h,
src/threads-pthread.c, src/threads-pthread.h, src/threads-win32.c,
src/threads-win32.h, src/threads.c, src/threads.h, src/util.c,
src/util.h, src/uuid.c, src/uuid.h, src/virterror.c,
src/virterror_internal.h, src/xml.c, src/xml.h: Move all files
into src/util/
* daemon/Makefile.am: Add -Isrc/util/ to build flags
* src/Makefile.am: Add -Isrc/util/ to build flags and update for
moved files
* src/libvirt_private.syms: Export cgroup APIs since they're now
in util rather than linking directly to drivers
* src/xen/xs_internal.c: Disable bogus virEventRemoveHandle call
when built under PROXY
* proxy/Makefile.am: Update for changed file locations. Remove
bogus build of event.c
* tools/Makefile.am, tests/Makefile.am: Add -Isrc/util/ to build flags
2009-09-16 15:28:46 +00:00
|
|
|
virCgroupGetCpuacctUsage;
|
2012-08-21 09:18:30 +00:00
|
|
|
virCgroupGetCpusetCpus;
|
2011-12-20 08:34:58 +00:00
|
|
|
virCgroupGetCpusetMems;
|
2009-09-21 14:31:22 +00:00
|
|
|
virCgroupGetFreezerState;
|
2012-03-02 02:54:23 +00:00
|
|
|
virCgroupGetMemSwapHardLimit;
|
2010-10-20 17:10:45 +00:00
|
|
|
virCgroupGetMemoryHardLimit;
|
|
|
|
virCgroupGetMemorySoftLimit;
|
|
|
|
virCgroupGetMemoryUsage;
|
2011-02-22 17:33:59 +00:00
|
|
|
virCgroupKill;
|
|
|
|
virCgroupKillPainfully;
|
2011-03-16 05:07:12 +00:00
|
|
|
virCgroupKillRecursive;
|
2010-10-29 09:32:16 +00:00
|
|
|
virCgroupMounted;
|
2012-08-21 09:18:25 +00:00
|
|
|
virCgroupMoveTask;
|
2011-03-07 23:41:40 +00:00
|
|
|
virCgroupPathOfController;
|
2010-10-20 17:10:45 +00:00
|
|
|
virCgroupRemove;
|
2011-11-08 11:00:34 +00:00
|
|
|
virCgroupSetBlkioDeviceWeight;
|
2011-02-08 06:56:39 +00:00
|
|
|
virCgroupSetBlkioWeight;
|
2011-07-21 07:21:05 +00:00
|
|
|
virCgroupSetCpuCfsPeriod;
|
|
|
|
virCgroupSetCpuCfsQuota;
|
2012-03-02 02:54:23 +00:00
|
|
|
virCgroupSetCpuShares;
|
2012-08-21 09:18:30 +00:00
|
|
|
virCgroupSetCpusetCpus;
|
2011-12-20 08:34:58 +00:00
|
|
|
virCgroupSetCpusetMems;
|
2009-09-21 14:31:22 +00:00
|
|
|
virCgroupSetFreezerState;
|
2012-03-02 02:54:23 +00:00
|
|
|
virCgroupSetMemSwapHardLimit;
|
2010-10-20 17:10:45 +00:00
|
|
|
virCgroupSetMemory;
|
2010-10-12 14:50:53 +00:00
|
|
|
virCgroupSetMemoryHardLimit;
|
|
|
|
virCgroupSetMemorySoftLimit;
|
2010-10-20 17:10:45 +00:00
|
|
|
|
|
|
|
|
2010-05-25 11:14:06 +00:00
|
|
|
# command.h
|
2011-03-22 22:22:37 +00:00
|
|
|
virCommandAbort;
|
2010-05-25 11:14:06 +00:00
|
|
|
virCommandAddArg;
|
2010-12-10 18:33:53 +00:00
|
|
|
virCommandAddArgBuffer;
|
2010-05-25 11:14:06 +00:00
|
|
|
virCommandAddArgFormat;
|
|
|
|
virCommandAddArgList;
|
|
|
|
virCommandAddArgPair;
|
|
|
|
virCommandAddArgSet;
|
2010-12-10 18:33:53 +00:00
|
|
|
virCommandAddEnvBuffer;
|
2011-05-05 20:32:52 +00:00
|
|
|
virCommandAddEnvFormat;
|
2010-05-25 11:14:06 +00:00
|
|
|
virCommandAddEnvPair;
|
|
|
|
virCommandAddEnvPass;
|
|
|
|
virCommandAddEnvPassCommon;
|
|
|
|
virCommandAddEnvString;
|
2012-02-01 21:09:54 +00:00
|
|
|
virCommandAllowCap;
|
2010-05-25 11:14:06 +00:00
|
|
|
virCommandClearCaps;
|
|
|
|
virCommandDaemonize;
|
2011-05-06 14:37:36 +00:00
|
|
|
virCommandExec;
|
2010-05-25 11:14:06 +00:00
|
|
|
virCommandFree;
|
2010-11-22 13:31:35 +00:00
|
|
|
virCommandHandshakeNotify;
|
|
|
|
virCommandHandshakeWait;
|
2010-05-25 11:14:06 +00:00
|
|
|
virCommandNew;
|
|
|
|
virCommandNewArgList;
|
|
|
|
virCommandNewArgs;
|
|
|
|
virCommandNonblockingFDs;
|
|
|
|
virCommandPreserveFD;
|
2010-11-22 13:31:35 +00:00
|
|
|
virCommandRequireHandshake;
|
2010-05-25 11:14:06 +00:00
|
|
|
virCommandRun;
|
|
|
|
virCommandRunAsync;
|
|
|
|
virCommandSetErrorBuffer;
|
|
|
|
virCommandSetErrorFD;
|
|
|
|
virCommandSetInputBuffer;
|
|
|
|
virCommandSetInputFD;
|
|
|
|
virCommandSetOutputBuffer;
|
|
|
|
virCommandSetOutputFD;
|
|
|
|
virCommandSetPidFile;
|
|
|
|
virCommandSetPreExecHook;
|
|
|
|
virCommandSetWorkingDirectory;
|
|
|
|
virCommandToString;
|
|
|
|
virCommandTransferFD;
|
|
|
|
virCommandWait;
|
|
|
|
virCommandWriteArgLog;
|
2011-05-10 18:42:59 +00:00
|
|
|
virFork;
|
|
|
|
virRun;
|
2010-05-25 11:14:06 +00:00
|
|
|
|
|
|
|
|
2010-10-20 17:10:45 +00:00
|
|
|
# conf.h
|
|
|
|
virConfFree;
|
|
|
|
virConfFreeValue;
|
|
|
|
virConfGetValue;
|
|
|
|
virConfNew;
|
|
|
|
virConfReadFile;
|
|
|
|
virConfReadMem;
|
|
|
|
virConfSetValue;
|
|
|
|
virConfWriteFile;
|
|
|
|
virConfWriteMem;
|
Move all shared utility files to src/util/
* src/bridge.c, src/bridge.h, src/buf.c, src/buf.h, src/cgroup.c,
src/cgroup.h, src/conf.c, src/conf.h, src/event.c, src/event.h,
src/hash.c, src/hash.h, src/hostusb.c, src/hostusb.h,
src/iptables.c, src/iptables.h, src/logging.c, src/logging.h,
src/memory.c, src/memory.h, src/pci.c, src/pci.h, src/qparams.c,
src/qparams.h, src/stats_linux.c, src/stats_linux.h,
src/threads-pthread.c, src/threads-pthread.h, src/threads-win32.c,
src/threads-win32.h, src/threads.c, src/threads.h, src/util.c,
src/util.h, src/uuid.c, src/uuid.h, src/virterror.c,
src/virterror_internal.h, src/xml.c, src/xml.h: Move all files
into src/util/
* daemon/Makefile.am: Add -Isrc/util/ to build flags
* src/Makefile.am: Add -Isrc/util/ to build flags and update for
moved files
* src/libvirt_private.syms: Export cgroup APIs since they're now
in util rather than linking directly to drivers
* src/xen/xs_internal.c: Disable bogus virEventRemoveHandle call
when built under PROXY
* proxy/Makefile.am: Update for changed file locations. Remove
bogus build of event.c
* tools/Makefile.am, tests/Makefile.am: Add -Isrc/util/ to build flags
2009-09-16 15:28:46 +00:00
|
|
|
|
|
|
|
|
Adds CPU selection infrastructure
Each driver supporting CPU selection must fill in host CPU capabilities.
When filling them, drivers for hypervisors running on the same node as
libvirtd can use cpuNodeData() to obtain raw CPU data. Other drivers,
such as VMware, need to implement their own way of getting such data.
Raw data can be decoded into virCPUDefPtr using cpuDecode() function.
When implementing virConnectCompareCPU(), a hypervisor driver can just
call cpuCompareXML() function with host CPU capabilities.
For each guest for which a driver supports selecting CPU models, it must
set the appropriate feature in guest's capabilities:
virCapabilitiesAddGuestFeature(guest, "cpuselection", 1, 0)
Actions needed when a domain is being created depend on whether the
hypervisor understands raw CPU data (currently CPUID for i686, x86_64
architectures) or symbolic names has to be used.
Typical use by hypervisors which prefer CPUID (such as VMware and Xen):
- convert guest CPU configuration from domain's XML into a set of raw
data structures each representing one of the feature policies:
cpuEncode(conn, architecture, guest_cpu_config,
&forced_data, &required_data, &optional_data,
&disabled_data, &forbidden_data)
- create a mask or whatever the hypervisor expects to see and pass it
to the hypervisor
Typical use by hypervisors with symbolic model names (such as QEMU):
- get raw CPU data for a computed guest CPU:
cpuGuestData(conn, host_cpu, guest_cpu_config, &data)
- decode raw data into virCPUDefPtr with a possible restriction on
allowed model names:
cpuDecode(conn, guest, data, n_allowed_models, allowed_models)
- pass guest->model and guest->features to the hypervisor
* src/cpu/cpu.c src/cpu/cpu.h src/cpu/cpu_generic.c
src/cpu/cpu_generic.h src/cpu/cpu_map.c src/cpu/cpu_map.h
src/cpu/cpu_x86.c src/cpu/cpu_x86.h src/cpu/cpu_x86_data.h
* configure.in: check for CPUID instruction
* src/Makefile.am: glue the new files in
* src/libvirt_private.syms: add new private symbols
* po/POTFILES.in: add new cpu files containing translatable strings
2009-12-18 15:02:11 +00:00
|
|
|
# cpu.h
|
2010-01-25 17:27:56 +00:00
|
|
|
cpuBaseline;
|
|
|
|
cpuBaselineXML;
|
Adds CPU selection infrastructure
Each driver supporting CPU selection must fill in host CPU capabilities.
When filling them, drivers for hypervisors running on the same node as
libvirtd can use cpuNodeData() to obtain raw CPU data. Other drivers,
such as VMware, need to implement their own way of getting such data.
Raw data can be decoded into virCPUDefPtr using cpuDecode() function.
When implementing virConnectCompareCPU(), a hypervisor driver can just
call cpuCompareXML() function with host CPU capabilities.
For each guest for which a driver supports selecting CPU models, it must
set the appropriate feature in guest's capabilities:
virCapabilitiesAddGuestFeature(guest, "cpuselection", 1, 0)
Actions needed when a domain is being created depend on whether the
hypervisor understands raw CPU data (currently CPUID for i686, x86_64
architectures) or symbolic names has to be used.
Typical use by hypervisors which prefer CPUID (such as VMware and Xen):
- convert guest CPU configuration from domain's XML into a set of raw
data structures each representing one of the feature policies:
cpuEncode(conn, architecture, guest_cpu_config,
&forced_data, &required_data, &optional_data,
&disabled_data, &forbidden_data)
- create a mask or whatever the hypervisor expects to see and pass it
to the hypervisor
Typical use by hypervisors with symbolic model names (such as QEMU):
- get raw CPU data for a computed guest CPU:
cpuGuestData(conn, host_cpu, guest_cpu_config, &data)
- decode raw data into virCPUDefPtr with a possible restriction on
allowed model names:
cpuDecode(conn, guest, data, n_allowed_models, allowed_models)
- pass guest->model and guest->features to the hypervisor
* src/cpu/cpu.c src/cpu/cpu.h src/cpu/cpu_generic.c
src/cpu/cpu_generic.h src/cpu/cpu_map.c src/cpu/cpu_map.h
src/cpu/cpu_x86.c src/cpu/cpu_x86.h src/cpu/cpu_x86_data.h
* configure.in: check for CPUID instruction
* src/Makefile.am: glue the new files in
* src/libvirt_private.syms: add new private symbols
* po/POTFILES.in: add new cpu files containing translatable strings
2009-12-18 15:02:11 +00:00
|
|
|
cpuCompare;
|
|
|
|
cpuCompareXML;
|
|
|
|
cpuDataFree;
|
|
|
|
cpuDecode;
|
|
|
|
cpuEncode;
|
|
|
|
cpuGuestData;
|
2010-10-20 17:10:45 +00:00
|
|
|
cpuHasFeature;
|
2010-09-16 14:56:07 +00:00
|
|
|
cpuMapOverride;
|
Adds CPU selection infrastructure
Each driver supporting CPU selection must fill in host CPU capabilities.
When filling them, drivers for hypervisors running on the same node as
libvirtd can use cpuNodeData() to obtain raw CPU data. Other drivers,
such as VMware, need to implement their own way of getting such data.
Raw data can be decoded into virCPUDefPtr using cpuDecode() function.
When implementing virConnectCompareCPU(), a hypervisor driver can just
call cpuCompareXML() function with host CPU capabilities.
For each guest for which a driver supports selecting CPU models, it must
set the appropriate feature in guest's capabilities:
virCapabilitiesAddGuestFeature(guest, "cpuselection", 1, 0)
Actions needed when a domain is being created depend on whether the
hypervisor understands raw CPU data (currently CPUID for i686, x86_64
architectures) or symbolic names has to be used.
Typical use by hypervisors which prefer CPUID (such as VMware and Xen):
- convert guest CPU configuration from domain's XML into a set of raw
data structures each representing one of the feature policies:
cpuEncode(conn, architecture, guest_cpu_config,
&forced_data, &required_data, &optional_data,
&disabled_data, &forbidden_data)
- create a mask or whatever the hypervisor expects to see and pass it
to the hypervisor
Typical use by hypervisors with symbolic model names (such as QEMU):
- get raw CPU data for a computed guest CPU:
cpuGuestData(conn, host_cpu, guest_cpu_config, &data)
- decode raw data into virCPUDefPtr with a possible restriction on
allowed model names:
cpuDecode(conn, guest, data, n_allowed_models, allowed_models)
- pass guest->model and guest->features to the hypervisor
* src/cpu/cpu.c src/cpu/cpu.h src/cpu/cpu_generic.c
src/cpu/cpu_generic.h src/cpu/cpu_map.c src/cpu/cpu_map.h
src/cpu/cpu_x86.c src/cpu/cpu_x86.h src/cpu/cpu_x86_data.h
* configure.in: check for CPUID instruction
* src/Makefile.am: glue the new files in
* src/libvirt_private.syms: add new private symbols
* po/POTFILES.in: add new cpu files containing translatable strings
2009-12-18 15:02:11 +00:00
|
|
|
cpuNodeData;
|
2010-03-23 08:32:50 +00:00
|
|
|
cpuUpdate;
|
Adds CPU selection infrastructure
Each driver supporting CPU selection must fill in host CPU capabilities.
When filling them, drivers for hypervisors running on the same node as
libvirtd can use cpuNodeData() to obtain raw CPU data. Other drivers,
such as VMware, need to implement their own way of getting such data.
Raw data can be decoded into virCPUDefPtr using cpuDecode() function.
When implementing virConnectCompareCPU(), a hypervisor driver can just
call cpuCompareXML() function with host CPU capabilities.
For each guest for which a driver supports selecting CPU models, it must
set the appropriate feature in guest's capabilities:
virCapabilitiesAddGuestFeature(guest, "cpuselection", 1, 0)
Actions needed when a domain is being created depend on whether the
hypervisor understands raw CPU data (currently CPUID for i686, x86_64
architectures) or symbolic names has to be used.
Typical use by hypervisors which prefer CPUID (such as VMware and Xen):
- convert guest CPU configuration from domain's XML into a set of raw
data structures each representing one of the feature policies:
cpuEncode(conn, architecture, guest_cpu_config,
&forced_data, &required_data, &optional_data,
&disabled_data, &forbidden_data)
- create a mask or whatever the hypervisor expects to see and pass it
to the hypervisor
Typical use by hypervisors with symbolic model names (such as QEMU):
- get raw CPU data for a computed guest CPU:
cpuGuestData(conn, host_cpu, guest_cpu_config, &data)
- decode raw data into virCPUDefPtr with a possible restriction on
allowed model names:
cpuDecode(conn, guest, data, n_allowed_models, allowed_models)
- pass guest->model and guest->features to the hypervisor
* src/cpu/cpu.c src/cpu/cpu.h src/cpu/cpu_generic.c
src/cpu/cpu_generic.h src/cpu/cpu_map.c src/cpu/cpu_map.h
src/cpu/cpu_x86.c src/cpu/cpu_x86.h src/cpu/cpu_x86_data.h
* configure.in: check for CPUID instruction
* src/Makefile.am: glue the new files in
* src/libvirt_private.syms: add new private symbols
* po/POTFILES.in: add new cpu files containing translatable strings
2009-12-18 15:02:11 +00:00
|
|
|
|
|
|
|
|
2009-12-18 13:44:55 +00:00
|
|
|
# cpu_conf.h
|
|
|
|
virCPUDefAddFeature;
|
2010-03-23 08:34:04 +00:00
|
|
|
virCPUDefCopy;
|
2011-12-19 14:41:16 +00:00
|
|
|
virCPUDefCopyModel;
|
2010-10-20 17:10:45 +00:00
|
|
|
virCPUDefFormat;
|
|
|
|
virCPUDefFormatBuf;
|
|
|
|
virCPUDefFree;
|
2011-12-19 14:41:16 +00:00
|
|
|
virCPUDefFreeModel;
|
2010-10-20 17:10:45 +00:00
|
|
|
virCPUDefParseXML;
|
2011-12-21 12:47:17 +00:00
|
|
|
virCPUModeTypeToString;
|
2009-12-18 13:44:55 +00:00
|
|
|
|
|
|
|
|
2009-01-05 14:05:29 +00:00
|
|
|
# datatypes.h
|
Convert public datatypes to inherit from virObject
This converts the following public API datatypes to use the
virObject infrastructure:
virConnectPtr
virDomainPtr
virDomainSnapshotPtr
virInterfacePtr
virNetworkPtr
virNodeDevicePtr
virNWFilterPtr
virSecretPtr
virStreamPtr
virStorageVolPtr
virStoragePoolPtr
The code is significantly simplified, since the mutex in the
virConnectPtr object now only needs to be held when accessing
the per-connection virError object instance. All other operations
are completely lock free.
* src/datatypes.c, src/datatypes.h, src/libvirt.c: Convert
public datatypes to use virObject
* src/conf/domain_event.c, src/phyp/phyp_driver.c,
src/qemu/qemu_command.c, src/qemu/qemu_migration.c,
src/qemu/qemu_process.c, src/storage/storage_driver.c,
src/vbox/vbox_tmpl.c, src/xen/xend_internal.c,
tests/qemuxml2argvtest.c, tests/qemuxmlnstest.c,
tests/sexpr2xmltest.c, tests/xmconfigtest.c: Convert
to use virObjectUnref/virObjectRef
Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
2012-07-31 16:55:36 +00:00
|
|
|
virConnectClass;
|
|
|
|
virDomainClass;
|
|
|
|
virDomainSnapshotClass;
|
2012-04-02 15:45:01 +00:00
|
|
|
virGetConnect;
|
2009-01-05 14:05:29 +00:00
|
|
|
virGetDomain;
|
2010-10-20 17:10:45 +00:00
|
|
|
virGetDomainSnapshot;
|
2009-05-20 14:26:49 +00:00
|
|
|
virGetInterface;
|
2010-10-20 17:10:45 +00:00
|
|
|
virGetNWFilter;
|
2009-01-05 14:05:29 +00:00
|
|
|
virGetNetwork;
|
2010-10-20 17:10:45 +00:00
|
|
|
virGetNodeDevice;
|
|
|
|
virGetSecret;
|
2009-01-05 14:05:29 +00:00
|
|
|
virGetStoragePool;
|
|
|
|
virGetStorageVol;
|
2010-10-20 17:10:45 +00:00
|
|
|
virGetStream;
|
Convert public datatypes to inherit from virObject
This converts the following public API datatypes to use the
virObject infrastructure:
virConnectPtr
virDomainPtr
virDomainSnapshotPtr
virInterfacePtr
virNetworkPtr
virNodeDevicePtr
virNWFilterPtr
virSecretPtr
virStreamPtr
virStorageVolPtr
virStoragePoolPtr
The code is significantly simplified, since the mutex in the
virConnectPtr object now only needs to be held when accessing
the per-connection virError object instance. All other operations
are completely lock free.
* src/datatypes.c, src/datatypes.h, src/libvirt.c: Convert
public datatypes to use virObject
* src/conf/domain_event.c, src/phyp/phyp_driver.c,
src/qemu/qemu_command.c, src/qemu/qemu_migration.c,
src/qemu/qemu_process.c, src/storage/storage_driver.c,
src/vbox/vbox_tmpl.c, src/xen/xend_internal.c,
tests/qemuxml2argvtest.c, tests/qemuxmlnstest.c,
tests/sexpr2xmltest.c, tests/xmconfigtest.c: Convert
to use virObjectUnref/virObjectRef
Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
2012-07-31 16:55:36 +00:00
|
|
|
virInterfaceClass;
|
|
|
|
virNetworkClass;
|
|
|
|
virNodeDeviceClass;
|
|
|
|
virNWFilterClass;
|
|
|
|
virSecretClass;
|
|
|
|
virStoragePoolClass;
|
|
|
|
virStorageVolClass;
|
|
|
|
virStreamClass;
|
2010-10-20 17:10:45 +00:00
|
|
|
|
|
|
|
|
2012-08-16 15:41:06 +00:00
|
|
|
# device_conf.h
|
|
|
|
virDeviceAddressPciMultiTypeFromString;
|
|
|
|
virDeviceAddressPciMultiTypeToString;
|
2012-08-16 15:42:14 +00:00
|
|
|
virDevicePCIAddressEqual;
|
2012-08-16 15:41:06 +00:00
|
|
|
virDevicePCIAddressFormat;
|
|
|
|
virDevicePCIAddressIsValid;
|
|
|
|
virDevicePCIAddressParseXML;
|
|
|
|
|
2010-10-20 17:10:45 +00:00
|
|
|
# dnsmasq.h
|
|
|
|
dnsmasqAddDhcpHost;
|
2011-06-24 10:04:39 +00:00
|
|
|
dnsmasqAddHost;
|
2010-10-20 17:10:45 +00:00
|
|
|
dnsmasqContextFree;
|
|
|
|
dnsmasqContextNew;
|
|
|
|
dnsmasqDelete;
|
|
|
|
dnsmasqReload;
|
|
|
|
dnsmasqSave;
|
2009-01-05 14:05:29 +00:00
|
|
|
|
|
|
|
|
Move qemu_audit.h helpers into shared code
The LXC and UML drivers can both make use of auditing. Move
the qemu_audit.{c,h} files to src/conf/domain_audit.{c,h}
* src/conf/domain_audit.c: Rename from src/qemu/qemu_audit.c
* src/conf/domain_audit.h: Rename from src/qemu/qemu_audit.h
* src/Makefile.am: Remove qemu_audit.{c,h}, add domain_audit.{c,h}
* src/qemu/qemu_audit.h, src/qemu/qemu_cgroup.c,
src/qemu/qemu_command.c, src/qemu/qemu_driver.c,
src/qemu/qemu_hotplug.c, src/qemu/qemu_migration.c,
src/qemu/qemu_process.c: Update for changed audit API names
2011-07-04 10:56:13 +00:00
|
|
|
# domain_audit.h
|
|
|
|
virDomainAuditCgroup;
|
|
|
|
virDomainAuditCgroupMajor;
|
|
|
|
virDomainAuditCgroupPath;
|
|
|
|
virDomainAuditDisk;
|
2011-07-04 11:00:33 +00:00
|
|
|
virDomainAuditFS;
|
Move qemu_audit.h helpers into shared code
The LXC and UML drivers can both make use of auditing. Move
the qemu_audit.{c,h} files to src/conf/domain_audit.{c,h}
* src/conf/domain_audit.c: Rename from src/qemu/qemu_audit.c
* src/conf/domain_audit.h: Rename from src/qemu/qemu_audit.h
* src/Makefile.am: Remove qemu_audit.{c,h}, add domain_audit.{c,h}
* src/qemu/qemu_audit.h, src/qemu/qemu_cgroup.c,
src/qemu/qemu_command.c, src/qemu/qemu_driver.c,
src/qemu/qemu_hotplug.c, src/qemu/qemu_migration.c,
src/qemu/qemu_process.c: Update for changed audit API names
2011-07-04 10:56:13 +00:00
|
|
|
virDomainAuditHostdev;
|
|
|
|
virDomainAuditMemory;
|
|
|
|
virDomainAuditNet;
|
|
|
|
virDomainAuditNetDevice;
|
2011-09-02 15:09:14 +00:00
|
|
|
virDomainAuditRedirdev;
|
Move qemu_audit.h helpers into shared code
The LXC and UML drivers can both make use of auditing. Move
the qemu_audit.{c,h} files to src/conf/domain_audit.{c,h}
* src/conf/domain_audit.c: Rename from src/qemu/qemu_audit.c
* src/conf/domain_audit.h: Rename from src/qemu/qemu_audit.h
* src/Makefile.am: Remove qemu_audit.{c,h}, add domain_audit.{c,h}
* src/qemu/qemu_audit.h, src/qemu/qemu_cgroup.c,
src/qemu/qemu_command.c, src/qemu/qemu_driver.c,
src/qemu/qemu_hotplug.c, src/qemu/qemu_migration.c,
src/qemu/qemu_process.c: Update for changed audit API names
2011-07-04 10:56:13 +00:00
|
|
|
virDomainAuditSecurityLabel;
|
|
|
|
virDomainAuditStart;
|
|
|
|
virDomainAuditStop;
|
|
|
|
virDomainAuditVcpu;
|
|
|
|
|
|
|
|
|
2009-01-05 14:05:29 +00:00
|
|
|
# domain_conf.h
|
2011-11-08 11:00:33 +00:00
|
|
|
virBlkioDeviceWeightArrayClear;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDiskNameToBusDeviceIndex;
|
|
|
|
virDiskNameToIndex;
|
2011-06-26 08:09:00 +00:00
|
|
|
virDomainActualNetDefFree;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainAssignDef;
|
2011-09-15 13:07:51 +00:00
|
|
|
virDomainBlockedReasonTypeFromString;
|
|
|
|
virDomainBlockedReasonTypeToString;
|
2012-09-18 09:38:18 +00:00
|
|
|
virDomainBootMenuTypeFromString;
|
|
|
|
virDomainBootMenuTypeToString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainChrConsoleTargetTypeFromString;
|
|
|
|
virDomainChrConsoleTargetTypeToString;
|
|
|
|
virDomainChrDefForeach;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainChrDefFree;
|
2011-04-14 16:05:14 +00:00
|
|
|
virDomainChrDefNew;
|
2011-11-15 08:01:31 +00:00
|
|
|
virDomainChrSourceDefCopy;
|
domain_conf: split source data out from ChrDef
This opens up the possibility of reusing the smaller ChrSourceDef
for both qemu monitor and a passthrough smartcard device.
* src/conf/domain_conf.h (_virDomainChrDef): Factor host
details...
(_virDomainChrSourceDef): ...into new struct.
(virDomainChrSourceDefFree): New prototype.
* src/conf/domain_conf.c (virDomainChrDefFree)
(virDomainChrDefParseXML, virDomainChrDefFormat): Split...
(virDomainChrSourceDefClear, virDomainChrSourceDefFree)
(virDomainChrSourceDefParseXML, virDomainChrSourceDefFormat):
...into new functions.
(virDomainChrDefParseTargetXML): Update clients to reflect type
split.
* src/vmx/vmx.c (virVMXParseSerial, virVMXParseParallel)
(virVMXFormatSerial, virVMXFormatParallel): Likewise.
* src/xen/xen_driver.c (xenUnifiedDomainOpenConsole): Likewise.
* src/xen/xend_internal.c (xenDaemonParseSxprChar)
(xenDaemonFormatSxprChr): Likewise.
* src/vbox/vbox_tmpl.c (vboxDomainDumpXML, vboxAttachSerial)
(vboxAttachParallel): Likewise.
* src/security/security_dac.c (virSecurityDACSetChardevLabel)
(virSecurityDACSetChardevCallback)
(virSecurityDACRestoreChardevLabel)
(virSecurityDACRestoreChardevCallback): Likewise.
* src/security/security_selinux.c (SELinuxSetSecurityChardevLabel)
(SELinuxSetSecurityChardevCallback)
(SELinuxRestoreSecurityChardevLabel)
(SELinuxSetSecurityChardevCallback): Likewise.
* src/security/virt-aa-helper.c (get_files): Likewise.
* src/lxc/lxc_driver.c (lxcVmStart, lxcDomainOpenConsole):
Likewise.
* src/uml/uml_conf.c (umlBuildCommandLineChr): Likewise.
* src/uml/uml_driver.c (umlIdentifyOneChrPTY, umlIdentifyChrPTY)
(umlDomainOpenConsole): Likewise.
* src/qemu/qemu_command.c (qemuBuildChrChardevStr)
(qemuBuildChrArgStr, qemuBuildCommandLine)
(qemuParseCommandLineChr): Likewise.
* src/qemu/qemu_domain.c (qemuDomainObjPrivateXMLFormat)
(qemuDomainObjPrivateXMLParse): Likewise.
* src/qemu/qemu_cgroup.c (qemuSetupChardevCgroup): Likewise.
* src/qemu/qemu_hotplug.c (qemuDomainAttachNetDevice): Likewise.
* src/qemu/qemu_driver.c (qemudFindCharDevicePTYsMonitor)
(qemudFindCharDevicePTYs, qemuPrepareChardevDevice)
(qemuPrepareMonitorChr, qemudShutdownVMDaemon)
(qemuDomainOpenConsole): Likewise.
* src/qemu/qemu_command.h (qemuBuildChrChardevStr)
(qemuBuildChrArgStr): Delete, now that they are static.
* src/libvirt_private.syms (domain_conf.h): New exports.
* cfg.mk (useless_free_options): Update list.
* tests/qemuxml2argvtest.c (testCompareXMLToArgvFiles): Update
tests.
2011-01-07 22:45:01 +00:00
|
|
|
virDomainChrSourceDefFree;
|
2011-02-04 02:23:31 +00:00
|
|
|
virDomainChrSpicevmcTypeFromString;
|
|
|
|
virDomainChrSpicevmcTypeToString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainChrTcpProtocolTypeFromString;
|
|
|
|
virDomainChrTcpProtocolTypeToString;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainChrTypeFromString;
|
|
|
|
virDomainChrTypeToString;
|
2012-02-06 13:59:16 +00:00
|
|
|
virDomainClockBasisTypeToString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainClockOffsetTypeFromString;
|
|
|
|
virDomainClockOffsetTypeToString;
|
|
|
|
virDomainConfigFile;
|
|
|
|
virDomainControllerDefFree;
|
2012-07-23 08:18:57 +00:00
|
|
|
virDomainControllerFind;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainControllerInsert;
|
|
|
|
virDomainControllerInsertPreAlloced;
|
2011-09-02 13:06:15 +00:00
|
|
|
virDomainControllerModelSCSITypeFromString;
|
|
|
|
virDomainControllerModelSCSITypeToString;
|
2012-01-02 21:35:12 +00:00
|
|
|
virDomainControllerModelUSBTypeFromString;
|
|
|
|
virDomainControllerModelUSBTypeToString;
|
2012-07-23 08:18:57 +00:00
|
|
|
virDomainControllerRemove;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainControllerTypeToString;
|
2012-03-15 11:40:33 +00:00
|
|
|
virDomainCpuPlacementModeTypeFromString;
|
|
|
|
virDomainCpuPlacementModeTypeToString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainDefAddImplicitControllers;
|
2011-05-27 09:47:30 +00:00
|
|
|
virDomainDefCheckABIStability;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainDefClearDeviceAliases;
|
|
|
|
virDomainDefClearPCIAddresses;
|
2012-07-03 13:30:25 +00:00
|
|
|
virDomainDefCompatibleDevice;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainDefFormat;
|
2011-09-17 12:57:30 +00:00
|
|
|
virDomainDefFormatInternal;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainDefFree;
|
2012-08-15 22:10:36 +00:00
|
|
|
virDomainDefGetSecurityLabelDef;
|
|
|
|
virDomainDiskDefGetSecurityLabelDef;
|
|
|
|
virDomainDefAddSecurityLabelDef;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainDefParseFile;
|
|
|
|
virDomainDefParseNode;
|
|
|
|
virDomainDefParseString;
|
|
|
|
virDomainDeleteConfig;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainDeviceAddressIsValid;
|
|
|
|
virDomainDeviceAddressTypeToString;
|
2012-03-01 18:47:34 +00:00
|
|
|
virDomainDeviceDefCopy;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainDeviceDefFree;
|
|
|
|
virDomainDeviceDefParse;
|
2012-10-11 05:09:00 +00:00
|
|
|
virDomainDeviceInfoCopy;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainDeviceInfoIterate;
|
2009-03-02 17:39:43 +00:00
|
|
|
virDomainDeviceTypeToString;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainDiskBusTypeToString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainDiskCacheTypeFromString;
|
|
|
|
virDomainDiskCacheTypeToString;
|
2012-01-12 09:31:14 +00:00
|
|
|
virDomainDiskCopyOnReadTypeFromString;
|
|
|
|
virDomainDiskCopyOnReadTypeToString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainDiskDefAssignAddress;
|
|
|
|
virDomainDiskDefForeachPath;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainDiskDefFree;
|
|
|
|
virDomainDiskDeviceTypeToString;
|
2010-04-21 14:28:21 +00:00
|
|
|
virDomainDiskErrorPolicyTypeFromString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainDiskErrorPolicyTypeToString;
|
2012-02-27 09:20:11 +00:00
|
|
|
virDomainDiskFindControllerModel;
|
2012-08-20 13:58:50 +00:00
|
|
|
virDomainDiskGeometryTransTypeFromString;
|
|
|
|
virDomainDiskGeometryTransTypeToString;
|
2011-04-22 03:09:32 +00:00
|
|
|
virDomainDiskIndexByName;
|
2009-08-14 09:31:36 +00:00
|
|
|
virDomainDiskInsert;
|
|
|
|
virDomainDiskInsertPreAlloced;
|
2010-04-21 14:28:21 +00:00
|
|
|
virDomainDiskIoTypeFromString;
|
|
|
|
virDomainDiskIoTypeToString;
|
snapshot: also support disks by path
I got confused when 'virsh domblkinfo dom disk' required the
path to a disk (which can be ambiguous, since a single file
can back multiple disks), rather than the unambiguous target
device name that I was using in disk snapshots. So, in true
developer fashion, I went for the best of both worlds - all
interfaces that operate on a disk (aka block) now accept
either the target name or the unambiguous path to the backing
file used by the disk.
* src/conf/domain_conf.h (virDomainDiskIndexByName): Add
parameter.
(virDomainDiskPathByName): New prototype.
* src/libvirt_private.syms (domain_conf.h): Export it.
* src/conf/domain_conf.c (virDomainDiskIndexByName): Also allow
searching by path, and decide whether ambiguity is okay.
(virDomainDiskPathByName): New function.
(virDomainDiskRemoveByName, virDomainSnapshotAlignDisks): Update
callers.
* src/qemu/qemu_driver.c (qemudDomainBlockPeek)
(qemuDomainAttachDeviceConfig, qemuDomainUpdateDeviceConfig)
(qemuDomainGetBlockInfo, qemuDiskPathToAlias): Likewise.
* src/qemu/qemu_process.c (qemuProcessFindDomainDiskByPath):
Likewise.
* src/libxl/libxl_driver.c (libxlDomainAttachDeviceDiskLive)
(libxlDomainDetachDeviceDiskLive, libxlDomainAttachDeviceConfig)
(libxlDomainUpdateDeviceConfig): Likewise.
* src/uml/uml_driver.c (umlDomainBlockPeek): Likewise.
* src/xen/xend_internal.c (xenDaemonDomainBlockPeek): Likewise.
* docs/formatsnapshot.html.in: Update documentation.
* tools/virsh.pod (domblkstat, domblkinfo): Likewise.
* docs/schemas/domaincommon.rng (diskTarget): Tighten pattern on
disk targets.
* docs/schemas/domainsnapshot.rng (disksnapshot): Update to match.
* tests/domainsnapshotxml2xmlin/disk_snapshot.xml: Update test.
2011-08-20 02:38:36 +00:00
|
|
|
virDomainDiskPathByName;
|
2010-08-23 09:31:26 +00:00
|
|
|
virDomainDiskRemove;
|
2011-04-22 03:09:32 +00:00
|
|
|
virDomainDiskRemoveByName;
|
2010-10-12 11:23:18 +00:00
|
|
|
virDomainDiskTypeFromString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainDiskTypeToString;
|
2012-08-21 09:18:36 +00:00
|
|
|
virDomainEmulatorPinAdd;
|
|
|
|
virDomainEmulatorPinDel;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainFSDefFree;
|
2012-05-29 18:46:38 +00:00
|
|
|
virDomainFSIndexByName;
|
2011-07-22 11:11:12 +00:00
|
|
|
virDomainFSTypeFromString;
|
|
|
|
virDomainFSTypeToString;
|
2012-01-17 12:44:18 +00:00
|
|
|
virDomainFSWrpolicyTypeFromString;
|
|
|
|
virDomainFSWrpolicyTypeToString;
|
2012-10-16 14:28:22 +00:00
|
|
|
virDomainFeatureStateTypeFromString;
|
|
|
|
virDomainFeatureStateTypeToString;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainFindByID;
|
|
|
|
virDomainFindByName;
|
|
|
|
virDomainFindByUUID;
|
2009-04-22 14:26:50 +00:00
|
|
|
virDomainGetRootFilesystem;
|
2011-05-26 14:15:54 +00:00
|
|
|
virDomainGraphicsAuthConnectedTypeFromString;
|
|
|
|
virDomainGraphicsAuthConnectedTypeToString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainGraphicsDefFree;
|
conf: add <listen> subelement to domain <graphics> element
Once it's plugged in, the <listen> element will be an optional
replacement for the "listen" attribute that graphics elements already
have. If the <listen> element is type='address', it will have an
attribute called 'address' which will contain an IP address or dns
name that the guest's display server should listen on. If, however,
type='network', the <listen> element should have an attribute called
'network' that will be set to the name of a network configuration to
get the IP address from.
* docs/schemas/domain.rng: updated to allow the <listen> element
* docs/formatdomain.html.in: document the <listen> element and its
attributes.
* src/conf/domain_conf.[hc]:
1) The domain parser, formatter, and data structure are modified to
support 0 or more <listen> subelements to each <graphics>
element. The old style "legacy" listen attribute is also still
accepted, and will be stored internally just as if it were a
separate <listen> element. On output (i.e. format), the address
attribute of the first <listen> element of type 'address' will be
duplicated in the legacy "listen" attribute of the <graphic>
element.
2) The "listenAddr" attribute has been removed from the unions in
virDomainGRaphicsDef for graphics types vnc, rdp, and spice.
This attribute is now in the <listen> subelement (aka
virDomainGraphicsListenDef)
3) Helper functions were written to provide simple access
(both Get and Set) to the listen elements and their attributes.
* src/libvirt_private.syms: export the listen helper functions
* src/qemu/qemu_command.c, src/qemu/qemu_hotplug.c,
src/qemu/qemu_migration.c, src/vbox/vbox_tmpl.c,
src/vmx/vmx.c, src/xenxs/xen_sxpr.c, src/xenxs/xen_xm.c
Modify all these files to use the listen helper functions rather
than directly referencing the (now missing) listenAddr
attribute. There can be multiple <listen> elements to a single
<graphics>, but the drivers all currently only support one, so all
replacements of direct access with a helper function indicate index
"0".
* tests/* - only 3 of these are new files added explicitly to test the
new <listen> element. All the others have been modified to reflect
the fact that any legacy "listen" attributes passed in to the domain
parse will be saved in a <listen> element (i.e. one of the
virDomainGraphicsListenDefs), and during the domain format function,
both the <listen> element as well as the legacy attributes will be
output.
2011-07-07 04:20:28 +00:00
|
|
|
virDomainGraphicsListenGetAddress;
|
|
|
|
virDomainGraphicsListenGetNetwork;
|
|
|
|
virDomainGraphicsListenGetType;
|
|
|
|
virDomainGraphicsListenSetAddress;
|
|
|
|
virDomainGraphicsListenSetNetwork;
|
|
|
|
virDomainGraphicsListenSetType;
|
2010-04-09 16:56:00 +00:00
|
|
|
virDomainGraphicsSpiceChannelModeTypeFromString;
|
|
|
|
virDomainGraphicsSpiceChannelModeTypeToString;
|
|
|
|
virDomainGraphicsSpiceChannelNameTypeFromString;
|
|
|
|
virDomainGraphicsSpiceChannelNameTypeToString;
|
2011-06-15 17:23:51 +00:00
|
|
|
virDomainGraphicsSpiceClipboardCopypasteTypeFromString;
|
|
|
|
virDomainGraphicsSpiceClipboardCopypasteTypeToString;
|
2011-04-14 08:44:20 +00:00
|
|
|
virDomainGraphicsSpiceImageCompressionTypeFromString;
|
2011-06-14 11:35:48 +00:00
|
|
|
virDomainGraphicsSpiceImageCompressionTypeToString;
|
2011-04-14 08:44:20 +00:00
|
|
|
virDomainGraphicsSpiceJpegCompressionTypeFromString;
|
|
|
|
virDomainGraphicsSpiceJpegCompressionTypeToString;
|
2012-03-09 07:26:24 +00:00
|
|
|
virDomainGraphicsSpiceMouseModeTypeFromString;
|
|
|
|
virDomainGraphicsSpiceMouseModeTypeToString;
|
2011-04-14 08:44:20 +00:00
|
|
|
virDomainGraphicsSpicePlaybackCompressionTypeFromString;
|
|
|
|
virDomainGraphicsSpicePlaybackCompressionTypeToString;
|
2011-05-23 15:16:42 +00:00
|
|
|
virDomainGraphicsSpiceStreamingModeTypeFromString;
|
|
|
|
virDomainGraphicsSpiceStreamingModeTypeToString;
|
2011-04-14 08:44:20 +00:00
|
|
|
virDomainGraphicsSpiceZlibCompressionTypeFromString;
|
|
|
|
virDomainGraphicsSpiceZlibCompressionTypeToString;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainGraphicsTypeFromString;
|
2010-03-22 18:44:58 +00:00
|
|
|
virDomainGraphicsTypeToString;
|
blockjob: react to active block copy
For now, disk migration via block copy job is not implemented in
libvirt. But when we do implement it, we have to deal with the
fact that qemu does not yet provide an easy way to re-start a qemu
process with mirroring still intact. Paolo has proposed an idea
for a persistent dirty bitmap that might make this possible, but
until that design is complete, it's hard to say what changes
libvirt would need. Even something like 'virDomainSave' becomes
hairy, if you realize the implications that 'virDomainRestore'
would be stuck with recreating the same mirror layout.
But if we step back and look at the bigger picture, we realize that
the initial client of live storage migration via disk mirroring is
oVirt, which always uses transient domains, and that if a transient
domain is destroyed while a mirror exists, oVirt can easily restart
the storage migration by creating a new domain that visits just the
source storage, with no loss in data.
We can make life a lot easier by being cowards for now, forbidding
certain operations on a domain. This patch guarantees that we
never get in a state where we would have to restart a domain with
a mirroring block copy, by preventing saves, snapshots, migration,
hot unplug of a disk in use, and conversion to a persistent domain
(thankfully, it is still relatively easy to 'virsh undefine' a
running domain to temporarily make it transient, run tests on
'virsh blockcopy', then 'virsh define' to restore the persistence).
Later, if the qemu design is enhanced, we can relax our code.
The change to qemudDomainDefine looks a bit odd for undoing an
assignment, rather than probing up front to avoid the assignment,
but this is because of how virDomainAssignDef combines both a
lookup and assignment into a single function call.
* src/conf/domain_conf.h (virDomainHasDiskMirror): New prototype.
* src/conf/domain_conf.c (virDomainHasDiskMirror): New function.
* src/libvirt_private.syms (domain_conf.h): Export it.
* src/qemu/qemu_driver.c (qemuDomainSaveInternal)
(qemuDomainSnapshotCreateXML, qemuDomainRevertToSnapshot)
(qemuDomainBlockJobImpl, qemudDomainDefine): Prevent dangerous
actions while block copy is already in action.
* src/qemu/qemu_hotplug.c (qemuDomainDetachDiskDevice): Likewise.
* src/qemu/qemu_migration.c (qemuMigrationIsAllowed): Likewise.
2012-04-10 02:39:47 +00:00
|
|
|
virDomainHasDiskMirror;
|
2012-01-31 09:16:54 +00:00
|
|
|
virDomainHostdevDefAlloc;
|
|
|
|
virDomainHostdevDefClear;
|
2009-04-24 12:19:00 +00:00
|
|
|
virDomainHostdevDefFree;
|
2012-02-27 06:46:47 +00:00
|
|
|
virDomainHostdevFind;
|
|
|
|
virDomainHostdevInsert;
|
2009-08-14 07:31:10 +00:00
|
|
|
virDomainHostdevModeTypeToString;
|
2012-02-27 06:46:47 +00:00
|
|
|
virDomainHostdevRemove;
|
2009-08-14 07:31:10 +00:00
|
|
|
virDomainHostdevSubsysTypeToString;
|
2011-09-02 14:20:40 +00:00
|
|
|
virDomainHubTypeFromString;
|
|
|
|
virDomainHubTypeToString;
|
2012-10-16 16:25:56 +00:00
|
|
|
virDomainHypervTypeFromString;
|
|
|
|
virDomainHypervTypeToString;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainInputDefFree;
|
2011-06-20 08:26:47 +00:00
|
|
|
virDomainIoEventFdTypeFromString;
|
|
|
|
virDomainIoEventFdTypeToString;
|
2012-03-07 02:06:30 +00:00
|
|
|
virDomainLeaseDefFree;
|
2011-05-18 16:20:53 +00:00
|
|
|
virDomainLeaseIndex;
|
|
|
|
virDomainLeaseInsert;
|
|
|
|
virDomainLeaseInsertPreAlloc;
|
|
|
|
virDomainLeaseInsertPreAlloced;
|
|
|
|
virDomainLeaseRemove;
|
|
|
|
virDomainLeaseRemoveAt;
|
2010-10-12 11:23:18 +00:00
|
|
|
virDomainLifecycleCrashTypeFromString;
|
|
|
|
virDomainLifecycleCrashTypeToString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainLifecycleTypeFromString;
|
|
|
|
virDomainLifecycleTypeToString;
|
2011-12-12 05:16:49 +00:00
|
|
|
virDomainLiveConfigHelperMethod;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainLoadAllConfigs;
|
2012-09-06 20:17:01 +00:00
|
|
|
virDomainLockFailureTypeFromString;
|
|
|
|
virDomainLockFailureTypeToString;
|
2012-10-12 09:50:47 +00:00
|
|
|
virDomainLookupVcpuPin;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainMemballoonModelTypeFromString;
|
|
|
|
virDomainMemballoonModelTypeToString;
|
2012-08-15 07:51:58 +00:00
|
|
|
virDomainMemDumpTypeFromString;
|
|
|
|
virDomainMemDumpTypeToString;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainNetDefFree;
|
2012-01-02 21:35:12 +00:00
|
|
|
virDomainNetFind;
|
qemu: fix attach/detach of netdevs with matching mac addrs
This resolves:
https://bugzilla.redhat.com/show_bug.cgi?id=862515
which describes inconsistencies in dealing with duplicate mac
addresses on network devices in a domain.
(at any rate, it resolves *almost* everything, and prints out an
informative error message for the one problem that isn't solved, but
has a workaround.)
A synopsis of the problems:
1) you can't do a persistent attach-interface of a device with a mac
address that matches an existing device.
2) you *can* do a live attach-interface of such a device.
3) you *can* directly edit a domain and put in two devices with
matching mac addresses.
4) When running virsh detach-device (live or config), only MAC address
is checked when matching the device to remove, so the first device
with the desired mac address will be removed. This isn't always the
one that's wanted.
5) when running virsh detach-interface (live or config), the only two
items that can be specified to match against are mac address and model
type (virtio, etc) - if multiple netdevs match both of those
attributes, it again just finds the first one added and assumes that
is the only match.
Since it is completely valid to have multiple network devices with the
same MAC address (although it can cause problems in many cases, there
*are* valid use cases), what is needed is:
1) remove the restriction that prohibits doing a persistent add of a
netdev with a duplicate mac address.
2) enhance the backend of virDomainDetachDeviceFlags to check for
something that *is* guaranteed unique (but still work with just mac
address, as long as it yields only a single results.
This patch does three things:
1) removes the check for duplicate mac address during a persistent
netdev attach.
2) unifies the searching for both live and config detach of netdevices
in the subordinate functions of qemuDomainModifyDeviceFlags() to use the
new function virDomainNetFindIdx (which matches mac address and PCI
address if available, checking for duplicates if only mac address was
specified). This function returns -2 if multiple matches are found,
allowing the callers to print out an appropriate message.
Steps 1 & 2 are enough to fully fix the problem when using virsh
attach-device and detach-device (which require an XML description of
the device rather than a bunch of commandline args)
3) modifies the virsh detach-interface command to check for multiple
matches of mac address and show an error message suggesting use of the
detach-device command in cases where there are multiple matching mac
addresses.
Later we should decide how we want to input a PCI address on the virsh
commandline, and enhance detach-interface to take a --address option,
eliminating the need to use detach-device
* src/conf/domain_conf.c
* src/conf/domain_conf.h
* src/libvirt_private.syms
* added new virDomainNetFindIdx function
* removed now unused virDomainNetIndexByMac and
virDomainNetRemoveByMac
* src/qemu/qemu_driver.c
* remove check for duplicate max from qemuDomainAttachDeviceConfig
* use virDomainNetFindIdx/virDomainNetRemove instead
of virDomainNetRemoveByMac in qemuDomainDetachDeviceConfig
* use virDomainNetFindIdx instead of virDomainIndexByMac
in qemuDomainUpdateDeviceConfig
* src/qemu/qemu_hotplug.c
* use virDomainNetFindIdx instead of a homespun loop in
qemuDomainDetachNetDevice.
* tools/virsh-domain.c: modified detach-interface command as described
above
2012-10-25 20:03:35 +00:00
|
|
|
virDomainNetFindIdx;
|
2011-07-26 12:42:37 +00:00
|
|
|
virDomainNetGetActualBandwidth;
|
2011-06-26 08:09:00 +00:00
|
|
|
virDomainNetGetActualBridgeName;
|
|
|
|
virDomainNetGetActualDirectDev;
|
|
|
|
virDomainNetGetActualDirectMode;
|
2012-02-15 17:37:15 +00:00
|
|
|
virDomainNetGetActualHostdev;
|
2012-01-02 21:35:12 +00:00
|
|
|
virDomainNetGetActualType;
|
2012-02-15 19:19:32 +00:00
|
|
|
virDomainNetGetActualVirtPortProfile;
|
2012-08-12 07:51:30 +00:00
|
|
|
virDomainNetGetActualVlan;
|
2011-05-27 07:01:47 +00:00
|
|
|
virDomainNetInsert;
|
2012-02-27 17:13:41 +00:00
|
|
|
virDomainNetRemove;
|
2009-07-17 21:08:34 +00:00
|
|
|
virDomainNetTypeToString;
|
2011-09-15 13:07:51 +00:00
|
|
|
virDomainNostateReasonTypeFromString;
|
|
|
|
virDomainNostateReasonTypeToString;
|
2011-06-20 07:15:44 +00:00
|
|
|
virDomainNumatuneMemModeTypeFromString;
|
|
|
|
virDomainNumatuneMemModeTypeToString;
|
numad: Set memory policy from numad advisory nodeset
Though numad will manage the memory allocation of task dynamically,
it wants management application (libvirt) to pre-set the memory
policy according to the advisory nodeset returned from querying numad,
(just like pre-bind CPU nodeset for domain process), and thus the
performance could benefit much more from it.
This patch introduces new XML tag 'placement', value 'auto' indicates
whether to set the memory policy with the advisory nodeset from numad,
and its value defaults to the value of <vcpu> placement, or 'static'
if 'nodeset' is specified. Example of the new XML tag's usage:
<numatune>
<memory placement='auto' mode='interleave'/>
</numatune>
Just like what current "numatune" does, the 'auto' numa memory policy
setting uses libnuma's API too.
If <vcpu> "placement" is "auto", and <numatune> is not specified
explicitly, a default <numatume> will be added with "placement"
set as "auto", and "mode" set as "strict".
The following XML can now fully drive numad:
1) <vcpu> placement is 'auto', no <numatune> is specified.
<vcpu placement='auto'>10</vcpu>
2) <vcpu> placement is 'auto', no 'placement' is specified for
<numatune>.
<vcpu placement='auto'>10</vcpu>
<numatune>
<memory mode='interleave'/>
</numatune>
And it's also able to control the CPU placement and memory policy
independently. e.g.
1) <vcpu> placement is 'auto', and <numatune> placement is 'static'
<vcpu placement='auto'>10</vcpu>
<numatune>
<memory mode='strict' nodeset='0-10,^7'/>
</numatune>
2) <vcpu> placement is 'static', and <numatune> placement is 'auto'
<vcpu placement='static' cpuset='0-24,^12'>10</vcpu>
<numatune>
<memory mode='interleave' placement='auto'/>
</numatume>
A follow up patch will change the XML formatting codes to always output
'placement' for <vcpu>, even it's 'static'.
2012-05-08 16:04:34 +00:00
|
|
|
virDomainNumatuneMemPlacementModeTypeFromString;
|
|
|
|
virDomainNumatuneMemPlacementModeTypeToString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainObjAssignDef;
|
2011-04-22 03:07:56 +00:00
|
|
|
virDomainObjCopyPersistentDef;
|
2010-11-19 19:51:46 +00:00
|
|
|
virDomainObjGetPersistentDef;
|
2011-05-04 09:07:01 +00:00
|
|
|
virDomainObjGetState;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainObjIsDuplicate;
|
|
|
|
virDomainObjListDeinit;
|
|
|
|
virDomainObjListGetActiveIDs;
|
|
|
|
virDomainObjListGetInactiveNames;
|
|
|
|
virDomainObjListInit;
|
|
|
|
virDomainObjListNumOfDomains;
|
|
|
|
virDomainObjLock;
|
2012-07-11 13:35:46 +00:00
|
|
|
virDomainObjNew;
|
2011-04-22 03:07:56 +00:00
|
|
|
virDomainObjSetDefTransient;
|
2011-05-04 09:07:01 +00:00
|
|
|
virDomainObjSetState;
|
2011-05-04 10:40:59 +00:00
|
|
|
virDomainObjTaint;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainObjUnlock;
|
2011-09-15 13:07:51 +00:00
|
|
|
virDomainPausedReasonTypeFromString;
|
|
|
|
virDomainPausedReasonTypeToString;
|
2011-09-20 17:31:52 +00:00
|
|
|
virDomainPciRombarModeTypeFromString;
|
|
|
|
virDomainPciRombarModeTypeToString;
|
2012-08-02 10:12:50 +00:00
|
|
|
virDomainPMStateTypeFromString;
|
|
|
|
virDomainPMStateTypeToString;
|
2011-09-02 15:09:14 +00:00
|
|
|
virDomainRedirdevBusTypeFromString;
|
|
|
|
virDomainRedirdevBusTypeToString;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainRemoveInactive;
|
2011-09-15 13:07:51 +00:00
|
|
|
virDomainRunningReasonTypeFromString;
|
|
|
|
virDomainRunningReasonTypeToString;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainSaveConfig;
|
2009-06-12 11:38:50 +00:00
|
|
|
virDomainSaveStatus;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainSaveXML;
|
2012-04-02 15:45:01 +00:00
|
|
|
virDomainSeclabelTypeFromString;
|
|
|
|
virDomainSeclabelTypeToString;
|
2011-09-15 13:07:51 +00:00
|
|
|
virDomainShutdownReasonTypeFromString;
|
|
|
|
virDomainShutdownReasonTypeToString;
|
|
|
|
virDomainShutoffReasonTypeFromString;
|
|
|
|
virDomainShutoffReasonTypeToString;
|
2011-01-10 16:41:33 +00:00
|
|
|
virDomainSmartcardDefForeach;
|
|
|
|
virDomainSmartcardDefFree;
|
|
|
|
virDomainSmartcardTypeFromString;
|
|
|
|
virDomainSmartcardTypeToString;
|
2012-04-02 15:45:01 +00:00
|
|
|
virDomainSmbiosModeTypeFromString;
|
|
|
|
virDomainSmbiosModeTypeToString;
|
2011-08-18 23:33:36 +00:00
|
|
|
virDomainSnapshotAlignDisks;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainSnapshotAssignDef;
|
|
|
|
virDomainSnapshotDefFormat;
|
|
|
|
virDomainSnapshotDefFree;
|
|
|
|
virDomainSnapshotDefParseString;
|
snapshot: framework for more efficient relation traversal
No one was using virDomainSnapshotHasChildren, but that was an
O(n) function. Exposing and tracking a bit more metadata for each
snapshot will allow the same query to be made with an O(1) query
of the member field. For single snapshot operations (create,
delete), callers can be trusted to maintain the metadata themselves,
but for reloading, we can't compute parents as we go since there
is no guarantee that parents were parsed before children, so we also
provide a function to refresh the relationships, and which can
be used to detect if the user has ignored our warnings and been
directly modifying files in /var/lib/libvirt/qemu/snapshot. This
patch only adds metadata; later patches will actually use it.
This layout intentionally hardcodes the size of each snapshot struct,
by tracking sibling pointers, rather than having to deal with the
headache of yet more memory management by directly sticking a
dynamically sized child[] on each parent.
* src/conf/domain_conf.h (_virDomainSnapshotObj)
(_virDomainSnapshotObjList): Add members.
(virDomainSnapshotUpdateRelations, virDomainSnapshotDropParent):
New prototypes.
(virDomainSnapshotHasChildren): Delete.
* src/conf/domain_conf.c (virDomainSnapshotSetRelations)
(virDomainSnapshotUpdateRelations, virDomainSnapshotDropParent):
New functions.
(virDomainSnapshotHasChildren): Drop unused function.
* src/libvirt_private.syms (domain_conf): Update exports.
2011-10-07 18:41:50 +00:00
|
|
|
virDomainSnapshotDropParent;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainSnapshotFindByName;
|
snapshot: make virDomainSnapshotObjList opaque
We were failing to react to allocation failure when initializing
a snapshot object list. Changing things to store a pointer
instead of a complete object adds one more possible point of
allocation failure, but at the same time, will make it easier to
react to failure now, as well as making it easier for a future
patch to split all virDomainSnapshotPtr handling into a separate
file, as I continue to add even more snapshot code.
Luckily, there was only one client outside of domain_conf.c that
was actually peeking inside the object, and a new wrapper function
was easy.
* src/conf/domain_conf.h (_virDomainObj): Use a pointer.
(virDomainSnapshotObjListInit): Rename.
(virDomainSnapshotObjListFree, virDomainSnapshotForEach): New
declarations.
(_virDomainSnapshotObjList): Move definitions...
* src/conf/domain_conf.c: ...here.
(virDomainSnapshotObjListInit, virDomainSnapshotObjListDeinit):
Rename...
(virDomainSnapshotObjListNew, virDomainSnapshotObjListFree): ...to
these.
(virDomainSnapshotForEach): New function.
(virDomainObjDispose, virDomainListPopulate): Adjust callers.
* src/qemu/qemu_domain.c (qemuDomainSnapshotDiscard)
(qemuDomainSnapshotDiscardAllMetadata): Likewise.
* src/qemu/qemu_migration.c (qemuMigrationIsAllowed): Likewise.
* src/qemu/qemu_driver.c (qemuDomainSnapshotLoad)
(qemuDomainUndefineFlags, qemuDomainSnapshotCreateXML)
(qemuDomainSnapshotListNames, qemuDomainSnapshotNum)
(qemuDomainListAllSnapshots)
(qemuDomainSnapshotListChildrenNames)
(qemuDomainSnapshotNumChildren)
(qemuDomainSnapshotListAllChildren)
(qemuDomainSnapshotLookupByName, qemuDomainSnapshotGetParent)
(qemuDomainSnapshotGetXMLDesc, qemuDomainSnapshotIsCurrent)
(qemuDomainSnapshotHasMetadata, qemuDomainRevertToSnapshot)
(qemuDomainSnapshotDelete): Likewise.
* src/libvirt_private.syms (domain_conf.h): Export new function.
2012-08-14 06:22:39 +00:00
|
|
|
virDomainSnapshotForEach;
|
2011-08-13 17:56:15 +00:00
|
|
|
virDomainSnapshotForEachChild;
|
2011-08-12 13:05:50 +00:00
|
|
|
virDomainSnapshotForEachDescendant;
|
2012-08-13 22:59:57 +00:00
|
|
|
virDomainSnapshotLocationTypeFromString;
|
|
|
|
virDomainSnapshotLocationTypeToString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainSnapshotObjListGetNames;
|
|
|
|
virDomainSnapshotObjListNum;
|
|
|
|
virDomainSnapshotObjListRemove;
|
2011-08-19 00:14:40 +00:00
|
|
|
virDomainSnapshotStateTypeFromString;
|
|
|
|
virDomainSnapshotStateTypeToString;
|
snapshot: framework for more efficient relation traversal
No one was using virDomainSnapshotHasChildren, but that was an
O(n) function. Exposing and tracking a bit more metadata for each
snapshot will allow the same query to be made with an O(1) query
of the member field. For single snapshot operations (create,
delete), callers can be trusted to maintain the metadata themselves,
but for reloading, we can't compute parents as we go since there
is no guarantee that parents were parsed before children, so we also
provide a function to refresh the relationships, and which can
be used to detect if the user has ignored our warnings and been
directly modifying files in /var/lib/libvirt/qemu/snapshot. This
patch only adds metadata; later patches will actually use it.
This layout intentionally hardcodes the size of each snapshot struct,
by tracking sibling pointers, rather than having to deal with the
headache of yet more memory management by directly sticking a
dynamically sized child[] on each parent.
* src/conf/domain_conf.h (_virDomainSnapshotObj)
(_virDomainSnapshotObjList): Add members.
(virDomainSnapshotUpdateRelations, virDomainSnapshotDropParent):
New prototypes.
(virDomainSnapshotHasChildren): Delete.
* src/conf/domain_conf.c (virDomainSnapshotSetRelations)
(virDomainSnapshotUpdateRelations, virDomainSnapshotDropParent):
New functions.
(virDomainSnapshotHasChildren): Drop unused function.
* src/libvirt_private.syms (domain_conf): Update exports.
2011-10-07 18:41:50 +00:00
|
|
|
virDomainSnapshotUpdateRelations;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainSoundDefFree;
|
|
|
|
virDomainSoundModelTypeFromString;
|
|
|
|
virDomainSoundModelTypeToString;
|
2011-10-17 14:54:03 +00:00
|
|
|
virDomainStartupPolicyTypeFromString;
|
|
|
|
virDomainStartupPolicyTypeToString;
|
2011-05-04 09:07:01 +00:00
|
|
|
virDomainStateReasonFromString;
|
|
|
|
virDomainStateReasonToString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainStateTypeFromString;
|
|
|
|
virDomainStateTypeToString;
|
2011-05-04 10:40:59 +00:00
|
|
|
virDomainTaintTypeFromString;
|
|
|
|
virDomainTaintTypeToString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainTimerModeTypeFromString;
|
|
|
|
virDomainTimerModeTypeToString;
|
|
|
|
virDomainTimerNameTypeFromString;
|
|
|
|
virDomainTimerNameTypeToString;
|
|
|
|
virDomainTimerTickpolicyTypeFromString;
|
|
|
|
virDomainTimerTickpolicyTypeToString;
|
|
|
|
virDomainTimerTrackTypeFromString;
|
|
|
|
virDomainTimerTrackTypeToString;
|
2011-06-24 23:09:46 +00:00
|
|
|
virDomainVcpuPinAdd;
|
2012-09-14 07:46:58 +00:00
|
|
|
virDomainVcpuPinDefArrayFree;
|
2012-08-21 09:18:29 +00:00
|
|
|
virDomainVcpuPinDefCopy;
|
|
|
|
virDomainVcpuPinDefFree;
|
2011-06-24 23:09:46 +00:00
|
|
|
virDomainVcpuPinDel;
|
|
|
|
virDomainVcpuPinFindByVcpu;
|
|
|
|
virDomainVcpuPinIsDuplicate;
|
2009-07-06 13:54:44 +00:00
|
|
|
virDomainVideoDefFree;
|
|
|
|
virDomainVideoDefaultRAM;
|
|
|
|
virDomainVideoDefaultType;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainVideoTypeFromString;
|
|
|
|
virDomainVideoTypeToString;
|
2012-01-02 21:35:12 +00:00
|
|
|
virDomainVirtTypeToString;
|
2011-08-13 06:32:45 +00:00
|
|
|
virDomainVirtioEventIdxTypeFromString;
|
|
|
|
virDomainVirtioEventIdxTypeToString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainWatchdogActionTypeFromString;
|
|
|
|
virDomainWatchdogActionTypeToString;
|
|
|
|
virDomainWatchdogModelTypeFromString;
|
|
|
|
virDomainWatchdogModelTypeToString;
|
2010-03-30 11:44:22 +00:00
|
|
|
|
2009-01-05 14:05:29 +00:00
|
|
|
|
|
|
|
# domain_event.h
|
2012-07-13 09:05:17 +00:00
|
|
|
virDomainEventBalloonChangeNewFromDom;
|
|
|
|
virDomainEventBalloonChangeNewFromObj;
|
2011-07-22 05:57:42 +00:00
|
|
|
virDomainEventBlockJobNewFromObj;
|
|
|
|
virDomainEventBlockJobNewFromDom;
|
2011-05-29 12:21:53 +00:00
|
|
|
virDomainEventControlErrorNewFromDom;
|
|
|
|
virDomainEventControlErrorNewFromObj;
|
2011-10-18 14:15:42 +00:00
|
|
|
virDomainEventDiskChangeNewFromDom;
|
|
|
|
virDomainEventDiskChangeNewFromObj;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainEventFree;
|
|
|
|
virDomainEventGraphicsNewFromDom;
|
|
|
|
virDomainEventGraphicsNewFromObj;
|
|
|
|
virDomainEventIOErrorNewFromDom;
|
|
|
|
virDomainEventIOErrorNewFromObj;
|
|
|
|
virDomainEventIOErrorReasonNewFromDom;
|
|
|
|
virDomainEventIOErrorReasonNewFromObj;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainEventNew;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainEventNewFromDef;
|
2009-01-05 14:05:29 +00:00
|
|
|
virDomainEventNewFromDom;
|
|
|
|
virDomainEventNewFromObj;
|
2012-03-23 14:50:36 +00:00
|
|
|
virDomainEventPMSuspendNewFromDom;
|
|
|
|
virDomainEventPMSuspendNewFromObj;
|
2012-03-23 14:43:14 +00:00
|
|
|
virDomainEventPMWakeupNewFromDom;
|
|
|
|
virDomainEventPMWakeupNewFromObj;
|
2010-03-18 18:28:15 +00:00
|
|
|
virDomainEventRTCChangeNewFromDom;
|
|
|
|
virDomainEventRTCChangeNewFromObj;
|
2011-04-25 11:35:23 +00:00
|
|
|
virDomainEventRebootNew;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainEventRebootNewFromDom;
|
|
|
|
virDomainEventRebootNewFromObj;
|
2011-01-05 22:51:45 +00:00
|
|
|
virDomainEventStateDeregister;
|
Return count of callbacks when registering callbacks
When registering a callback for a particular event some callers
need to know how many callbacks already exist for that event.
While it is possible to ask for a count, this is not free from
race conditions when threaded. Thus the API for registering
callbacks should return the count of callbacks. Also rename
virDomainEventStateDeregisterAny to virDomainEventStateDeregisterID
* src/conf/domain_event.c, src/conf/domain_event.h,
src/libvirt_private.syms: Return count of callbacks when
registering callbacks
* src/libxl/libxl_driver.c, src/libxl/libxl_driver.c,
src/qemu/qemu_driver.c, src/remote/remote_driver.c,
src/remote/remote_driver.c, src/uml/uml_driver.c,
src/vbox/vbox_tmpl.c, src/xen/xen_driver.c: Update
for change in APIs
2011-12-13 23:38:54 +00:00
|
|
|
virDomainEventStateDeregisterID;
|
2011-12-13 23:38:54 +00:00
|
|
|
virDomainEventStateEventID;
|
|
|
|
virDomainEventStateRegister;
|
|
|
|
virDomainEventStateRegisterID;
|
2011-01-05 22:27:40 +00:00
|
|
|
virDomainEventStateFree;
|
|
|
|
virDomainEventStateNew;
|
2011-01-05 22:51:45 +00:00
|
|
|
virDomainEventStateQueue;
|
2012-10-12 19:13:39 +00:00
|
|
|
virDomainEventPMSuspendDiskNewFromDom;
|
|
|
|
virDomainEventPMSuspendDiskNewFromObj;
|
2012-03-23 13:44:50 +00:00
|
|
|
virDomainEventTrayChangeNewFromDom;
|
|
|
|
virDomainEventTrayChangeNewFromObj;
|
Add support for an explicit watchdog event
This introduces a new event type
VIR_DOMAIN_EVENT_ID_WATCHDOG
This event includes the action that is about to be taken
as a result of the watchdog triggering
typedef enum {
VIR_DOMAIN_EVENT_WATCHDOG_NONE = 0,
VIR_DOMAIN_EVENT_WATCHDOG_PAUSE,
VIR_DOMAIN_EVENT_WATCHDOG_RESET,
VIR_DOMAIN_EVENT_WATCHDOG_POWEROFF,
VIR_DOMAIN_EVENT_WATCHDOG_SHUTDOWN,
VIR_DOMAIN_EVENT_WATCHDOG_DEBUG,
} virDomainEventWatchdogAction;
Thus there is a new callback definition for this event type
typedef void (*virConnectDomainEventWatchdogCallback)(virConnectPtr conn,
virDomainPtr dom,
int action,
void *opaque);
* daemon/remote.c: Dispatch watchdog events to client
* examples/domain-events/events-c/event-test.c: Watch for
watchdog events
* include/libvirt/libvirt.h.in: Define new watchdg event ID
and callback signature
* src/conf/domain_event.c, src/conf/domain_event.h,
src/libvirt_private.syms: Extend API to handle watchdog events
* src/qemu/qemu_driver.c: Connect to the QEMU monitor event
for watchdogs and emit a libvirt watchdog event
* src/remote/remote_driver.c: Receive and dispatch watchdog
events to application
* src/remote/remote_protocol.x: Wire protocol definition for
watchdog events
* src/qemu/qemu_monitor.c, src/qemu/qemu_monitor.h,
src/qemu/qemu_monitor_json.c: Watch for WATCHDOG event
from QEMU monitor
2010-03-18 19:07:48 +00:00
|
|
|
virDomainEventWatchdogNewFromDom;
|
|
|
|
virDomainEventWatchdogNewFromObj;
|
2010-10-20 17:10:45 +00:00
|
|
|
|
2009-01-05 14:05:29 +00:00
|
|
|
|
2011-01-24 12:16:30 +00:00
|
|
|
# domain_lock.h
|
|
|
|
virDomainLockProcessStart;
|
|
|
|
virDomainLockProcessInquire;
|
|
|
|
virDomainLockProcessPause;
|
|
|
|
virDomainLockProcessResume;
|
|
|
|
virDomainLockDiskAttach;
|
|
|
|
virDomainLockDiskDetach;
|
|
|
|
virDomainLockLeaseAttach;
|
|
|
|
virDomainLockLeaseDetach;
|
|
|
|
|
|
|
|
|
2010-06-21 18:18:31 +00:00
|
|
|
# domain_nwfilter.h
|
|
|
|
virDomainConfNWFilterInstantiate;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDomainConfNWFilterRegister;
|
2010-06-21 18:18:31 +00:00
|
|
|
virDomainConfNWFilterTeardown;
|
|
|
|
virDomainConfVMNWFilterTeardown;
|
2009-01-05 14:05:29 +00:00
|
|
|
|
2010-10-12 11:23:18 +00:00
|
|
|
|
2009-11-03 22:11:01 +00:00
|
|
|
# ebtables.h
|
|
|
|
ebtablesAddForwardAllowIn;
|
|
|
|
ebtablesAddForwardPolicyReject;
|
2010-11-30 16:00:30 +00:00
|
|
|
ebtablesContextFree;
|
2009-11-03 22:11:01 +00:00
|
|
|
ebtablesContextNew;
|
|
|
|
ebtablesRemoveForwardAllowIn;
|
|
|
|
|
|
|
|
|
2011-02-24 17:58:04 +00:00
|
|
|
# event_poll.h
|
2012-04-02 15:45:01 +00:00
|
|
|
virEventPollAddHandle;
|
|
|
|
virEventPollAddTimeout;
|
2011-02-24 17:58:04 +00:00
|
|
|
virEventPollFromNativeEvents;
|
2012-04-02 15:45:01 +00:00
|
|
|
virEventPollInit;
|
|
|
|
virEventPollRemoveHandle;
|
|
|
|
virEventPollRemoveTimeout;
|
|
|
|
virEventPollRunOnce;
|
|
|
|
virEventPollToNativeEvents;
|
|
|
|
virEventPollUpdateHandle;
|
|
|
|
virEventPollUpdateTimeout;
|
2011-02-24 17:58:04 +00:00
|
|
|
|
|
|
|
|
2010-09-22 18:32:21 +00:00
|
|
|
# fdstream.h
|
|
|
|
virFDStreamOpen;
|
|
|
|
virFDStreamConnectUNIX;
|
|
|
|
virFDStreamOpenFile;
|
|
|
|
virFDStreamCreateFile;
|
|
|
|
|
|
|
|
|
2009-01-05 14:05:29 +00:00
|
|
|
# hash.h
|
|
|
|
virHashAddEntry;
|
|
|
|
virHashCreate;
|
2012-04-02 15:45:01 +00:00
|
|
|
virHashEqual;
|
2009-01-05 14:05:29 +00:00
|
|
|
virHashForEach;
|
|
|
|
virHashFree;
|
2011-11-18 16:58:17 +00:00
|
|
|
virHashGetItems;
|
2009-01-05 14:05:29 +00:00
|
|
|
virHashLookup;
|
2012-04-19 14:21:43 +00:00
|
|
|
virHashRemoveAll;
|
2009-01-05 14:05:29 +00:00
|
|
|
virHashRemoveEntry;
|
|
|
|
virHashRemoveSet;
|
|
|
|
virHashSearch;
|
|
|
|
virHashSize;
|
2011-02-22 15:11:59 +00:00
|
|
|
virHashSteal;
|
2011-04-15 19:17:11 +00:00
|
|
|
virHashTableSize;
|
2011-11-18 16:58:17 +00:00
|
|
|
virHashUpdateEntry;
|
2009-01-05 14:05:29 +00:00
|
|
|
|
|
|
|
|
2010-03-26 14:49:45 +00:00
|
|
|
# hooks.h
|
|
|
|
virHookCall;
|
|
|
|
virHookInitialize;
|
|
|
|
virHookPresent;
|
|
|
|
|
|
|
|
|
2009-07-15 17:34:04 +00:00
|
|
|
# interface_conf.h
|
2010-10-20 17:10:45 +00:00
|
|
|
virInterfaceAssignDef;
|
2009-07-15 17:34:04 +00:00
|
|
|
virInterfaceDefFormat;
|
2010-10-20 17:10:45 +00:00
|
|
|
virInterfaceDefFree;
|
2009-07-15 17:34:04 +00:00
|
|
|
virInterfaceDefParseFile;
|
2009-09-10 13:21:10 +00:00
|
|
|
virInterfaceDefParseNode;
|
2010-10-20 17:10:45 +00:00
|
|
|
virInterfaceDefParseString;
|
2009-09-10 13:21:10 +00:00
|
|
|
virInterfaceFindByMACString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virInterfaceFindByName;
|
2011-05-09 19:17:26 +00:00
|
|
|
virInterfaceObjListClone;
|
2010-10-20 17:10:45 +00:00
|
|
|
virInterfaceObjListFree;
|
2009-09-10 13:21:10 +00:00
|
|
|
virInterfaceObjLock;
|
|
|
|
virInterfaceObjUnlock;
|
2010-10-20 17:10:45 +00:00
|
|
|
virInterfaceRemove;
|
2009-09-10 13:21:10 +00:00
|
|
|
|
2009-07-15 17:34:04 +00:00
|
|
|
|
2009-01-05 14:05:29 +00:00
|
|
|
# iptables.h
|
|
|
|
iptablesAddForwardAllowCross;
|
|
|
|
iptablesAddForwardAllowIn;
|
|
|
|
iptablesAddForwardAllowOut;
|
|
|
|
iptablesAddForwardAllowRelatedIn;
|
|
|
|
iptablesAddForwardMasquerade;
|
|
|
|
iptablesAddForwardRejectIn;
|
|
|
|
iptablesAddForwardRejectOut;
|
2010-07-13 02:59:58 +00:00
|
|
|
iptablesAddOutputFixUdpChecksum;
|
2009-01-05 14:05:29 +00:00
|
|
|
iptablesAddTcpInput;
|
|
|
|
iptablesAddUdpInput;
|
|
|
|
iptablesContextFree;
|
|
|
|
iptablesContextNew;
|
|
|
|
iptablesRemoveForwardAllowCross;
|
|
|
|
iptablesRemoveForwardAllowIn;
|
|
|
|
iptablesRemoveForwardAllowOut;
|
|
|
|
iptablesRemoveForwardAllowRelatedIn;
|
|
|
|
iptablesRemoveForwardMasquerade;
|
|
|
|
iptablesRemoveForwardRejectIn;
|
|
|
|
iptablesRemoveForwardRejectOut;
|
2010-07-13 02:59:58 +00:00
|
|
|
iptablesRemoveOutputFixUdpChecksum;
|
2009-01-05 14:05:29 +00:00
|
|
|
iptablesRemoveTcpInput;
|
|
|
|
iptablesRemoveUdpInput;
|
|
|
|
|
|
|
|
|
2009-11-03 18:59:18 +00:00
|
|
|
# json.h
|
2010-10-20 17:10:45 +00:00
|
|
|
virJSONValueArrayAppend;
|
|
|
|
virJSONValueArrayGet;
|
|
|
|
virJSONValueArraySize;
|
2009-11-03 18:59:18 +00:00
|
|
|
virJSONValueFree;
|
2010-10-20 17:10:45 +00:00
|
|
|
virJSONValueFromString;
|
|
|
|
virJSONValueGetBoolean;
|
|
|
|
virJSONValueGetNumberDouble;
|
|
|
|
virJSONValueGetNumberInt;
|
|
|
|
virJSONValueGetNumberLong;
|
|
|
|
virJSONValueGetNumberUint;
|
|
|
|
virJSONValueGetNumberUlong;
|
|
|
|
virJSONValueGetString;
|
|
|
|
virJSONValueIsNull;
|
|
|
|
virJSONValueNewArray;
|
|
|
|
virJSONValueNewBoolean;
|
|
|
|
virJSONValueNewNull;
|
|
|
|
virJSONValueNewNumberDouble;
|
2009-11-03 18:59:18 +00:00
|
|
|
virJSONValueNewNumberInt;
|
|
|
|
virJSONValueNewNumberLong;
|
2010-10-20 17:10:45 +00:00
|
|
|
virJSONValueNewNumberUint;
|
2009-11-03 18:59:18 +00:00
|
|
|
virJSONValueNewNumberUlong;
|
|
|
|
virJSONValueNewObject;
|
2010-10-20 17:10:45 +00:00
|
|
|
virJSONValueNewString;
|
|
|
|
virJSONValueNewStringLen;
|
2009-11-03 18:59:18 +00:00
|
|
|
virJSONValueObjectAppend;
|
2010-10-20 17:10:45 +00:00
|
|
|
virJSONValueObjectAppendBoolean;
|
|
|
|
virJSONValueObjectAppendNull;
|
|
|
|
virJSONValueObjectAppendNumberDouble;
|
2009-11-03 18:59:18 +00:00
|
|
|
virJSONValueObjectAppendNumberInt;
|
|
|
|
virJSONValueObjectAppendNumberLong;
|
2010-10-20 17:10:45 +00:00
|
|
|
virJSONValueObjectAppendNumberUint;
|
2009-11-03 18:59:18 +00:00
|
|
|
virJSONValueObjectAppendNumberUlong;
|
2010-10-20 17:10:45 +00:00
|
|
|
virJSONValueObjectAppendString;
|
2009-11-03 18:59:18 +00:00
|
|
|
virJSONValueObjectGet;
|
2010-10-20 17:10:45 +00:00
|
|
|
virJSONValueObjectGetBoolean;
|
2012-05-02 18:32:37 +00:00
|
|
|
virJSONValueObjectGetKey;
|
2010-10-20 17:10:45 +00:00
|
|
|
virJSONValueObjectGetNumberDouble;
|
2009-11-03 18:59:18 +00:00
|
|
|
virJSONValueObjectGetNumberInt;
|
|
|
|
virJSONValueObjectGetNumberLong;
|
2010-10-20 17:10:45 +00:00
|
|
|
virJSONValueObjectGetNumberUint;
|
2009-11-03 18:59:18 +00:00
|
|
|
virJSONValueObjectGetNumberUlong;
|
2010-10-20 17:10:45 +00:00
|
|
|
virJSONValueObjectGetString;
|
2012-05-02 18:32:37 +00:00
|
|
|
virJSONValueObjectGetValue;
|
2010-10-20 17:10:45 +00:00
|
|
|
virJSONValueObjectHasKey;
|
2009-11-03 18:59:18 +00:00
|
|
|
virJSONValueObjectIsNull;
|
2012-05-02 18:32:37 +00:00
|
|
|
virJSONValueObjectKeysNumber;
|
2009-11-03 18:59:18 +00:00
|
|
|
virJSONValueToString;
|
|
|
|
|
|
|
|
|
2010-10-20 17:10:45 +00:00
|
|
|
# libvirt_internal.h
|
|
|
|
virDomainMigrateFinish2;
|
|
|
|
virDomainMigrateFinish;
|
|
|
|
virDomainMigratePerform;
|
|
|
|
virDomainMigratePrepare2;
|
|
|
|
virDomainMigratePrepare;
|
|
|
|
virDomainMigratePrepareTunnel;
|
Introduce yet another migration version in API.
Migration just seems to go from bad to worse. We already had to
introduce a second migration protocol when adding the QEMU driver,
since the one from Xen was insufficiently flexible to cope with
passing the data the QEMU driver required.
It turns out that this protocol still has some flaws that we
need to address. The current sequence is
* Src: DumpXML
- Generate XML to pass to dst
* Dst: Prepare
- Get ready to accept incoming VM
- Generate optional cookie to pass to src
* Src: Perform
- Start migration and wait for send completion
- Kill off VM if successful, resume if failed
* Dst: Finish
- Wait for recv completion and check status
- Kill off VM if unsuccessful
The problems with this are:
- Since the first step is a generic 'DumpXML' call, we can't
add in other migration specific data. eg, we can't include
any VM lease data from lock manager plugins
- Since the first step is a generic 'DumpXML' call, we can't
emit any 'migration begin' event on the source, or have
any hook that runs right at the start of the process
- Since there is no final step on the source, if the Finish
method fails to receive all migration data & has to kill
the VM, then there's no way to resume the original VM
on the source
This patch attempts to introduce a version 3 that uses the
improved 5 step sequence
* Src: Begin
- Generate XML to pass to dst
- Generate optional cookie to pass to dst
* Dst: Prepare
- Get ready to accept incoming VM
- Generate optional cookie to pass to src
* Src: Perform
- Start migration and wait for send completion
- Generate optional cookie to pass to dst
* Dst: Finish
- Wait for recv completion and check status
- Kill off VM if failed, resume if success
- Generate optional cookie to pass to src
* Src: Confirm
- Kill off VM if success, resume if failed
The API is designed to allow both input and output cookies
in all methods where applicable. This lets us pass around
arbitrary extra driver specific data between src & dst during
migration. Combined with the extra 'Begin' method this lets
us pass lease information from source to dst at the start of
migration
Moving the killing of the source VM out of Perform and
into Confirm, means we can now recover if the dst host
can't successfully Finish receiving migration data.
2010-11-02 12:43:44 +00:00
|
|
|
virDomainMigrateBegin3;
|
|
|
|
virDomainMigratePrepare3;
|
|
|
|
virDomainMigratePrepareTunnel3;
|
|
|
|
virDomainMigratePerform3;
|
|
|
|
virDomainMigrateFinish3;
|
|
|
|
virDomainMigrateConfirm3;
|
2010-10-20 17:10:45 +00:00
|
|
|
virDrvSupportsFeature;
|
|
|
|
virRegisterDeviceMonitor;
|
|
|
|
virRegisterDriver;
|
|
|
|
virRegisterInterfaceDriver;
|
|
|
|
virRegisterNWFilterDriver;
|
|
|
|
virRegisterNetworkDriver;
|
|
|
|
virRegisterSecretDriver;
|
|
|
|
virRegisterStorageDriver;
|
|
|
|
|
|
|
|
|
2010-09-13 13:02:58 +00:00
|
|
|
# locking.h
|
|
|
|
virLockManagerAcquire;
|
|
|
|
virLockManagerAddResource;
|
|
|
|
virLockManagerFree;
|
|
|
|
virLockManagerInquire;
|
|
|
|
virLockManagerNew;
|
|
|
|
virLockManagerPluginNew;
|
|
|
|
virLockManagerPluginRef;
|
|
|
|
virLockManagerPluginUnref;
|
|
|
|
virLockManagerPluginUsesState;
|
|
|
|
virLockManagerPluginGetName;
|
|
|
|
virLockManagerRelease;
|
2012-08-21 13:21:47 +00:00
|
|
|
virLockManagerSetPluginDir;
|
2010-09-13 13:02:58 +00:00
|
|
|
|
|
|
|
|
2009-06-26 15:08:04 +00:00
|
|
|
# logging.h
|
2010-10-20 17:10:45 +00:00
|
|
|
virLogDefineFilter;
|
|
|
|
virLogDefineOutput;
|
2011-03-03 08:32:18 +00:00
|
|
|
virLogEmergencyDumpAll;
|
2010-10-20 17:10:45 +00:00
|
|
|
virLogGetDefaultPriority;
|
|
|
|
virLogGetFilters;
|
2009-08-06 13:45:50 +00:00
|
|
|
virLogGetNbFilters;
|
|
|
|
virLogGetNbOutputs;
|
2009-10-08 15:05:01 +00:00
|
|
|
virLogGetOutputs;
|
2010-10-20 17:10:45 +00:00
|
|
|
virLogLock;
|
|
|
|
virLogMessage;
|
2009-08-06 13:55:07 +00:00
|
|
|
virLogParseDefaultPriority;
|
2009-06-26 15:08:04 +00:00
|
|
|
virLogParseFilters;
|
|
|
|
virLogParseOutputs;
|
|
|
|
virLogReset;
|
2011-03-08 10:31:20 +00:00
|
|
|
virLogSetBufferSize;
|
2010-10-20 17:10:45 +00:00
|
|
|
virLogSetDefaultPriority;
|
|
|
|
virLogSetFromEnv;
|
2010-02-03 16:12:57 +00:00
|
|
|
virLogUnlock;
|
2009-06-26 15:08:04 +00:00
|
|
|
|
|
|
|
|
2009-01-05 14:05:29 +00:00
|
|
|
# memory.h
|
|
|
|
virAlloc;
|
|
|
|
virAllocN;
|
2011-01-18 18:37:45 +00:00
|
|
|
virAllocVar;
|
2010-08-13 21:00:47 +00:00
|
|
|
virExpandN;
|
2009-01-05 14:05:29 +00:00
|
|
|
virFree;
|
2010-10-20 17:10:45 +00:00
|
|
|
virReallocN;
|
2010-08-14 15:42:51 +00:00
|
|
|
virResizeN;
|
2010-08-13 21:00:47 +00:00
|
|
|
virShrinkN;
|
2009-01-05 14:05:29 +00:00
|
|
|
|
|
|
|
|
2011-11-18 16:07:48 +00:00
|
|
|
# netdev_bandwidth_conf.h
|
Adjust naming of network device bandwidth management APIs
Rename virBandwidth to virNetDevBandwidth, and virRate to
virNetDevBandwidthRate.
* src/util/network.c, src/util/network.h: Rename bandwidth
structs and APIs
* src/conf/domain_conf.c, src/conf/domain_conf.h,
src/conf/network_conf.c, src/conf/network_conf.h,
src/lxc/lxc_driver.c, src/network/bridge_driver.c,
src/qemu/qemu_command.c, src/util/macvtap.c,
src/util/macvtap.h, tools/virsh.c: Update for API changes.
2011-11-02 14:29:05 +00:00
|
|
|
virNetDevBandwidthFormat;
|
|
|
|
virNetDevBandwidthParse;
|
2011-11-18 16:07:48 +00:00
|
|
|
|
|
|
|
|
2012-08-12 07:51:30 +00:00
|
|
|
#netdev_vlan_conf.h
|
|
|
|
virNetDevVlanFormat;
|
|
|
|
virNetDevVlanParse;
|
|
|
|
|
|
|
|
|
2011-11-18 16:07:48 +00:00
|
|
|
# netdev_vportprofile_conf.h
|
2011-11-02 14:43:16 +00:00
|
|
|
virNetDevVPortProfileFormat;
|
|
|
|
virNetDevVPortProfileParse;
|
2012-03-06 01:12:44 +00:00
|
|
|
virNetDevVPortTypeFromString;
|
|
|
|
virNetDevVPortTypeToString;
|
2009-10-30 15:36:04 +00:00
|
|
|
|
|
|
|
|
2009-01-05 14:05:29 +00:00
|
|
|
# network_conf.h
|
|
|
|
virNetworkAssignDef;
|
2009-01-20 22:36:10 +00:00
|
|
|
virNetworkConfigFile;
|
2012-09-14 15:35:35 +00:00
|
|
|
virNetworkConfigChangeSetup;
|
|
|
|
virNetworkDefCopy;
|
2009-01-05 14:05:29 +00:00
|
|
|
virNetworkDefFormat;
|
|
|
|
virNetworkDefFree;
|
2010-11-17 18:36:19 +00:00
|
|
|
virNetworkDefGetIpByIndex;
|
2009-01-05 14:05:29 +00:00
|
|
|
virNetworkDefParseFile;
|
|
|
|
virNetworkDefParseNode;
|
|
|
|
virNetworkDefParseString;
|
|
|
|
virNetworkDeleteConfig;
|
|
|
|
virNetworkFindByName;
|
|
|
|
virNetworkFindByUUID;
|
2010-11-17 18:36:19 +00:00
|
|
|
virNetworkIpDefNetmask;
|
|
|
|
virNetworkIpDefPrefix;
|
2012-09-04 15:55:17 +00:00
|
|
|
virNetworkList;
|
2009-01-05 14:05:29 +00:00
|
|
|
virNetworkLoadAllConfigs;
|
2012-09-14 15:35:35 +00:00
|
|
|
virNetworkObjAssignDef;
|
|
|
|
virNetworkObjFree;
|
|
|
|
virNetworkObjGetPersistentDef;
|
2010-10-20 17:10:45 +00:00
|
|
|
virNetworkObjIsDuplicate;
|
2009-01-05 14:05:29 +00:00
|
|
|
virNetworkObjListFree;
|
2010-10-20 17:10:45 +00:00
|
|
|
virNetworkObjLock;
|
2012-09-14 15:35:35 +00:00
|
|
|
virNetworkObjReplacePersistentDef;
|
|
|
|
virNetworkObjSetDefTransient;
|
2010-10-20 17:10:45 +00:00
|
|
|
virNetworkObjUnlock;
|
network: free/null newDef if network fails to start
https://bugzilla.redhat.com/show_bug.cgi?id=866364
pointed out a crash due to virNetworkObjAssignDef free'ing
network->newDef without NULLing it afterward. A fix for this is in
upstream commit b7e9202401ebaa039b8f05acdefda8c24081537a. While the
NULLing of newDef was a legitimate fix, newDef should have already
been empty (NULL) anyway (as indicated in the comment that was deleted
by that commit).
The reason that newDef had a non-NULL value (i.e. the root cause) was
that networkStartNetwork() had failed after populating
network->newDef, but then neglected to free/NULL newDef in the
cleanup.
(A bit of background here: network->newDef should contain the
persistent config of a network when a network is active (and of course
only when it is persisten), and NULL at all other times. There is also
a network->def which should contain the persistent definition of the
network when it is inactive, and the current live state at all other
times. The idea is that you can make changes to network->newDef which
will take effect the next time the network is restarted, but won't
mess with the current state of the network (virDomainObj has a similar
pair of virDomainDefs that behave in the same fashion). Personally I
think there should be a network->live and network->config, and the
location of the persistent config should *always* be in
network->config, but that's for a later cleanup).
Since I love things to be symmetric, I created a new function called
virNetworkObjUnsetDefTransient(), which reverses the effects of
virNetworkObjSetDefTransient(). I don't really like the name of the
new function, but then I also didn't really like the name of the old
one either (it's just named that way to match a similar function in
the domain conf code).
2012-10-19 16:13:49 +00:00
|
|
|
virNetworkObjUnsetDefTransient;
|
2012-09-14 19:14:57 +00:00
|
|
|
virNetworkObjUpdate;
|
2009-01-05 14:05:29 +00:00
|
|
|
virNetworkRemoveInactive;
|
|
|
|
virNetworkSaveConfig;
|
2012-09-14 15:35:35 +00:00
|
|
|
virNetworkSaveStatus;
|
Give each virtual network bridge its own fixed MAC address
This fixes https://bugzilla.redhat.com/show_bug.cgi?id=609463
The problem was that, since a bridge always acquires the MAC address
of the connected interface with the numerically lowest MAC, as guests
are started and stopped, it was possible for the MAC address to change
over time, and this change in the network was being detected by
Windows 7 (it sees the MAC of the default route change), so on each
reboot it would bring up a dialog box asking about this "new network".
The solution is to create a dummy tap interface with a MAC guaranteed
to be lower than any guest interface's MAC, and attach that tap to the
bridge as soon as it's created. Since all guest MAC addresses start
with 0xFE, we can just generate a MAC with the standard "0x52, 0x54,
0" prefix, and it's guaranteed to always win (physical interfaces are
never connected to these bridges, so we don't need to worry about
competing numerically with them).
Note that the dummy tap is never set to IFF_UP state - that's not
necessary in order for the bridge to take its MAC, and not setting it
to UP eliminates the clutter of having an (eg) "virbr0-nic" displayed
in the output of the ifconfig command.
I chose to not auto-generate the MAC address in the network XML
parser, as there are likely to be consumers of that API that don't
need or want to have a MAC address associated with the
bridge.
Instead, in bridge_driver.c when the network is being defined, if
there is no MAC, one is generated. To account for virtual network
configs that already exist when upgrading from an older version of
libvirt, I've added a %post script to the specfile that searches for
all network definitions in both the config directory
(/etc/libvirt/qemu/networks) and the state directory
(/var/lib/libvirt/network) that are missing a mac address, generates a
random address, and adds it to the config (and a matching address to
the state file, if there is one).
docs/formatnetwork.html.in: document <mac address.../>
docs/schemas/network.rng: add nac address to schema
libvirt.spec.in: %post script to update existing networks
src/conf/network_conf.[ch]: parse and format <mac address.../>
src/libvirt_private.syms: export a couple private symbols we need
src/network/bridge_driver.c:
auto-generate mac address when needed,
create dummy interface if mac address is present.
tests/networkxml2xmlin/isolated-network.xml
tests/networkxml2xmlin/routed-network.xml
tests/networkxml2xmlout/isolated-network.xml
tests/networkxml2xmlout/routed-network.xml: add mac address to some tests
2011-02-09 08:28:12 +00:00
|
|
|
virNetworkSetBridgeMacAddr;
|
2009-03-02 17:37:03 +00:00
|
|
|
virNetworkSetBridgeName;
|
conf: support abstracted interface info in network XML
The network XML is updated in the following ways:
1) The <forward> element can now contain a list of forward interfaces:
<forward .... >
<interface dev='eth10'/>
<interface dev='eth11'/>
<interface dev='eth12'/>
<interface dev='eth13'/>
</forward>
The first of these takes the place of the dev attribute that is
normally in <forward> - when defining a network you can specify
either one, and on output both will be present. If you specify
both on input, they must match.
2) In addition to forward modes of 'nat' and 'route', these new modes
are supported:
private, passthrough, vepa - when this network is referenced by a
domain's interface, it will have the same effect as if the
interface had been defined as type='direct', e.g.:
<interface type='direct'>
<source mode='${mode}' dev='${dev}>
...
</interface>
where ${mode} is one of the three new modes, and ${dev} is an interface
selected from the list given in <forward>.
bridge - if a <forward> dev (or multiple devs) is defined, and
forward mode is 'bridge' this is just like the modes 'private',
'passthrough', and 'vepa' above. If there is no forward dev
specified but a bridge name is given (e.g. "<bridge
name='br0'/>"), then guest interfaces using this network will use
libvirt's "host bridge" mode, equivalent to this:
<interface type='bridge'>
<source bridge='${bridge-name}'/>
...
</interface>
3) A network can have multiple <portgroup> elements, which may be
selected by the guest interface definition (by adding
"portgroup='${name}'" in the <source> element along with the
network name). Currently a portgroup can only contain a
virtportprofile, but the intent is that other configuration items
may be put there int the future (e.g. bandwidth config). When
building a guest's interface, if the <interface> XML itself has no
virtportprofile, and if the requested network has a portgroup with
a name matching the name given in the <interface> (or if one of the
network's portgroups is marked with the "default='yes'" attribute),
the virtportprofile from that portgroup will be used by the
interface.
4) A network can have a virtportprofile defined at the top level,
which will be used by a guest interface when connecting in one of
the 'direct' modes if the guest interface XML itself hasn't
specified any virtportprofile, and if there are also no matching
portgroups on the network.
2011-07-20 03:01:09 +00:00
|
|
|
virPortGroupFindByName;
|
2009-01-05 14:05:29 +00:00
|
|
|
|
|
|
|
|
|
|
|
# node_device_conf.h
|
2012-09-17 03:32:53 +00:00
|
|
|
virNodeDevCapTypeFromString;
|
2009-01-05 14:05:29 +00:00
|
|
|
virNodeDevCapTypeToString;
|
|
|
|
virNodeDevCapsDefFree;
|
2010-10-20 17:10:45 +00:00
|
|
|
virNodeDeviceAssignDef;
|
2009-01-05 14:05:29 +00:00
|
|
|
virNodeDeviceDefFormat;
|
2010-10-20 17:10:45 +00:00
|
|
|
virNodeDeviceDefFree;
|
2010-10-12 11:23:18 +00:00
|
|
|
virNodeDeviceDefParseFile;
|
2010-10-20 17:10:45 +00:00
|
|
|
virNodeDeviceDefParseNode;
|
|
|
|
virNodeDeviceDefParseString;
|
|
|
|
virNodeDeviceFindByName;
|
|
|
|
virNodeDeviceFindBySysfsPath;
|
|
|
|
virNodeDeviceGetParentHost;
|
|
|
|
virNodeDeviceGetWWNs;
|
|
|
|
virNodeDeviceHasCap;
|
2012-09-05 05:34:09 +00:00
|
|
|
virNodeDeviceList;
|
2010-10-20 17:10:45 +00:00
|
|
|
virNodeDeviceObjListFree;
|
2009-01-05 14:05:29 +00:00
|
|
|
virNodeDeviceObjLock;
|
2010-10-20 17:10:45 +00:00
|
|
|
virNodeDeviceObjRemove;
|
2009-01-05 14:05:29 +00:00
|
|
|
virNodeDeviceObjUnlock;
|
2010-10-20 17:10:45 +00:00
|
|
|
|
|
|
|
|
|
|
|
# nodeinfo.h
|
|
|
|
nodeCapsInitNUMA;
|
2012-10-24 22:43:26 +00:00
|
|
|
nodeGetCPUBitmap;
|
2012-10-25 20:44:32 +00:00
|
|
|
nodeGetCPUCount;
|
2012-10-16 14:05:14 +00:00
|
|
|
nodeGetCPUMap;
|
2011-06-07 01:02:55 +00:00
|
|
|
nodeGetCPUStats;
|
2010-10-20 17:10:45 +00:00
|
|
|
nodeGetCellsFreeMemory;
|
|
|
|
nodeGetFreeMemory;
|
|
|
|
nodeGetInfo;
|
2012-09-14 14:42:16 +00:00
|
|
|
nodeGetMemoryParameters;
|
2011-06-07 01:11:17 +00:00
|
|
|
nodeGetMemoryStats;
|
2012-09-14 14:42:16 +00:00
|
|
|
nodeSetMemoryParameters;
|
2009-01-05 14:05:29 +00:00
|
|
|
|
|
|
|
|
2010-03-25 17:46:09 +00:00
|
|
|
# nwfilter_conf.h
|
2010-10-20 17:10:45 +00:00
|
|
|
virNWFilterCallbackDriversLock;
|
|
|
|
virNWFilterCallbackDriversUnlock;
|
|
|
|
virNWFilterChainSuffixTypeToString;
|
|
|
|
virNWFilterConfLayerInit;
|
|
|
|
virNWFilterConfLayerShutdown;
|
|
|
|
virNWFilterDefFormat;
|
|
|
|
virNWFilterDefFree;
|
|
|
|
virNWFilterDefParseString;
|
2012-01-27 13:19:58 +00:00
|
|
|
virNWFilterInstFiltersOnAllVMs;
|
2010-10-20 17:10:45 +00:00
|
|
|
virNWFilterJumpTargetTypeToString;
|
2011-01-15 15:06:52 +00:00
|
|
|
virNWFilterLoadAllConfigs;
|
2010-10-20 17:10:45 +00:00
|
|
|
virNWFilterLockFilterUpdates;
|
2011-01-15 15:06:52 +00:00
|
|
|
virNWFilterObjAssignDef;
|
|
|
|
virNWFilterObjDeleteDef;
|
|
|
|
virNWFilterObjFindByName;
|
|
|
|
virNWFilterObjFindByUUID;
|
|
|
|
virNWFilterObjListFree;
|
|
|
|
virNWFilterObjLock;
|
|
|
|
virNWFilterObjRemove;
|
|
|
|
virNWFilterObjSaveDef;
|
|
|
|
virNWFilterObjUnlock;
|
2010-10-20 17:10:45 +00:00
|
|
|
virNWFilterPrintStateMatchFlags;
|
2011-04-08 00:13:38 +00:00
|
|
|
virNWFilterPrintTCPFlags;
|
2010-10-20 17:10:45 +00:00
|
|
|
virNWFilterRegisterCallbackDriver;
|
2010-03-25 17:46:09 +00:00
|
|
|
virNWFilterRuleActionTypeToString;
|
2011-11-22 20:12:03 +00:00
|
|
|
virNWFilterRuleDirectionTypeToString;
|
2010-03-25 17:46:12 +00:00
|
|
|
virNWFilterRuleProtocolTypeToString;
|
2010-03-25 17:46:09 +00:00
|
|
|
virNWFilterTestUnassignDef;
|
nwfilter: fix crash during filter define when lxc driver failed startup
The meat of this patch is just moving the calls to
virNWFilterRegisterCallbackDriver from each hypervisor's "register"
function into its "initialize" function. The rest is just code
movement to allow that, and a new virNWFilterUnRegisterCallbackDriver
function to undo what the register function does.
The long explanation:
There is an array in nwfilter called callbackDrvArray that has
pointers to a table of functions for each hypervisor driver that are
called by nwfilter. One of those function pointers is to a function
that will lock the hypervisor driver. Entries are added to the table
by calling each driver's "register" function, which happens quite
early in libvirtd's startup.
Sometime later, each driver's "initialize" function is called. This
function allocates a driver object and stores a pointer to it in a
static variable that was previously initialized to NULL. (and here's
the important part...) If the "initialize" function fails, the driver
object is freed, and that pointer set back to NULL (but the entry in
nwfilter's callbackDrvArray is still there).
When the "lock the driver" function mentioned above is called, it
assumes that the driver was successfully loaded, so it blindly tries
to call virMutexLock on "driver->lock".
BUT, if the initialize never happened, or if it failed, "driver" is
NULL. And it just happens that "lock" is always the first field in
driver so it is also NULL.
Boom.
To fix this, the call to virNWFilterRegisterCallbackDriver for each
driver shouldn't be called until the end of its (*already guaranteed
successful*) "initialize" function, not during its "register" function
(which is currently the case). This implies that there should also be
a virNWFilterUnregisterCallbackDriver() function that is called in a
driver's "shutdown" function (although in practice, that function is
currently never called).
2012-08-09 06:18:23 +00:00
|
|
|
virNWFilterUnRegisterCallbackDriver;
|
nwfilter: Support for learning a VM's IP address
This patch implements support for learning a VM's IP address. It uses
the pcap library to listen on the VM's backend network interface (tap)
or the physical ethernet device (macvtap) and tries to capture packets
with source or destination MAC address of the VM and learn from DHCP
Offers, ARP traffic, or first-sent IPv4 packet what the IP address of
the VM's interface is. This then allows to instantiate the network
traffic filtering rules without the user having to provide the IP
parameter somewhere in the filter description or in the interface
description as a parameter. This only supports to detect the parameter
IP, which is for the assumed single IPv4 address of a VM. There is not
support for interfaces that may have multiple IP addresses (IP
aliasing) or IPv6 that may then require more than one valid IP address
to be detected. A VM can have multiple independent interfaces that each
uses a different IP address and in that case it will be attempted to
detect each one of the address independently.
So, when for example an interface description in the domain XML has
looked like this up to now:
<interface type='bridge'>
<source bridge='mybridge'/>
<model type='virtio'/>
<filterref filter='clean-traffic'>
<parameter name='IP' value='10.2.3.4'/>
</filterref>
</interface>
you may omit the IP parameter:
<interface type='bridge'>
<source bridge='mybridge'/>
<model type='virtio'/>
<filterref filter='clean-traffic'/>
</interface>
Internally I am walking the 'tree' of a VM's referenced network filters
and determine with the given variables which variables are missing. Now,
the above IP parameter may be missing and this causes a libvirt-internal
thread to be started that uses the pcap library's API to listen to the
backend interface (in case of macvtap to the physical interface) in an
attempt to determine the missing IP parameter. If the backend interface
disappears the thread terminates assuming the VM was brought down. In
case of a macvtap device a timeout is being used to wait for packets
from the given VM (filtering by VM's interface MAC address). If the VM's
macvtap device disappeared the thread also terminates. In all other
cases it tries to determine the IP address of the VM and will then apply
the rules late on the given interface, which would have happened
immediately if the IP parameter had been explicitly given. In case an
error happens while the firewall rules are applied, the VM's backend
interface is 'down'ed preventing it to communicate. Reasons for failure
for applying the network firewall rules may that an ebtables/iptables
command failes or OOM errors. Essentially the same failure reasons may
occur as when the firewall rules are applied immediately on VM start,
except that due to the late application of the filtering rules the VM
now is already running and cannot be hindered anymore from starting.
Bringing down the whole VM would probably be considered too drastic.
While a VM's IP address is attempted to be determined only limited
updates to network filters are allowed. In particular it is prevented
that filters are modified in such a way that they would introduce new
variables.
A caveat: The algorithm does not know which one is the appropriate IP
address of a VM. If the VM spoofs an IP address in its first ARP traffic
or IPv4 packets its filtering rules will be instantiated for this IP
address, thus 'locking' it to the found IP address. So, it's still
'safer' to explicitly provide the IP address of a VM's interface in the
filter description if it is known beforehand.
* configure.ac: detect libpcap
* libvirt.spec.in: require libpcap[-devel] if qemu is built
* src/internal.h: add the new ATTRIBUTE_PACKED define
* src/Makefile.am src/libvirt_private.syms: add the new modules and symbols
* src/nwfilter/nwfilter_learnipaddr.[ch]: new module being added
* src/nwfilter/nwfilter_driver.c src/conf/nwfilter_conf.[ch]
src/nwfilter/nwfilter_ebiptables_driver.[ch]
src/nwfilter/nwfilter_gentech_driver.[ch]: plu the new functionality in
* tests/nwfilterxml2xmltest: extend testing
2010-04-07 21:02:18 +00:00
|
|
|
virNWFilterUnlockFilterUpdates;
|
2010-03-25 17:46:09 +00:00
|
|
|
|
|
|
|
|
2012-06-01 23:32:06 +00:00
|
|
|
# nwfilter_ipaddrmap
|
|
|
|
virNWFilterIPAddrMapAddIPAddr;
|
|
|
|
virNWFilterIPAddrMapDelIPAddr;
|
|
|
|
virNWFilterIPAddrMapGetIPAddr;
|
|
|
|
virNWFilterIPAddrMapInit;
|
|
|
|
virNWFilterIPAddrMapShutdown;
|
|
|
|
|
|
|
|
|
2010-04-23 16:39:08 +00:00
|
|
|
# nwfilter_params.h
|
2010-03-25 17:46:09 +00:00
|
|
|
virNWFilterHashTableCreate;
|
|
|
|
virNWFilterHashTableFree;
|
|
|
|
virNWFilterHashTablePut;
|
|
|
|
virNWFilterHashTablePutAll;
|
|
|
|
virNWFilterHashTableRemoveEntry;
|
2012-01-11 11:42:37 +00:00
|
|
|
virNWFilterVarAccessGetVarName;
|
2012-01-11 11:42:37 +00:00
|
|
|
virNWFilterVarAccessIsAvailable;
|
|
|
|
virNWFilterVarAccessPrint;
|
2011-11-18 16:58:18 +00:00
|
|
|
virNWFilterVarCombIterCreate;
|
|
|
|
virNWFilterVarCombIterFree;
|
|
|
|
virNWFilterVarCombIterGetVarValue;
|
|
|
|
virNWFilterVarCombIterNext;
|
2011-11-23 00:05:45 +00:00
|
|
|
virNWFilterVarValueAddValue;
|
|
|
|
virNWFilterVarValueCopy;
|
2011-11-18 16:58:18 +00:00
|
|
|
virNWFilterVarValueCreateSimple;
|
|
|
|
virNWFilterVarValueCreateSimpleCopyValue;
|
2011-11-23 00:05:45 +00:00
|
|
|
virNWFilterVarValueDelValue;
|
|
|
|
virNWFilterVarValueFree;
|
|
|
|
virNWFilterVarValueGetCardinality;
|
|
|
|
virNWFilterVarValueGetNthValue;
|
2011-11-18 16:58:18 +00:00
|
|
|
virNWFilterVarValueGetSimple;
|
2010-03-25 17:46:09 +00:00
|
|
|
|
|
|
|
|
2009-03-02 16:18:11 +00:00
|
|
|
# pci.h
|
2012-03-06 01:12:23 +00:00
|
|
|
pciConfigAddressToSysfsFile;
|
2009-03-02 16:18:11 +00:00
|
|
|
pciDettachDevice;
|
2010-10-20 17:10:45 +00:00
|
|
|
pciDeviceFileIterate;
|
2009-08-17 14:05:23 +00:00
|
|
|
pciDeviceGetManaged;
|
qemu: Do not reattach PCI device used by other domain when shutdown
When failing on starting a domain, it tries to reattach all the PCI
devices defined in the domain conf, regardless of whether the devices
are still used by other domain. This will cause the devices to be deleted
from the list qemu_driver->activePciHostdevs, thus the devices will be
thought as usable even if it's not true. And following commands
nodedev-{reattach,reset} will be successful.
How to reproduce:
1) Define two domains with same PCI device defined in the confs.
2) # virsh start domain1
3) # virsh start domain2
4) # virsh nodedev-reattach $pci_device
You will see the device will be reattached to host successfully.
As pciDeviceReattach just check if the device is still used by
other domain via checking if the device is in list driver->activePciHostdevs,
however, the device is deleted from the list by step 2).
This patch is to prohibit the bug by:
1) Prohibit a domain starting or device attachment right at
preparation period (qemuPrepareHostdevPCIDevices) if the
device is in list driver->activePciHostdevs, which means
it's used by other domain.
2) Introduces a new field for struct _pciDevice, (const char *used_by),
it will be set as the domain name at preparation period,
(qemuPrepareHostdevPCIDevices). Thus we can prohibit deleting
the device from driver->activePciHostdevs if it's still used by
other domain when stopping the domain process.
* src/pci.h (define two internal functions, pciDeviceSetUsedBy and
pciDevceGetUsedBy)
* src/pci.c (new field "const char *used_by" for struct _pciDevice,
implementations for the two new functions)
* src/libvirt_private.syms (Add the two new internal functions)
* src/qemu_hostdev.h (Modify the definition of functions
qemuPrepareHostdevPCIDevices, and qemuDomainReAttachHostdevDevices)
* src/qemu_hostdev.c (Prohibit preparation and don't delete the
device from activePciHostdevs list if it's still used by other domain)
* src/qemu_hotplug.c (Update function usage, as the definitions are
changed)
Signed-off-by: Eric Blake <eblake@redhat.com>
2011-10-13 04:05:04 +00:00
|
|
|
pciDeviceGetName;
|
2011-10-20 09:50:10 +00:00
|
|
|
pciDeviceGetRemoveSlot;
|
|
|
|
pciDeviceGetReprobe;
|
|
|
|
pciDeviceGetUnbindFromStub;
|
qemu: Do not reattach PCI device used by other domain when shutdown
When failing on starting a domain, it tries to reattach all the PCI
devices defined in the domain conf, regardless of whether the devices
are still used by other domain. This will cause the devices to be deleted
from the list qemu_driver->activePciHostdevs, thus the devices will be
thought as usable even if it's not true. And following commands
nodedev-{reattach,reset} will be successful.
How to reproduce:
1) Define two domains with same PCI device defined in the confs.
2) # virsh start domain1
3) # virsh start domain2
4) # virsh nodedev-reattach $pci_device
You will see the device will be reattached to host successfully.
As pciDeviceReattach just check if the device is still used by
other domain via checking if the device is in list driver->activePciHostdevs,
however, the device is deleted from the list by step 2).
This patch is to prohibit the bug by:
1) Prohibit a domain starting or device attachment right at
preparation period (qemuPrepareHostdevPCIDevices) if the
device is in list driver->activePciHostdevs, which means
it's used by other domain.
2) Introduces a new field for struct _pciDevice, (const char *used_by),
it will be set as the domain name at preparation period,
(qemuPrepareHostdevPCIDevices). Thus we can prohibit deleting
the device from driver->activePciHostdevs if it's still used by
other domain when stopping the domain process.
* src/pci.h (define two internal functions, pciDeviceSetUsedBy and
pciDevceGetUsedBy)
* src/pci.c (new field "const char *used_by" for struct _pciDevice,
implementations for the two new functions)
* src/libvirt_private.syms (Add the two new internal functions)
* src/qemu_hostdev.h (Modify the definition of functions
qemuPrepareHostdevPCIDevices, and qemuDomainReAttachHostdevDevices)
* src/qemu_hostdev.c (Prohibit preparation and don't delete the
device from activePciHostdevs list if it's still used by other domain)
* src/qemu_hotplug.c (Update function usage, as the definitions are
changed)
Signed-off-by: Eric Blake <eblake@redhat.com>
2011-10-13 04:05:04 +00:00
|
|
|
pciDeviceGetUsedBy;
|
2012-03-06 01:12:23 +00:00
|
|
|
pciDeviceGetVirtualFunctionInfo;
|
2010-10-20 17:10:45 +00:00
|
|
|
pciDeviceIsAssignable;
|
2011-08-16 16:38:02 +00:00
|
|
|
pciDeviceIsVirtualFunction;
|
2009-08-17 14:05:23 +00:00
|
|
|
pciDeviceListAdd;
|
2009-10-27 17:30:16 +00:00
|
|
|
pciDeviceListCount;
|
2010-10-20 17:10:45 +00:00
|
|
|
pciDeviceListDel;
|
2011-10-18 02:46:38 +00:00
|
|
|
pciDeviceListFind;
|
2010-10-20 17:10:45 +00:00
|
|
|
pciDeviceListFree;
|
2009-10-27 17:30:16 +00:00
|
|
|
pciDeviceListGet;
|
2010-10-20 17:10:45 +00:00
|
|
|
pciDeviceListNew;
|
2009-10-27 17:30:16 +00:00
|
|
|
pciDeviceListSteal;
|
2011-08-16 16:38:02 +00:00
|
|
|
pciDeviceNetName;
|
2011-07-03 12:09:44 +00:00
|
|
|
pciDeviceReAttachInit;
|
2010-10-20 17:10:45 +00:00
|
|
|
pciDeviceSetManaged;
|
2011-10-20 09:50:10 +00:00
|
|
|
pciDeviceSetRemoveSlot;
|
|
|
|
pciDeviceSetReprobe;
|
|
|
|
pciDeviceSetUnbindFromStub;
|
qemu: Do not reattach PCI device used by other domain when shutdown
When failing on starting a domain, it tries to reattach all the PCI
devices defined in the domain conf, regardless of whether the devices
are still used by other domain. This will cause the devices to be deleted
from the list qemu_driver->activePciHostdevs, thus the devices will be
thought as usable even if it's not true. And following commands
nodedev-{reattach,reset} will be successful.
How to reproduce:
1) Define two domains with same PCI device defined in the confs.
2) # virsh start domain1
3) # virsh start domain2
4) # virsh nodedev-reattach $pci_device
You will see the device will be reattached to host successfully.
As pciDeviceReattach just check if the device is still used by
other domain via checking if the device is in list driver->activePciHostdevs,
however, the device is deleted from the list by step 2).
This patch is to prohibit the bug by:
1) Prohibit a domain starting or device attachment right at
preparation period (qemuPrepareHostdevPCIDevices) if the
device is in list driver->activePciHostdevs, which means
it's used by other domain.
2) Introduces a new field for struct _pciDevice, (const char *used_by),
it will be set as the domain name at preparation period,
(qemuPrepareHostdevPCIDevices). Thus we can prohibit deleting
the device from driver->activePciHostdevs if it's still used by
other domain when stopping the domain process.
* src/pci.h (define two internal functions, pciDeviceSetUsedBy and
pciDevceGetUsedBy)
* src/pci.c (new field "const char *used_by" for struct _pciDevice,
implementations for the two new functions)
* src/libvirt_private.syms (Add the two new internal functions)
* src/qemu_hostdev.h (Modify the definition of functions
qemuPrepareHostdevPCIDevices, and qemuDomainReAttachHostdevDevices)
* src/qemu_hostdev.c (Prohibit preparation and don't delete the
device from activePciHostdevs list if it's still used by other domain)
* src/qemu_hotplug.c (Update function usage, as the definitions are
changed)
Signed-off-by: Eric Blake <eblake@redhat.com>
2011-10-13 04:05:04 +00:00
|
|
|
pciDeviceSetUsedBy;
|
2010-10-20 17:10:45 +00:00
|
|
|
pciFreeDevice;
|
|
|
|
pciGetDevice;
|
2011-08-16 16:38:02 +00:00
|
|
|
pciGetPhysicalFunction;
|
|
|
|
pciGetVirtualFunctionIndex;
|
|
|
|
pciGetVirtualFunctions;
|
2010-10-20 17:10:45 +00:00
|
|
|
pciReAttachDevice;
|
|
|
|
pciResetDevice;
|
|
|
|
pciWaitForDeviceCleanup;
|
2009-08-14 13:20:40 +00:00
|
|
|
|
2009-03-02 16:18:11 +00:00
|
|
|
|
2009-11-16 15:22:34 +00:00
|
|
|
# processinfo.h
|
|
|
|
virProcessInfoGetAffinity;
|
2010-10-20 17:10:45 +00:00
|
|
|
virProcessInfoSetAffinity;
|
2009-11-16 15:22:34 +00:00
|
|
|
|
|
|
|
|
2009-09-01 15:27:46 +00:00
|
|
|
# secret_conf.h
|
2010-10-20 17:10:45 +00:00
|
|
|
virSecretDefFormat;
|
2009-09-01 15:27:46 +00:00
|
|
|
virSecretDefFree;
|
|
|
|
virSecretDefParseFile;
|
2010-10-20 17:10:45 +00:00
|
|
|
virSecretDefParseString;
|
2011-10-28 18:29:39 +00:00
|
|
|
virSecretUsageTypeTypeFromString;
|
|
|
|
virSecretUsageTypeTypeToString;
|
2009-01-05 14:05:29 +00:00
|
|
|
|
2009-08-14 19:48:55 +00:00
|
|
|
|
2012-08-02 12:10:31 +00:00
|
|
|
# security_driver.h
|
|
|
|
virSecurityDriverLookup;
|
|
|
|
|
|
|
|
|
|
|
|
# security_manager.h
|
|
|
|
virSecurityManagerClearSocketLabel;
|
|
|
|
virSecurityManagerFree;
|
|
|
|
virSecurityManagerGenLabel;
|
|
|
|
virSecurityManagerGetDOI;
|
|
|
|
virSecurityManagerGetModel;
|
2012-08-15 22:10:37 +00:00
|
|
|
virSecurityManagerGetNested;
|
2012-08-02 12:10:31 +00:00
|
|
|
virSecurityManagerGetProcessLabel;
|
|
|
|
virSecurityManagerNew;
|
|
|
|
virSecurityManagerNewStack;
|
|
|
|
virSecurityManagerNewDAC;
|
|
|
|
virSecurityManagerReleaseLabel;
|
|
|
|
virSecurityManagerReserveLabel;
|
|
|
|
virSecurityManagerRestoreImageLabel;
|
|
|
|
virSecurityManagerRestoreAllLabel;
|
|
|
|
virSecurityManagerRestoreHostdevLabel;
|
|
|
|
virSecurityManagerRestoreSavedStateLabel;
|
|
|
|
virSecurityManagerSetAllLabel;
|
|
|
|
virSecurityManagerSetDaemonSocketLabel;
|
|
|
|
virSecurityManagerSetImageFDLabel;
|
|
|
|
virSecurityManagerSetImageLabel;
|
|
|
|
virSecurityManagerSetHostdevLabel;
|
|
|
|
virSecurityManagerSetProcessLabel;
|
|
|
|
virSecurityManagerSetSavedStateLabel;
|
|
|
|
virSecurityManagerSetSocketLabel;
|
2012-10-15 09:03:49 +00:00
|
|
|
virSecurityManagerSetTapFDLabel;
|
2012-08-15 22:10:37 +00:00
|
|
|
virSecurityManagerStackAddNested;
|
2012-08-02 12:10:31 +00:00
|
|
|
virSecurityManagerVerify;
|
|
|
|
virSecurityManagerGetMountOptions;
|
|
|
|
|
2011-03-29 12:39:18 +00:00
|
|
|
# sexpr.h
|
|
|
|
sexpr_append;
|
|
|
|
sexpr_cons;
|
|
|
|
sexpr_float;
|
|
|
|
sexpr_fmt_node;
|
|
|
|
sexpr_free;
|
|
|
|
sexpr_has;
|
|
|
|
sexpr_int;
|
|
|
|
sexpr_lookup;
|
|
|
|
sexpr_nil;
|
|
|
|
sexpr_node;
|
|
|
|
sexpr_node_copy;
|
|
|
|
sexpr_string;
|
|
|
|
sexpr_u64;
|
|
|
|
sexpr2string;
|
|
|
|
string2sexpr;
|
2009-03-03 09:44:41 +00:00
|
|
|
|
2009-01-05 14:05:29 +00:00
|
|
|
# storage_conf.h
|
2010-10-20 17:10:45 +00:00
|
|
|
virStoragePartedFsTypeTypeToString;
|
2009-01-05 14:05:29 +00:00
|
|
|
virStoragePoolDefFormat;
|
|
|
|
virStoragePoolDefFree;
|
2009-06-22 16:41:34 +00:00
|
|
|
virStoragePoolDefParseFile;
|
|
|
|
virStoragePoolDefParseNode;
|
2010-10-20 17:10:45 +00:00
|
|
|
virStoragePoolDefParseSourceString;
|
|
|
|
virStoragePoolDefParseString;
|
|
|
|
virStoragePoolFormatDiskTypeToString;
|
|
|
|
virStoragePoolFormatFileSystemNetTypeToString;
|
|
|
|
virStoragePoolFormatFileSystemTypeToString;
|
2012-09-04 15:16:25 +00:00
|
|
|
virStoragePoolList;
|
2009-01-05 14:05:29 +00:00
|
|
|
virStoragePoolLoadAllConfigs;
|
|
|
|
virStoragePoolObjAssignDef;
|
|
|
|
virStoragePoolObjClearVols;
|
|
|
|
virStoragePoolObjDeleteDef;
|
|
|
|
virStoragePoolObjFindByName;
|
|
|
|
virStoragePoolObjFindByUUID;
|
2010-10-20 17:10:45 +00:00
|
|
|
virStoragePoolObjIsDuplicate;
|
2009-01-05 14:05:29 +00:00
|
|
|
virStoragePoolObjListFree;
|
2010-10-20 17:10:45 +00:00
|
|
|
virStoragePoolObjLock;
|
2009-01-05 14:05:29 +00:00
|
|
|
virStoragePoolObjRemove;
|
|
|
|
virStoragePoolObjSaveDef;
|
2010-10-20 17:10:45 +00:00
|
|
|
virStoragePoolObjUnlock;
|
2011-10-21 22:44:52 +00:00
|
|
|
virStoragePoolSourceClear;
|
|
|
|
virStoragePoolSourceFindDuplicate;
|
|
|
|
virStoragePoolSourceFindDuplicateDevices;
|
2009-01-05 14:05:29 +00:00
|
|
|
virStoragePoolSourceFree;
|
|
|
|
virStoragePoolSourceListFormat;
|
2010-10-20 17:10:45 +00:00
|
|
|
virStoragePoolSourceListNewSource;
|
|
|
|
virStoragePoolTypeFromString;
|
2009-01-05 14:05:29 +00:00
|
|
|
virStorageVolDefFindByKey;
|
|
|
|
virStorageVolDefFindByName;
|
|
|
|
virStorageVolDefFindByPath;
|
|
|
|
virStorageVolDefFormat;
|
|
|
|
virStorageVolDefFree;
|
2009-06-22 16:41:34 +00:00
|
|
|
virStorageVolDefParseFile;
|
|
|
|
virStorageVolDefParseNode;
|
2010-10-20 17:10:45 +00:00
|
|
|
virStorageVolDefParseString;
|
|
|
|
|
2009-01-05 14:05:29 +00:00
|
|
|
|
2009-09-08 11:33:35 +00:00
|
|
|
# storage_encryption_conf.h
|
2010-10-20 17:10:45 +00:00
|
|
|
virStorageEncryptionFormat;
|
2009-08-19 19:50:10 +00:00
|
|
|
virStorageEncryptionFree;
|
|
|
|
virStorageEncryptionParseNode;
|
2009-08-14 18:06:59 +00:00
|
|
|
virStorageGenerateQcowPassphrase;
|
2009-08-19 19:50:10 +00:00
|
|
|
|
2010-10-20 17:10:45 +00:00
|
|
|
|
2009-09-25 13:20:13 +00:00
|
|
|
# storage_file.h
|
2012-10-12 22:29:14 +00:00
|
|
|
virStorageFileChainLookup;
|
2009-09-25 13:20:13 +00:00
|
|
|
virStorageFileFormatTypeFromString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virStorageFileFormatTypeToString;
|
2011-07-14 10:53:45 +00:00
|
|
|
virStorageFileFreeMetadata;
|
2009-09-29 08:41:23 +00:00
|
|
|
virStorageFileGetMetadata;
|
2009-09-29 08:34:48 +00:00
|
|
|
virStorageFileGetMetadataFromFD;
|
2012-02-21 21:58:50 +00:00
|
|
|
virStorageFileIsClusterFS;
|
Don't reset user/group/security label on shared filesystems during migrate
When QEMU runs with its disk on NFS, and as a non-root user, the
disk is chownd to that non-root user. When migration completes
the last step is shutting down the QEMU on the source host. THis
normally resets user/group/security label. This is bad when the
VM was just migrated because the file is still in use on the dest
host. It is thus neccessary to skip the reset step for any files
found to be on a shared filesystem
* src/libvirt_private.syms: Export virStorageFileIsSharedFS
* src/util/storage_file.c, src/util/storage_file.h: Add a new
method virStorageFileIsSharedFS() to determine if a file is
on a shared filesystem (NFS, GFS, OCFS2, etc)
* src/qemu/qemu_driver.c: Tell security driver not to reset
disk labels on migration completion
* src/qemu/qemu_security_dac.c, src/qemu/qemu_security_stacked.c,
src/security/security_selinux.c, src/security/security_driver.h,
src/security/security_apparmor.c: Add ability to skip disk
restore step for files on shared filesystems.
2010-05-13 15:49:22 +00:00
|
|
|
virStorageFileIsSharedFS;
|
2010-10-29 11:20:40 +00:00
|
|
|
virStorageFileIsSharedFSType;
|
2010-10-20 17:10:45 +00:00
|
|
|
virStorageFileProbeFormat;
|
|
|
|
virStorageFileProbeFormatFromFD;
|
2012-02-01 21:11:58 +00:00
|
|
|
virStorageFileResize;
|
2009-01-05 14:05:29 +00:00
|
|
|
|
2010-11-05 14:22:13 +00:00
|
|
|
# sysinfo.h
|
|
|
|
virSysinfoDefFree;
|
2011-02-07 23:16:04 +00:00
|
|
|
virSysinfoFormat;
|
2010-11-05 14:22:13 +00:00
|
|
|
virSysinfoRead;
|
|
|
|
|
|
|
|
|
2010-12-08 06:19:06 +00:00
|
|
|
# threadpool.h
|
|
|
|
virThreadPoolFree;
|
|
|
|
virThreadPoolNew;
|
|
|
|
virThreadPoolSendJob;
|
2012-08-09 10:48:17 +00:00
|
|
|
virThreadPoolGetMinWorkers;
|
|
|
|
virThreadPoolGetMaxWorkers;
|
|
|
|
virThreadPoolGetPriorityWorkers;
|
2010-12-08 06:19:06 +00:00
|
|
|
|
|
|
|
|
2009-01-15 19:56:05 +00:00
|
|
|
# threads.h
|
2010-10-20 17:10:45 +00:00
|
|
|
virCondBroadcast;
|
|
|
|
virCondDestroy;
|
|
|
|
virCondInit;
|
|
|
|
virCondSignal;
|
|
|
|
virCondWait;
|
|
|
|
virCondWaitUntil;
|
|
|
|
virMutexDestroy;
|
2009-01-15 19:56:05 +00:00
|
|
|
virMutexInit;
|
2010-10-12 11:23:18 +00:00
|
|
|
virMutexInitRecursive;
|
2009-01-15 19:56:05 +00:00
|
|
|
virMutexLock;
|
|
|
|
virMutexUnlock;
|
2011-04-20 22:26:00 +00:00
|
|
|
virOnce;
|
2010-11-02 17:17:47 +00:00
|
|
|
virThreadCreate;
|
2010-12-04 21:33:23 +00:00
|
|
|
virThreadID;
|
2012-04-02 15:45:01 +00:00
|
|
|
virThreadInitialize;
|
2010-11-02 17:17:47 +00:00
|
|
|
virThreadIsSelf;
|
|
|
|
virThreadJoin;
|
|
|
|
virThreadSelf;
|
2010-11-18 13:03:56 +00:00
|
|
|
virThreadSelfID;
|
2009-01-15 19:56:05 +00:00
|
|
|
|
2010-10-20 17:10:45 +00:00
|
|
|
|
|
|
|
# usb.h
|
|
|
|
usbDeviceFileIterate;
|
|
|
|
usbDeviceGetBus;
|
|
|
|
usbDeviceGetDevno;
|
2011-12-21 17:58:29 +00:00
|
|
|
usbDeviceGetName;
|
|
|
|
usbDeviceGetUsedBy;
|
|
|
|
usbDeviceListAdd;
|
|
|
|
usbDeviceListCount;
|
|
|
|
usbDeviceListDel;
|
|
|
|
usbDeviceListFind;
|
|
|
|
usbDeviceListFree;
|
|
|
|
usbDeviceListGet;
|
|
|
|
usbDeviceListNew;
|
|
|
|
usbDeviceListSteal;
|
|
|
|
usbDeviceSetUsedBy;
|
2010-10-20 17:10:45 +00:00
|
|
|
usbFindDevice;
|
2012-05-04 07:49:58 +00:00
|
|
|
usbFindDeviceByBus;
|
|
|
|
usbFindDeviceByVendor;
|
2010-10-20 17:10:45 +00:00
|
|
|
usbFreeDevice;
|
|
|
|
usbGetDevice;
|
|
|
|
|
2009-01-15 19:56:05 +00:00
|
|
|
|
2009-01-05 14:05:29 +00:00
|
|
|
# util.h
|
|
|
|
saferead;
|
|
|
|
safewrite;
|
2009-03-20 12:17:56 +00:00
|
|
|
safezero;
|
2010-10-20 17:10:45 +00:00
|
|
|
virArgvToString;
|
|
|
|
virAsprintf;
|
|
|
|
virBuildPathInternal;
|
|
|
|
virDirCreate;
|
2012-08-11 19:13:00 +00:00
|
|
|
virDoubleToStr;
|
2009-01-05 14:05:29 +00:00
|
|
|
virEnumFromString;
|
|
|
|
virEnumToString;
|
2010-10-20 17:10:45 +00:00
|
|
|
virFileAbsPath;
|
2011-10-25 09:38:13 +00:00
|
|
|
virFileAccessibleAs;
|
2011-05-26 21:30:21 +00:00
|
|
|
virFileBuildPath;
|
2009-01-05 14:05:29 +00:00
|
|
|
virFileExists;
|
2010-10-20 17:10:45 +00:00
|
|
|
virFileFindMountPoint;
|
2009-01-05 14:05:29 +00:00
|
|
|
virFileHasSuffix;
|
2012-05-24 13:37:54 +00:00
|
|
|
virFileIsAbsPath;
|
2011-01-12 16:12:24 +00:00
|
|
|
virFileIsExecutable;
|
2011-08-16 19:36:22 +00:00
|
|
|
virFileIsLink;
|
2012-05-03 16:36:27 +00:00
|
|
|
virFileIsDir;
|
2009-01-05 14:05:29 +00:00
|
|
|
virFileLinkPointsTo;
|
2011-07-06 16:06:58 +00:00
|
|
|
virFileLock;
|
2009-01-05 14:05:29 +00:00
|
|
|
virFileMakePath;
|
2012-07-10 11:24:04 +00:00
|
|
|
virFileMakePathWithMode;
|
2010-10-20 17:10:45 +00:00
|
|
|
virFileMatchesNameSuffix;
|
2011-03-22 19:15:44 +00:00
|
|
|
virFileOpenAs;
|
2009-01-05 14:05:29 +00:00
|
|
|
virFileOpenTty;
|
2010-10-20 17:10:45 +00:00
|
|
|
virFileReadAll;
|
|
|
|
virFileReadLimFD;
|
2012-01-17 21:33:02 +00:00
|
|
|
virFileResolveAllLinks;
|
2010-10-20 17:10:45 +00:00
|
|
|
virFileResolveLink;
|
2010-05-20 15:41:31 +00:00
|
|
|
virFileSanitizePath;
|
2012-05-24 13:37:54 +00:00
|
|
|
virFileSkipRoot;
|
2010-10-20 17:10:45 +00:00
|
|
|
virFileStripSuffix;
|
2011-07-06 16:06:58 +00:00
|
|
|
virFileUnlock;
|
2010-10-20 17:10:45 +00:00
|
|
|
virFileWaitForDevices;
|
|
|
|
virFileWriteStr;
|
|
|
|
virFindFileInPath;
|
2012-09-25 17:31:01 +00:00
|
|
|
virFormatIntDecimal;
|
2010-10-20 17:10:45 +00:00
|
|
|
virGetGroupID;
|
2011-12-16 00:55:19 +00:00
|
|
|
virGetGroupName;
|
2010-10-20 17:10:45 +00:00
|
|
|
virGetHostname;
|
|
|
|
virGetUserDirectory;
|
2012-05-03 16:36:27 +00:00
|
|
|
virGetUserConfigDirectory;
|
|
|
|
virGetUserCacheDirectory;
|
|
|
|
virGetUserRuntimeDirectory;
|
2010-10-20 17:10:45 +00:00
|
|
|
virGetUserID;
|
|
|
|
virGetUserName;
|
|
|
|
virHexToBin;
|
|
|
|
virIndexToDiskName;
|
2011-02-17 07:29:07 +00:00
|
|
|
virIsDevMapperDevice;
|
2009-01-05 14:05:29 +00:00
|
|
|
virParseNumber;
|
2010-03-30 14:15:13 +00:00
|
|
|
virParseVersionString;
|
2010-03-26 10:50:10 +00:00
|
|
|
virPipeReadUntilEOF;
|
2012-03-05 16:28:59 +00:00
|
|
|
virScaleInteger;
|
2011-03-08 18:04:06 +00:00
|
|
|
virSetBlocking;
|
2010-10-20 17:10:45 +00:00
|
|
|
virSetCloseExec;
|
2011-03-26 11:19:28 +00:00
|
|
|
virSetInherit;
|
2010-10-20 17:10:45 +00:00
|
|
|
virSetNonBlock;
|
2010-12-23 06:44:02 +00:00
|
|
|
virSetUIDGID;
|
2009-01-05 14:05:29 +00:00
|
|
|
virSkipSpaces;
|
2011-06-29 17:30:43 +00:00
|
|
|
virSkipSpacesAndBackslash;
|
2011-06-29 17:47:08 +00:00
|
|
|
virSkipSpacesBackwards;
|
2010-10-20 17:10:45 +00:00
|
|
|
virStrToDouble;
|
|
|
|
virStrToLong_i;
|
2011-01-13 22:09:18 +00:00
|
|
|
virStrToLong_l;
|
2010-10-20 17:10:45 +00:00
|
|
|
virStrToLong_ll;
|
|
|
|
virStrToLong_ui;
|
2011-01-13 22:09:18 +00:00
|
|
|
virStrToLong_ul;
|
2010-10-20 17:10:45 +00:00
|
|
|
virStrToLong_ull;
|
2010-10-12 11:23:18 +00:00
|
|
|
virStrcpy;
|
|
|
|
virStrncpy;
|
2011-06-29 17:47:08 +00:00
|
|
|
virTrimSpaces;
|
2012-09-11 08:57:02 +00:00
|
|
|
virValidateWWN;
|
2010-11-22 23:39:47 +00:00
|
|
|
virVasprintf;
|
2009-01-05 14:05:29 +00:00
|
|
|
|
|
|
|
|
|
|
|
# uuid.h
|
2010-10-20 17:10:45 +00:00
|
|
|
virGetHostUUID;
|
|
|
|
virSetHostUUIDStr;
|
2009-01-05 14:05:29 +00:00
|
|
|
virUUIDFormat;
|
|
|
|
virUUIDGenerate;
|
2012-08-03 13:00:21 +00:00
|
|
|
virUUIDIsValid;
|
2009-01-05 14:05:29 +00:00
|
|
|
virUUIDParse;
|
2010-10-20 17:10:45 +00:00
|
|
|
|
2009-01-05 14:05:29 +00:00
|
|
|
|
2012-03-19 16:23:47 +00:00
|
|
|
# virauth.h
|
2012-03-20 15:40:05 +00:00
|
|
|
virAuthGetConfigFilePath;
|
2012-03-19 16:23:47 +00:00
|
|
|
virAuthGetPassword;
|
2012-03-20 15:40:05 +00:00
|
|
|
virAuthGetUsername;
|
|
|
|
|
|
|
|
|
|
|
|
# virauthconfig.h
|
|
|
|
virAuthConfigFree;
|
|
|
|
virAuthConfigLookup;
|
|
|
|
virAuthConfigNew;
|
|
|
|
virAuthConfigNewData;
|
2012-03-19 16:23:47 +00:00
|
|
|
|
|
|
|
|
2011-07-11 19:42:15 +00:00
|
|
|
# viraudit.h
|
2010-10-12 11:23:18 +00:00
|
|
|
virAuditClose;
|
2010-10-27 10:53:48 +00:00
|
|
|
virAuditEncode;
|
2010-10-12 11:23:18 +00:00
|
|
|
virAuditLog;
|
|
|
|
virAuditOpen;
|
|
|
|
virAuditSend;
|
|
|
|
|
2009-01-05 14:05:29 +00:00
|
|
|
|
2011-11-25 15:25:14 +00:00
|
|
|
# virconsole.h
|
|
|
|
virConsoleAlloc;
|
|
|
|
virConsoleFree;
|
|
|
|
virConsoleOpen;
|
|
|
|
|
|
|
|
|
2012-04-19 14:34:35 +00:00
|
|
|
# virdbus.h
|
|
|
|
virDBusGetSystemBus;
|
|
|
|
|
|
|
|
|
2012-06-05 12:00:52 +00:00
|
|
|
# virdomainlist.h
|
|
|
|
virDomainList;
|
2012-06-13 22:57:36 +00:00
|
|
|
virDomainListSnapshots;
|
2012-06-05 12:00:52 +00:00
|
|
|
|
|
|
|
|
2011-07-19 18:32:58 +00:00
|
|
|
# virfile.h
|
2012-07-03 14:06:27 +00:00
|
|
|
virFileLoopDeviceAssociate;
|
2011-07-19 18:32:58 +00:00
|
|
|
virFileClose;
|
2011-07-11 21:26:33 +00:00
|
|
|
virFileDirectFdFlag;
|
2012-02-08 14:03:01 +00:00
|
|
|
virFileWrapperFdClose;
|
|
|
|
virFileWrapperFdFree;
|
|
|
|
virFileWrapperFdNew;
|
2011-07-19 18:32:58 +00:00
|
|
|
virFileFclose;
|
|
|
|
virFileFdopen;
|
2011-10-13 10:17:12 +00:00
|
|
|
virFileRewrite;
|
2012-01-11 09:58:59 +00:00
|
|
|
virFileTouch;
|
2012-04-27 13:50:22 +00:00
|
|
|
virFileUpdatePerm;
|
2011-07-19 18:32:58 +00:00
|
|
|
|
|
|
|
|
2012-01-02 22:03:19 +00:00
|
|
|
# virkeycode.h
|
|
|
|
virKeycodeSetTypeFromString;
|
|
|
|
virKeycodeSetTypeToString;
|
|
|
|
virKeycodeValueFromString;
|
|
|
|
virKeycodeValueTranslate;
|
|
|
|
|
|
|
|
|
2012-03-16 16:29:49 +00:00
|
|
|
# virkeyfile.h
|
|
|
|
virKeyFileNew;
|
|
|
|
virKeyFileLoadFile;
|
|
|
|
virKeyFileLoadData;
|
|
|
|
virKeyFileFree;
|
|
|
|
virKeyFileHasValue;
|
|
|
|
virKeyFileHasGroup;
|
|
|
|
virKeyFileGetValueString;
|
|
|
|
|
|
|
|
|
Introduce an internal API for handling file based lockspaces
The previously introduced virFile{Lock,Unlock} APIs provide a
way to acquire/release fcntl() locks on individual files. For
unknown reason though, the POSIX spec says that fcntl() locks
are released when *any* file handle referring to the same path
is closed. In the following sequence
threadA: fd1 = open("foo")
threadB: fd2 = open("foo")
threadA: virFileLock(fd1)
threadB: virFileLock(fd2)
threadB: close(fd2)
you'd expect threadA to come out holding a lock on 'foo', and
indeed it does hold a lock for a very short time. Unfortunately
when threadB does close(fd2) this releases the lock associated
with fd1. For the current libvirt use case for virFileLock -
pidfiles - this doesn't matter since the lock is acquired
at startup while single threaded an never released until
exit.
To provide a more generally useful API though, it is necessary
to introduce a slightly higher level abstraction, which is to
be referred to as a "lockspace". This is to be provided by
a virLockSpacePtr object in src/util/virlockspace.{c,h}. The
core idea is that the lockspace keeps track of what files are
already open+locked. This means that when a 2nd thread comes
along and tries to acquire a lock, it doesn't end up opening
and closing a new FD. The lockspace just checks the current
list of held locks and immediately returns VIR_ERR_RESOURCE_BUSY.
NB, the API as it stands is designed on the basis that the
files being locked are not being otherwise opened and used
by the application code. One approach to using this API is to
acquire locks based on a hash of the filepath.
eg to lock /var/lib/libvirt/images/foo.img the application
might do
virLockSpacePtr lockspace = virLockSpaceNew("/var/lib/libvirt/imagelocks");
lockname = md5sum("/var/lib/libvirt/images/foo.img");
virLockSpaceAcquireLock(lockspace, lockname);
NB, in this example, the caller should ensure that the path
is canonicalized before calculating the checksum.
It is also possible to do locks directly on resources by
using a NULL lockspace directory and then using the file
path as the lock name eg
virLockSpacePtr lockspace = virLockSpaceNew(NULL);
virLockSpaceAcquireLock(lockspace, "/var/lib/libvirt/images/foo.img");
This is only safe to do though if no other part of the process
will be opening the files. This will be the case when this
code is used inside the soon-to-be-reposted virlockd daemon
Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
2012-08-02 16:02:40 +00:00
|
|
|
# virlockspace.h
|
|
|
|
virLockSpaceAcquireResource;
|
|
|
|
virLockSpaceCreateResource;
|
|
|
|
virLockSpaceDeleteResource;
|
|
|
|
virLockSpaceFree;
|
|
|
|
virLockSpaceGetDirectory;
|
|
|
|
virLockSpaceNew;
|
2012-08-09 10:54:37 +00:00
|
|
|
virLockSpaceNewPostExecRestart;
|
|
|
|
virLockSpacePreExecRestart;
|
Introduce an internal API for handling file based lockspaces
The previously introduced virFile{Lock,Unlock} APIs provide a
way to acquire/release fcntl() locks on individual files. For
unknown reason though, the POSIX spec says that fcntl() locks
are released when *any* file handle referring to the same path
is closed. In the following sequence
threadA: fd1 = open("foo")
threadB: fd2 = open("foo")
threadA: virFileLock(fd1)
threadB: virFileLock(fd2)
threadB: close(fd2)
you'd expect threadA to come out holding a lock on 'foo', and
indeed it does hold a lock for a very short time. Unfortunately
when threadB does close(fd2) this releases the lock associated
with fd1. For the current libvirt use case for virFileLock -
pidfiles - this doesn't matter since the lock is acquired
at startup while single threaded an never released until
exit.
To provide a more generally useful API though, it is necessary
to introduce a slightly higher level abstraction, which is to
be referred to as a "lockspace". This is to be provided by
a virLockSpacePtr object in src/util/virlockspace.{c,h}. The
core idea is that the lockspace keeps track of what files are
already open+locked. This means that when a 2nd thread comes
along and tries to acquire a lock, it doesn't end up opening
and closing a new FD. The lockspace just checks the current
list of held locks and immediately returns VIR_ERR_RESOURCE_BUSY.
NB, the API as it stands is designed on the basis that the
files being locked are not being otherwise opened and used
by the application code. One approach to using this API is to
acquire locks based on a hash of the filepath.
eg to lock /var/lib/libvirt/images/foo.img the application
might do
virLockSpacePtr lockspace = virLockSpaceNew("/var/lib/libvirt/imagelocks");
lockname = md5sum("/var/lib/libvirt/images/foo.img");
virLockSpaceAcquireLock(lockspace, lockname);
NB, in this example, the caller should ensure that the path
is canonicalized before calculating the checksum.
It is also possible to do locks directly on resources by
using a NULL lockspace directory and then using the file
path as the lock name eg
virLockSpacePtr lockspace = virLockSpaceNew(NULL);
virLockSpaceAcquireLock(lockspace, "/var/lib/libvirt/images/foo.img");
This is only safe to do though if no other part of the process
will be opening the files. This will be the case when this
code is used inside the soon-to-be-reposted virlockd daemon
Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
2012-08-02 16:02:40 +00:00
|
|
|
virLockSpaceReleaseResource;
|
|
|
|
virLockSpaceReleaseResourcesForOwner;
|
|
|
|
|
|
|
|
|
2012-01-27 17:23:05 +00:00
|
|
|
# virmacaddr.h
|
2012-07-17 12:07:59 +00:00
|
|
|
virMacAddrCmp;
|
|
|
|
virMacAddrCmpRaw;
|
2012-01-27 17:23:05 +00:00
|
|
|
virMacAddrCompare;
|
|
|
|
virMacAddrFormat;
|
|
|
|
virMacAddrGenerate;
|
2012-07-17 12:07:59 +00:00
|
|
|
virMacAddrGetRaw;
|
2012-08-30 18:29:49 +00:00
|
|
|
virMacAddrIsBroadcastRaw;
|
2012-03-19 16:49:17 +00:00
|
|
|
virMacAddrIsMulticast;
|
|
|
|
virMacAddrIsUnicast;
|
2012-01-27 17:23:05 +00:00
|
|
|
virMacAddrParse;
|
2012-07-17 12:07:59 +00:00
|
|
|
virMacAddrSet;
|
|
|
|
virMacAddrSetRaw;
|
2012-01-27 17:23:05 +00:00
|
|
|
|
|
|
|
|
2011-10-21 10:48:03 +00:00
|
|
|
# virnetclient.h
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetClientAddProgram;
|
|
|
|
virNetClientAddStream;
|
|
|
|
virNetClientClose;
|
|
|
|
virNetClientDupFD;
|
|
|
|
virNetClientGetFD;
|
|
|
|
virNetClientGetTLSKeySize;
|
2011-10-21 10:48:03 +00:00
|
|
|
virNetClientHasPassFD;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetClientIsEncrypted;
|
|
|
|
virNetClientIsOpen;
|
|
|
|
virNetClientKeepAliveIsSupported;
|
|
|
|
virNetClientKeepAliveStart;
|
|
|
|
virNetClientKeepAliveStop;
|
|
|
|
virNetClientLocalAddrString;
|
|
|
|
virNetClientNewExternal;
|
2011-11-14 15:12:53 +00:00
|
|
|
virNetClientNewLibSSH2;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetClientNewSSH;
|
|
|
|
virNetClientNewTCP;
|
|
|
|
virNetClientNewUNIX;
|
2012-08-07 11:09:51 +00:00
|
|
|
virNetClientRegisterAsyncIO;
|
|
|
|
virNetClientRegisterKeepAlive;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetClientRemoteAddrString;
|
|
|
|
virNetClientRemoveStream;
|
|
|
|
virNetClientSendNoReply;
|
|
|
|
virNetClientSendNonBlock;
|
|
|
|
virNetClientSendWithReply;
|
|
|
|
virNetClientSendWithReplyStream;
|
2012-07-18 16:10:22 +00:00
|
|
|
virNetClientSetCloseCallback;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetClientSetTLSSession;
|
|
|
|
|
|
|
|
|
|
|
|
# virnetclientprogram.h
|
|
|
|
virNetClientProgramCall;
|
|
|
|
virNetClientProgramDispatch;
|
|
|
|
virNetClientProgramGetProgram;
|
|
|
|
virNetClientProgramGetVersion;
|
|
|
|
virNetClientProgramMatches;
|
|
|
|
virNetClientProgramNew;
|
|
|
|
|
|
|
|
|
|
|
|
# virnetclientstream.h
|
|
|
|
virNetClientStreamEOF;
|
|
|
|
virNetClientStreamEventAddCallback;
|
|
|
|
virNetClientStreamEventRemoveCallback;
|
|
|
|
virNetClientStreamEventUpdateCallback;
|
|
|
|
virNetClientStreamMatches;
|
|
|
|
virNetClientStreamNew;
|
|
|
|
virNetClientStreamQueuePacket;
|
|
|
|
virNetClientStreamRaiseError;
|
|
|
|
virNetClientStreamRecvPacket;
|
|
|
|
virNetClientStreamSendPacket;
|
|
|
|
virNetClientStreamSetError;
|
2011-10-21 10:48:03 +00:00
|
|
|
|
2011-11-18 16:07:48 +00:00
|
|
|
|
2011-11-11 05:50:46 +00:00
|
|
|
# virnetdev.h
|
|
|
|
virNetDevClearIPv4Address;
|
|
|
|
virNetDevExists;
|
2011-11-18 16:07:48 +00:00
|
|
|
virNetDevGetIPv4Address;
|
2012-01-13 12:08:10 +00:00
|
|
|
virNetDevGetIndex;
|
2011-11-11 05:50:46 +00:00
|
|
|
virNetDevGetMAC;
|
|
|
|
virNetDevGetMTU;
|
2011-11-18 16:07:48 +00:00
|
|
|
virNetDevGetPhysicalFunction;
|
|
|
|
virNetDevGetVLanID;
|
2012-01-13 12:08:10 +00:00
|
|
|
virNetDevGetVirtualFunctionIndex;
|
2012-03-06 01:12:34 +00:00
|
|
|
virNetDevGetVirtualFunctionInfo;
|
2012-01-13 12:08:10 +00:00
|
|
|
virNetDevGetVirtualFunctions;
|
2011-11-11 05:50:46 +00:00
|
|
|
virNetDevIsOnline;
|
2011-11-18 16:07:48 +00:00
|
|
|
virNetDevIsVirtualFunction;
|
2012-03-06 01:12:34 +00:00
|
|
|
virNetDevLinkDump;
|
2011-11-18 16:07:48 +00:00
|
|
|
virNetDevReplaceMacAddress;
|
2012-03-06 01:12:34 +00:00
|
|
|
virNetDevReplaceNetConfig;
|
2011-11-18 16:07:48 +00:00
|
|
|
virNetDevRestoreMacAddress;
|
2012-03-06 01:12:34 +00:00
|
|
|
virNetDevRestoreNetConfig;
|
2011-11-11 05:50:46 +00:00
|
|
|
virNetDevSetIPv4Address;
|
|
|
|
virNetDevSetMAC;
|
|
|
|
virNetDevSetMTU;
|
|
|
|
virNetDevSetMTUFromDevice;
|
2011-11-16 02:59:57 +00:00
|
|
|
virNetDevSetName;
|
|
|
|
virNetDevSetNamespace;
|
2011-11-11 05:50:46 +00:00
|
|
|
virNetDevSetOnline;
|
2011-11-18 16:07:48 +00:00
|
|
|
virNetDevValidateConfig;
|
2011-11-11 05:50:46 +00:00
|
|
|
|
|
|
|
|
2011-11-16 02:59:57 +00:00
|
|
|
# virnetdevbandwidth.h
|
|
|
|
virNetDevBandwidthClear;
|
|
|
|
virNetDevBandwidthCopy;
|
|
|
|
virNetDevBandwidthEqual;
|
|
|
|
virNetDevBandwidthFree;
|
|
|
|
virNetDevBandwidthSet;
|
|
|
|
|
|
|
|
|
2011-11-11 05:50:46 +00:00
|
|
|
# virnetdevbridge.h
|
|
|
|
virNetDevBridgeAddPort;
|
|
|
|
virNetDevBridgeCreate;
|
|
|
|
virNetDevBridgeDelete;
|
|
|
|
virNetDevBridgeGetSTP;
|
|
|
|
virNetDevBridgeGetSTPDelay;
|
|
|
|
virNetDevBridgeRemovePort;
|
|
|
|
virNetDevBridgeSetSTP;
|
|
|
|
virNetDevBridgeSetSTPDelay;
|
|
|
|
|
|
|
|
|
2011-11-18 16:07:48 +00:00
|
|
|
# virnetdevmacvlan.h
|
|
|
|
virNetDevMacVLanCreate;
|
|
|
|
virNetDevMacVLanDelete;
|
|
|
|
virNetDevMacVLanCreateWithVPortProfile;
|
|
|
|
virNetDevMacVLanDeleteWithVPortProfile;
|
2012-03-29 12:55:04 +00:00
|
|
|
virNetDevMacVLanRestartWithVPortProfile;
|
2012-03-29 11:15:00 +00:00
|
|
|
virNetDevMacVLanVPortProfileRegisterCallback;
|
2011-11-18 16:07:48 +00:00
|
|
|
|
|
|
|
|
2012-02-10 21:09:00 +00:00
|
|
|
# virnetdevopenvswitch.h
|
|
|
|
virNetDevOpenvswitchAddPort;
|
2012-10-01 15:18:21 +00:00
|
|
|
virNetDevOpenvswitchGetMigrateData;
|
2012-02-10 21:09:00 +00:00
|
|
|
virNetDevOpenvswitchRemovePort;
|
2012-10-01 15:18:21 +00:00
|
|
|
virNetDevOpenvswitchSetMigrateData;
|
2012-02-10 21:09:00 +00:00
|
|
|
|
|
|
|
|
2011-11-11 05:50:46 +00:00
|
|
|
# virnetdevtap.h
|
|
|
|
virNetDevTapCreate;
|
|
|
|
virNetDevTapCreateInBridgePort;
|
|
|
|
virNetDevTapDelete;
|
|
|
|
|
2011-10-21 10:48:03 +00:00
|
|
|
|
2011-11-16 02:59:57 +00:00
|
|
|
# virnetdevveth.h
|
|
|
|
virNetDevVethCreate;
|
|
|
|
virNetDevVethDelete;
|
|
|
|
|
|
|
|
|
2012-08-11 17:44:27 +00:00
|
|
|
# virnetdevvlan.h
|
|
|
|
virNetDevVlanClear;
|
|
|
|
virNetDevVlanCopy;
|
|
|
|
virNetDevVlanEqual;
|
|
|
|
virNetDevVlanFree;
|
|
|
|
|
2011-11-16 02:59:57 +00:00
|
|
|
# virnetdevvportprofile.h
|
2011-11-18 16:07:48 +00:00
|
|
|
virNetDevVPortProfileAssociate;
|
2012-08-04 07:09:47 +00:00
|
|
|
virNetDevVPortProfileCheckComplete;
|
|
|
|
virNetDevVPortProfileCheckNoExtras;
|
2011-11-18 16:07:48 +00:00
|
|
|
virNetDevVPortProfileDisassociate;
|
2011-11-16 02:59:57 +00:00
|
|
|
virNetDevVPortProfileEqual;
|
2012-08-04 07:09:47 +00:00
|
|
|
virNetDevVPortProfileMerge3;
|
2011-11-18 16:07:48 +00:00
|
|
|
virNetDevVPortProfileOpTypeFromString;
|
|
|
|
virNetDevVPortProfileOpTypeToString;
|
2011-11-16 02:59:57 +00:00
|
|
|
|
|
|
|
|
2012-02-03 14:13:19 +00:00
|
|
|
#virnetlink.h
|
|
|
|
virNetlinkCommand;
|
2012-02-29 20:20:33 +00:00
|
|
|
virNetlinkEventAddClient;
|
|
|
|
virNetlinkEventRemoveClient;
|
2012-02-22 13:17:13 +00:00
|
|
|
virNetlinkEventServiceIsRunning;
|
2012-05-04 17:19:51 +00:00
|
|
|
virNetlinkEventServiceLocalPid;
|
2012-02-22 13:17:13 +00:00
|
|
|
virNetlinkEventServiceStop;
|
2012-08-22 04:10:24 +00:00
|
|
|
virNetlinkEventServiceStopAll;
|
2012-02-22 13:17:13 +00:00
|
|
|
virNetlinkEventServiceStart;
|
2012-05-03 14:39:04 +00:00
|
|
|
virNetlinkShutdown;
|
|
|
|
virNetlinkStartup;
|
2012-02-03 14:13:19 +00:00
|
|
|
|
|
|
|
|
2011-09-30 13:38:39 +00:00
|
|
|
# virnetmessage.h
|
|
|
|
virNetMessageClear;
|
2012-04-02 15:45:01 +00:00
|
|
|
virNetMessageDecodeHeader;
|
2011-10-21 10:30:12 +00:00
|
|
|
virNetMessageDecodeNumFDs;
|
2012-04-02 15:45:01 +00:00
|
|
|
virNetMessageDecodeLength;
|
|
|
|
virNetMessageDecodePayload;
|
2011-10-21 11:12:28 +00:00
|
|
|
virNetMessageDupFD;
|
2011-09-30 13:38:39 +00:00
|
|
|
virNetMessageEncodeHeader;
|
|
|
|
virNetMessageEncodePayload;
|
2012-04-02 15:45:01 +00:00
|
|
|
virNetMessageEncodePayloadRaw;
|
2011-10-21 10:30:12 +00:00
|
|
|
virNetMessageEncodeNumFDs;
|
2011-09-30 13:38:39 +00:00
|
|
|
virNetMessageFree;
|
|
|
|
virNetMessageNew;
|
|
|
|
virNetMessageQueuePush;
|
|
|
|
virNetMessageQueueServe;
|
|
|
|
virNetMessageSaveError;
|
2012-04-02 15:45:01 +00:00
|
|
|
xdr_virNetMessageError;
|
2011-09-30 13:38:39 +00:00
|
|
|
|
|
|
|
|
|
|
|
# virnetserver.h
|
|
|
|
virNetServerAddProgram;
|
|
|
|
virNetServerAddService;
|
|
|
|
virNetServerAddSignalHandler;
|
|
|
|
virNetServerAutoShutdown;
|
|
|
|
virNetServerClose;
|
|
|
|
virNetServerIsPrivileged;
|
2011-08-24 13:33:34 +00:00
|
|
|
virNetServerKeepAliveRequired;
|
2011-09-30 13:38:39 +00:00
|
|
|
virNetServerNew;
|
2012-08-09 11:54:54 +00:00
|
|
|
virNetServerNewPostExecRestart;
|
|
|
|
virNetServerPreExecRestart;
|
2011-09-30 13:38:39 +00:00
|
|
|
virNetServerQuit;
|
|
|
|
virNetServerRun;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetServerSetTLSContext;
|
2011-09-30 13:38:39 +00:00
|
|
|
virNetServerUpdateServices;
|
|
|
|
|
|
|
|
|
|
|
|
# virnetserverclient.h
|
|
|
|
virNetServerClientAddFilter;
|
|
|
|
virNetServerClientClose;
|
|
|
|
virNetServerClientDelayedClose;
|
|
|
|
virNetServerClientGetAuth;
|
|
|
|
virNetServerClientGetFD;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetServerClientGetIdentity;
|
2011-09-30 13:38:39 +00:00
|
|
|
virNetServerClientGetPrivateData;
|
|
|
|
virNetServerClientGetReadonly;
|
|
|
|
virNetServerClientGetTLSKeySize;
|
2012-01-18 17:41:36 +00:00
|
|
|
virNetServerClientGetUNIXIdentity;
|
2011-09-30 13:38:39 +00:00
|
|
|
virNetServerClientHasTLSSession;
|
|
|
|
virNetServerClientImmediateClose;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetServerClientInit;
|
|
|
|
virNetServerClientInitKeepAlive;
|
|
|
|
virNetServerClientIsClosed;
|
2011-09-30 13:38:39 +00:00
|
|
|
virNetServerClientIsSecure;
|
|
|
|
virNetServerClientLocalAddrString;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetServerClientNeedAuth;
|
|
|
|
virNetServerClientNew;
|
2012-08-09 11:54:54 +00:00
|
|
|
virNetServerClientNewPostExecRestart;
|
|
|
|
virNetServerClientPreExecRestart;
|
2011-09-30 13:38:39 +00:00
|
|
|
virNetServerClientRemoteAddrString;
|
|
|
|
virNetServerClientRemoveFilter;
|
|
|
|
virNetServerClientSendMessage;
|
|
|
|
virNetServerClientSetCloseHook;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetServerClientSetDispatcher;
|
2011-09-30 13:38:39 +00:00
|
|
|
virNetServerClientSetIdentity;
|
2011-08-24 13:33:34 +00:00
|
|
|
virNetServerClientStartKeepAlive;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetServerClientWantClose;
|
|
|
|
|
|
|
|
|
|
|
|
# virnetservermdns.h
|
|
|
|
virNetServerMDNSAddEntry;
|
|
|
|
virNetServerMDNSAddGroup;
|
|
|
|
virNetServerMDNSEntryFree;
|
|
|
|
virNetServerMDNSFree;
|
|
|
|
virNetServerMDNSGroupFree;
|
|
|
|
virNetServerMDNSNew;
|
|
|
|
virNetServerMDNSRemoveEntry;
|
|
|
|
virNetServerMDNSRemoveGroup;
|
|
|
|
virNetServerMDNSStart;
|
|
|
|
virNetServerMDNSStop;
|
2011-09-30 13:38:39 +00:00
|
|
|
|
|
|
|
|
|
|
|
# virnetserverprogram.h
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetServerProgramDispatch;
|
2011-09-30 13:38:39 +00:00
|
|
|
virNetServerProgramGetID;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetServerProgramGetPriority;
|
2011-09-30 13:38:39 +00:00
|
|
|
virNetServerProgramGetVersion;
|
|
|
|
virNetServerProgramMatches;
|
|
|
|
virNetServerProgramNew;
|
|
|
|
virNetServerProgramSendReplyError;
|
|
|
|
virNetServerProgramSendStreamData;
|
|
|
|
virNetServerProgramSendStreamError;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetServerProgramUnknownError;
|
|
|
|
|
|
|
|
|
|
|
|
# virnetserverservice.h
|
|
|
|
virNetServerServiceClose;
|
|
|
|
virNetServerServiceGetAuth;
|
2012-08-09 11:06:45 +00:00
|
|
|
virNetServerServiceGetMaxRequests;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetServerServiceGetPort;
|
2012-08-09 11:06:45 +00:00
|
|
|
virNetServerServiceGetTLSContext;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetServerServiceIsReadonly;
|
2012-08-09 14:09:19 +00:00
|
|
|
virNetServerServiceNewFD;
|
2012-08-09 11:54:54 +00:00
|
|
|
virNetServerServiceNewPostExecRestart;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetServerServiceNewTCP;
|
|
|
|
virNetServerServiceNewUNIX;
|
2012-08-09 11:54:54 +00:00
|
|
|
virNetServerServicePreExecRestart;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetServerServiceSetDispatcher;
|
|
|
|
virNetServerServiceToggle;
|
2011-09-30 13:38:39 +00:00
|
|
|
|
|
|
|
|
|
|
|
# virnetsocket.h
|
2012-04-02 15:45:01 +00:00
|
|
|
virNetSocketAccept;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetSocketAddIOCallback;
|
|
|
|
virNetSocketClose;
|
2011-09-30 13:38:39 +00:00
|
|
|
virNetSocketDupFD;
|
|
|
|
virNetSocketGetFD;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetSocketGetPort;
|
|
|
|
virNetSocketGetUNIXIdentity;
|
|
|
|
virNetSocketHasCachedData;
|
2011-10-21 10:13:21 +00:00
|
|
|
virNetSocketHasPassFD;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetSocketHasPendingData;
|
2011-10-21 10:13:21 +00:00
|
|
|
virNetSocketIsLocal;
|
2011-09-30 13:38:39 +00:00
|
|
|
virNetSocketListen;
|
2012-04-02 15:45:01 +00:00
|
|
|
virNetSocketLocalAddrString;
|
|
|
|
virNetSocketNewConnectCommand;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetSocketNewConnectExternal;
|
2011-11-14 14:50:02 +00:00
|
|
|
virNetSocketNewConnectLibSSH2;
|
2012-04-02 15:45:01 +00:00
|
|
|
virNetSocketNewConnectSSH;
|
2011-09-30 13:38:39 +00:00
|
|
|
virNetSocketNewConnectTCP;
|
2012-04-02 15:45:01 +00:00
|
|
|
virNetSocketNewConnectUNIX;
|
2012-08-09 14:09:19 +00:00
|
|
|
virNetSocketNewListenFD;
|
2012-04-02 15:45:01 +00:00
|
|
|
virNetSocketNewListenTCP;
|
2011-09-30 13:38:39 +00:00
|
|
|
virNetSocketNewListenUNIX;
|
2012-08-09 11:54:54 +00:00
|
|
|
virNetSocketNewPostExecRestart;
|
|
|
|
virNetSocketPreExecRestart;
|
2012-04-02 15:45:01 +00:00
|
|
|
virNetSocketRead;
|
2011-10-21 10:13:21 +00:00
|
|
|
virNetSocketRecvFD;
|
2012-04-02 15:45:01 +00:00
|
|
|
virNetSocketRemoteAddrString;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetSocketRemoveIOCallback;
|
2011-10-21 10:13:21 +00:00
|
|
|
virNetSocketSendFD;
|
2012-04-02 15:45:01 +00:00
|
|
|
virNetSocketSetBlocking;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetSocketSetTLSSession;
|
|
|
|
virNetSocketUpdateIOCallback;
|
2012-04-02 15:45:01 +00:00
|
|
|
virNetSocketWrite;
|
2011-09-30 13:38:39 +00:00
|
|
|
|
|
|
|
|
|
|
|
# virnettlscontext.h
|
2012-04-02 15:45:01 +00:00
|
|
|
virNetTLSContextCheckCertificate;
|
|
|
|
virNetTLSContextNewClient;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetTLSContextNewClientPath;
|
2011-09-30 13:38:39 +00:00
|
|
|
virNetTLSContextNewServer;
|
|
|
|
virNetTLSContextNewServerPath;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetTLSInit;
|
|
|
|
virNetTLSSessionGetHandshakeStatus;
|
|
|
|
virNetTLSSessionGetKeySize;
|
2012-04-02 15:45:01 +00:00
|
|
|
virNetTLSSessionHandshake;
|
|
|
|
virNetTLSSessionNew;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetTLSSessionRead;
|
2012-04-02 15:45:01 +00:00
|
|
|
virNetTLSSessionSetIOCallbacks;
|
2012-07-18 16:03:17 +00:00
|
|
|
virNetTLSSessionWrite;
|
2011-09-30 13:38:39 +00:00
|
|
|
|
|
|
|
|
Implement the core API to suspend/resume the host
Add the core functions that implement the functionality of the API.
Suspend is done by using an asynchronous mechanism so that we can return
the status to the caller before the host gets suspended. This asynchronous
operation is achieved by suspending the host in a separate thread of
execution. However, returning the status to the caller is only best-effort,
but not guaranteed.
To resume the host, an RTC alarm is set up (based on how long we want to
suspend) before suspending the host. When this alarm fires, the host
gets woken up.
Suspend-to-RAM operation on a host running Linux can take upto more than 20
seconds, depending on the load of the system. (Freezing of tasks, an operation
preceding any suspend operation, is given up after a 20 second timeout).
And Suspend-to-Disk can take even more time, considering the time required
for compaction, creating the memory image and writing it to disk etc.
So, we do not allow the user to specify a suspend duration of less than 60
seconds, to be on the safer side, since we don't want to prematurely declare
failure when we only had to wait for some more time.
2011-11-29 09:07:38 +00:00
|
|
|
# virnodesuspend.h
|
|
|
|
nodeSuspendForDuration;
|
2011-11-29 14:44:28 +00:00
|
|
|
virNodeSuspendGetTargetMask;
|
Implement the core API to suspend/resume the host
Add the core functions that implement the functionality of the API.
Suspend is done by using an asynchronous mechanism so that we can return
the status to the caller before the host gets suspended. This asynchronous
operation is achieved by suspending the host in a separate thread of
execution. However, returning the status to the caller is only best-effort,
but not guaranteed.
To resume the host, an RTC alarm is set up (based on how long we want to
suspend) before suspending the host. When this alarm fires, the host
gets woken up.
Suspend-to-RAM operation on a host running Linux can take upto more than 20
seconds, depending on the load of the system. (Freezing of tasks, an operation
preceding any suspend operation, is given up after a 20 second timeout).
And Suspend-to-Disk can take even more time, considering the time required
for compaction, creating the memory image and writing it to disk etc.
So, we do not allow the user to specify a suspend duration of less than 60
seconds, to be on the safer side, since we don't want to prematurely declare
failure when we only had to wait for some more time.
2011-11-29 09:07:38 +00:00
|
|
|
|
|
|
|
|
Add a generic reference counted virObject type
This introduces a fairly basic reference counted virObject type
and an associated virClass type, that use atomic operations for
ref counting.
In a global initializer (recommended to be invoked using the
virOnceInit API), a virClass type must be allocated for each
object type. This requires a class name, a "dispose" callback
which will be invoked to free memory associated with the object's
fields, and the size in bytes of the object struct.
eg,
virClassPtr connclass = virClassNew("virConnect",
sizeof(virConnect),
virConnectDispose);
The struct for the object, must include 'virObject' as its
first member
eg
struct _virConnect {
virObject object;
virURIPtr uri;
};
The 'dispose' callback is only responsible for freeing
fields in the object, not the object itself. eg a suitable
impl for the above struct would be
void virConnectDispose(void *obj) {
virConnectPtr conn = obj;
virURIFree(conn->uri);
}
There is no need to reset fields to 'NULL' or '0' in the
dispose callback, since the entire object will be memset
to 0, and the klass pointer & magic integer fields will
be poisoned with 0xDEADBEEF before being free()d
When creating an instance of an object, one needs simply
pass the virClassPtr eg
virConnectPtr conn = virObjectNew(connclass);
if (!conn)
return NULL;
conn->uri = virURIParse("foo:///bar")
Object references can be manipulated with
virObjectRef(conn)
virObjectUnref(conn)
The latter returns a true value, if the object has been
freed (ie its ref count hit zero)
Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
2012-07-11 13:35:44 +00:00
|
|
|
# virobject.h
|
|
|
|
virClassName;
|
|
|
|
virClassNew;
|
|
|
|
virObjectFreeCallback;
|
|
|
|
virObjectIsClass;
|
|
|
|
virObjectNew;
|
|
|
|
virObjectRef;
|
|
|
|
virObjectUnref;
|
|
|
|
|
|
|
|
|
2011-08-05 13:13:12 +00:00
|
|
|
# virpidfile.h
|
2011-07-06 16:12:26 +00:00
|
|
|
virPidFileAcquire;
|
|
|
|
virPidFileAcquirePath;
|
2011-08-05 13:13:12 +00:00
|
|
|
virPidFileBuildPath;
|
|
|
|
virPidFileRead;
|
2011-08-05 13:41:25 +00:00
|
|
|
virPidFileReadIfAlive;
|
2011-08-05 13:13:12 +00:00
|
|
|
virPidFileReadPath;
|
2011-08-05 13:41:25 +00:00
|
|
|
virPidFileReadPathIfAlive;
|
2011-07-06 16:12:26 +00:00
|
|
|
virPidFileRelease;
|
|
|
|
virPidFileReleasePath;
|
2011-08-05 13:13:12 +00:00
|
|
|
virPidFileWrite;
|
|
|
|
virPidFileWritePath;
|
|
|
|
virPidFileDelete;
|
|
|
|
virPidFileDeletePath;
|
|
|
|
|
|
|
|
|
2012-09-24 16:54:51 +00:00
|
|
|
# virprocess.h
|
2012-09-24 17:10:37 +00:00
|
|
|
virProcessAbort;
|
2012-09-24 16:54:51 +00:00
|
|
|
virProcessKill;
|
2012-09-26 14:42:58 +00:00
|
|
|
virProcessKillPainfully;
|
2012-09-24 17:10:37 +00:00
|
|
|
virProcessTranslateStatus;
|
|
|
|
virProcessWait;
|
|
|
|
|
2012-09-24 16:54:51 +00:00
|
|
|
|
2012-01-25 15:17:46 +00:00
|
|
|
# virrandom.h
|
2012-08-10 13:01:23 +00:00
|
|
|
virRandom;
|
2012-01-25 15:17:46 +00:00
|
|
|
virRandomBits;
|
2012-02-10 04:51:47 +00:00
|
|
|
virRandomGenerateWWN;
|
2012-08-10 13:01:23 +00:00
|
|
|
virRandomInt;
|
2012-01-25 15:17:46 +00:00
|
|
|
|
|
|
|
|
2011-11-18 16:07:48 +00:00
|
|
|
# virsocketaddr.h
|
|
|
|
virSocketAddrBroadcast;
|
|
|
|
virSocketAddrBroadcastByPrefix;
|
|
|
|
virSocketAddrCheckNetmask;
|
2012-04-25 13:53:29 +00:00
|
|
|
virSocketAddrEqual;
|
2011-11-18 16:07:48 +00:00
|
|
|
virSocketAddrFormat;
|
|
|
|
virSocketAddrFormatFull;
|
|
|
|
virSocketAddrGetPort;
|
|
|
|
virSocketAddrGetRange;
|
|
|
|
virSocketAddrIsNetmask;
|
|
|
|
virSocketAddrMask;
|
|
|
|
virSocketAddrMaskByPrefix;
|
|
|
|
virSocketAddrParse;
|
|
|
|
virSocketAddrParseIPv4;
|
|
|
|
virSocketAddrParseIPv6;
|
|
|
|
virSocketAddrPrefixToNetmask;
|
2012-04-25 13:53:29 +00:00
|
|
|
virSocketAddrSetIPv4Addr;
|
2011-11-18 16:07:48 +00:00
|
|
|
virSocketAddrSetPort;
|
|
|
|
|
|
|
|
|
2009-01-05 14:05:29 +00:00
|
|
|
# virterror_internal.h
|
2010-10-20 17:10:45 +00:00
|
|
|
virDispatchError;
|
2012-04-02 15:45:01 +00:00
|
|
|
virErrorInitialize;
|
2009-09-10 13:21:10 +00:00
|
|
|
virRaiseErrorFull;
|
2010-10-20 17:10:45 +00:00
|
|
|
virReportErrorHelper;
|
2009-01-20 17:13:33 +00:00
|
|
|
virReportOOMErrorFull;
|
2010-10-20 17:10:45 +00:00
|
|
|
virReportSystemErrorFull;
|
2010-01-09 01:38:55 +00:00
|
|
|
virSetError;
|
2011-01-21 17:25:01 +00:00
|
|
|
virSetErrorLogPriorityFunc;
|
2010-10-20 17:10:45 +00:00
|
|
|
virStrerror;
|
2009-01-05 14:05:29 +00:00
|
|
|
|
2011-11-29 12:11:01 +00:00
|
|
|
|
|
|
|
# virtime.h
|
|
|
|
virTimeFieldsNow;
|
2011-12-05 14:04:25 +00:00
|
|
|
virTimeFieldsNowRaw;
|
2011-11-29 12:11:01 +00:00
|
|
|
virTimeFieldsThen;
|
2011-12-05 14:04:25 +00:00
|
|
|
virTimeFieldsThenRaw;
|
|
|
|
virTimeMillisNow;
|
|
|
|
virTimeMillisNowRaw;
|
2011-11-29 12:11:01 +00:00
|
|
|
virTimeStringNow;
|
2011-12-05 14:04:25 +00:00
|
|
|
virTimeStringNowRaw;
|
2011-11-29 12:11:01 +00:00
|
|
|
virTimeStringThen;
|
2011-12-05 14:04:25 +00:00
|
|
|
virTimeStringThenRaw;
|
2011-11-29 12:11:01 +00:00
|
|
|
|
|
|
|
|
2012-01-02 22:03:19 +00:00
|
|
|
# virtypedparam.h
|
|
|
|
virTypedParameterArrayClear;
|
|
|
|
virTypedParameterArrayValidate;
|
|
|
|
virTypedParameterAssign;
|
2012-09-06 12:47:40 +00:00
|
|
|
virTypedParameterAssignFromStr;
|
2012-01-02 22:03:19 +00:00
|
|
|
|
|
|
|
|
2012-02-24 18:48:55 +00:00
|
|
|
# viruri.h
|
|
|
|
virURIFormat;
|
2012-03-20 13:59:32 +00:00
|
|
|
virURIFormatParams;
|
2012-03-20 11:59:42 +00:00
|
|
|
virURIFree;
|
2012-02-24 18:48:55 +00:00
|
|
|
virURIParse;
|
|
|
|
|
|
|
|
|
2009-01-05 14:05:29 +00:00
|
|
|
# xml.h
|
2011-12-07 22:06:18 +00:00
|
|
|
virXMLChildElementCount;
|
2011-05-26 21:30:21 +00:00
|
|
|
virXMLParseHelper;
|
2012-10-29 12:15:55 +00:00
|
|
|
virXMLPickShellSafeComment;
|
2010-10-20 17:10:45 +00:00
|
|
|
virXMLPropString;
|
2011-10-06 09:57:06 +00:00
|
|
|
virXMLSaveFile;
|
2009-11-26 17:57:00 +00:00
|
|
|
virXPathBoolean;
|
2011-01-13 22:09:18 +00:00
|
|
|
virXPathInt;
|
2009-01-05 14:05:29 +00:00
|
|
|
virXPathLong;
|
2010-10-20 17:10:45 +00:00
|
|
|
virXPathLongHex;
|
|
|
|
virXPathLongLong;
|
2009-01-05 14:05:29 +00:00
|
|
|
virXPathNode;
|
|
|
|
virXPathNodeSet;
|
2010-10-20 17:10:45 +00:00
|
|
|
virXPathNumber;
|
2009-01-05 14:05:29 +00:00
|
|
|
virXPathString;
|
2009-03-03 09:44:41 +00:00
|
|
|
virXPathStringLimit;
|
2011-01-13 22:09:18 +00:00
|
|
|
virXPathUInt;
|
2009-12-04 18:24:25 +00:00
|
|
|
virXPathULong;
|
|
|
|
virXPathULongHex;
|
2010-10-20 17:10:45 +00:00
|
|
|
virXPathULongLong;
|