- 19 4月, 2016 1 次提交
-
-
由 Martin Kletzander 提交于
It already labels abritrary paths, so it's just the naming that was wrong. Signed-off-by: NMartin Kletzander <mkletzan@redhat.com>
-
- 18 4月, 2016 2 次提交
-
-
由 Erik Skultety 提交于
Since threadpool increments the current number of threads according to current load, i.e. how many jobs are waiting in the queue. The count however, is constrained by max and min limits of workers. The logic of this new API works like this: 1) setting the minimum a) When the limit is increased, depending on the current number of threads, new threads are possibly spawned if the current number of threads is less than the new minimum limit b) Decreasing the minimum limit has no possible effect on the current number of threads 2) setting the maximum a) Icreasing the maximum limit has no immediate effect on the current number of threads, it only allows the threadpool to spawn more threads when new jobs, that would otherwise end up queued, arrive. b) Decreasing the maximum limit may affect the current number of threads, if the current number of threads is less than the new maximum limit. Since there may be some ongoing time-consuming jobs that would effectively block this API from killing any threads. Therefore, this API is asynchronous with best-effort execution, i.e. the necessary number of workers will be terminated once they finish their previous job, unless other workers had already terminated, decreasing the limit to the requested value. 3) setting priority workers - both increase and decrease in count of these workers have an immediate impact on the current number of workers, new ones will be spawned or some of them get terminated respectively. Signed-off-by: NErik Skultety <eskultet@redhat.com>
-
由 Erik Skultety 提交于
In order for the client to see all thread counts and limits, current total and free worker count getters need to be introduced. Client might also be interested in the job queue length, so provide a getter for that too. As with the other getters, preparing for the admin interface, mutual exclusion is used within all getters. Signed-off-by: NErik Skultety <eskultet@redhat.com>
-
- 15 4月, 2016 4 次提交
-
-
由 Richard W.M. Jones 提交于
In a few places in libvirt we busy-wait for events, for example qemu creating a monitor socket. This is problematic because: - We need to choose a sufficiently small polling period so that libvirt doesn't add unnecessary delays. - We need to choose a sufficiently large polling period so that the effect of busy-waiting doesn't affect the system. The solution to this conflict is to use an exponential backoff. This patch adds two functions to hide the details, and modifies a few places where we currently busy-wait. Signed-off-by: NRichard W.M. Jones <rjones@redhat.com>
-
由 Peter Krempa 提交于
-
由 Laine Stump 提交于
There are two places in qemu_domain_address.c where we have a switch statement to convert PCI controller models (VIR_DOMAIN_CONTROLLER_MODEL_PCI*) into the connection type flag that is matched when looking for an upstream connection for that model of controller (VIR_PCI_CONNECT_TYPE_*). This patch makes a utility function in conf/domain_addr.c to do that, so that when a new PCI controller is added, we only need to add the new model-->connect-type in a single place.
-
由 Cole Robinson 提交于
Take setlocale/gettext error handling pattern from tools/virsh-* and use it for all standalone binaries via a new shared virGettextInitialize routine. The virsh* pattern differed slightly from other callers. All users now consistently: * Ignore setlocale errors. virsh has done this forever, presumably for good reason. This has been partially responsible for some bug reports: https://bugzilla.redhat.com/show_bug.cgi?id=1312688 https://bugzilla.redhat.com/show_bug.cgi?id=1026514 https://bugzilla.redhat.com/show_bug.cgi?id=1016158 * Report the failed function name * Report strerror
-
- 14 4月, 2016 1 次提交
-
-
由 Maxim Nestratov 提交于
commit 30c61901 added new functions to libvirt_private.syms not alpabetically sorted and erroneously added vz sources to STATEFUL_DRIVER_SOURCE_FILES, which triggered check-aclrules running while vz driver isn't ready for it yet. Pushing under build-breaker rule. Signed-off-by: NMaxim Nestratov <mnestratov@virtuozzo.com>
-
- 13 4月, 2016 9 次提交
-
-
由 Maxim Nestratov 提交于
Make it possible to build vz driver as a module and don't link it with libvirt.so statically. Remove registering it on client's side as far as we start relying on daemon Signed-off-by: NMaxim Nestratov <mnestratov@virtuozzo.com>
-
由 Ján Tomko 提交于
Mock virNetDevRunEthernetScript instead. This restores the VIR_TEST_REGENERATE_OUTPUT functionality.
-
由 Peter Krempa 提交于
Since we didn't opt to use one single event for device lifecycle for a VM we are missing one last event if the device removal failed. This event will be emitted once we asked to eject the device but for some reason it is not possible.
-
由 Pavel Hrdina 提交于
Those are the last two places that uses the getter functions. Use a direct access instead and remove those getters. Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Pavel Hrdina 提交于
Removes the check for graphics type, it's not a public API and developer know what he's doing and this check makes no sense. It also removes the ability to allocate a new array if there is none. This was used by the virDomainGraphicsListenAdd* functions and isn't used anymore. This is now a simple getter with simple check for listens array presence and whether the index in out of bounds. Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Pavel Hrdina 提交于
Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Pavel Hrdina 提交于
Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Pavel Hrdina 提交于
This effectively removes virDomainGraphicsListenSetAddress which was used only to change the address of listen structure and possible change the listen type. The new function will auto-expand the listens array and append a new listen. The old function was used on pre-allocated array of listens and in most cases it only "add" a new listen. The two remaining uses can access the listen structure directly. Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Peter Krempa 提交于
-
- 07 4月, 2016 2 次提交
-
-
由 John Ferlan 提交于
Commit id 'fb2bd208' essentially copied the qemuGetSecretString creating an libxlGetSecretString. Rather than have multiple copies of the same code, create src/secret/secret_util.{c,h} files and place the common function in there. Modify the the build in order to build the module as a library which is then pulled in by both the qemu and libxl drivers for usage from both qemu_command.c and libxl_conf.c
-
由 John Ferlan 提交于
Using the existing virUUIDGenerateRandomBytes, move API to virrandom.c rename it to virRandomBytes and add it to libvirt_private.syms. This will be used as a fallback for generating a domain master key.
-
- 30 3月, 2016 2 次提交
-
-
由 Peter Krempa 提交于
-
由 Peter Krempa 提交于
In some cases it's impractical to use the regular APIs as the bitmap size needs to be pre-declared. These new APIs allow to use bitmaps that self expand. The new code adds a property to the bitmap to track the allocation of memory so that VIR_RESIZE_N can be used.
-
- 29 3月, 2016 1 次提交
-
-
由 Qiaowei Ren 提交于
This patch implement a set of interfaces for perf event. Based on these interfaces, we can implement internal driver API for perf, and get the results of perf conuter you care about. Signed-off-by: NQiaowei Ren <qiaowei.ren@intel.com> Message-id: 1459171833-26416-4-git-send-email-qiaowei.ren@intel.com
-
- 21 3月, 2016 2 次提交
-
-
由 Martin Kletzander 提交于
This allows setting the address in host and/or network order and makes the naming consistent. Now you don't need to call [hn]to[nh]l() functions as that is taken care of by these functions. Also, now the *NetOrder take the address in network order, the other functions in host order so the naming and usage is consistent. Some places were having the address in network order and calling ntohl() just so the original function can call htonl() again. This makes it nicer to read. Signed-off-by: NMartin Kletzander <mkletzan@redhat.com>
-
由 Cole Robinson 提交于
It's just a combination of AddImplicitControllers, and AddConsoleCompat. Every caller that wants ImplicitControllers also wants the ConsoleCompat AFAICT, so lump them together. We also need it for future patches.
-
- 19 3月, 2016 3 次提交
-
-
由 Martin Kletzander 提交于
If we expose this information, which is one byte in every PCI config file, we let all mgmt apps know whether the device itself is an endpoint or not so it's easier for them to decide whether such device can be passed through into a VM (endpoint) or not (*-bridge). Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1317531Signed-off-by: NMartin Kletzander <mkletzan@redhat.com>
-
由 Michal Privoznik 提交于
This is a missing counterpart for virSocketAddrSetIPv4Addr() and is going to be needed later in the tests. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
由 Michal Privoznik 提交于
These functions are going to be reused very shortly. So instead of duplicating the code, lets move them into utils module. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 09 3月, 2016 2 次提交
-
-
由 Peter Krempa 提交于
Introduce a helper to check supported device and domain config and move the memory hotplug checks to it. The advantage of this approach is that by default all new features are considered unsupported by all hypervisors unless specifically changed rather than the previous approach where every hypervisor would need to declare that a given feature is unsupported.
-
由 Peter Krempa 提交于
The implementation of the inner guts of the function is similar for all drivers, so we can add a helper and not have to reimplement it three times.
-
- 08 3月, 2016 1 次提交
-
-
由 Jiri Denemark 提交于
The VIR_DOMAIN_EVENT_ID_JOB_COMPLETED event will be triggered once a job (such as migration) finishes and it will contain statistics for the job as one would get by calling virDomainGetJobStats. Thanks to this event it is now possible to get statistics of a completed migration of a transient domain on the source host. Signed-off-by: NJiri Denemark <jdenemar@redhat.com>
-
- 03 3月, 2016 1 次提交
-
-
由 Michal Privoznik 提交于
While trying to build with -Os I've encountered some build failures. util/vircommand.c: In function 'virCommandAddEnvFormat': util/vircommand.c:1257:1: error: inlining failed in call to 'virCommandAddEnv': call is unlikely and code size would grow [-Werror=inline] virCommandAddEnv(virCommandPtr cmd, char *env) ^ util/vircommand.c:1308:5: error: called from here [-Werror=inline] virCommandAddEnv(cmd, env); ^ This function is big enough for the compiler to be not inlined. This is the error message I'm seeing: Then virDomainNumatuneNodeSpecified is exported and called from other places. It shouldn't be inlined then. In file included from network/bridge_driver_platform.h:30:0, from network/bridge_driver_platform.c:26: network/bridge_driver_linux.c: In function 'networkRemoveRoutingFirewallRules': ./conf/network_conf.h:350:1: error: inlining failed in call to 'virNetworkDefForwardIf.constprop': call is unlikely and code size would grow [-Werror=inline] virNetworkDefForwardIf(const virNetworkDef *def, size_t n) ^ Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 01 3月, 2016 2 次提交
-
-
由 Henning Schild 提交于
qemuProcessSetupEmulator runs at a point in time where there is only the qemu main thread. Use virCgroupAddTask to put just that one task into the emulator cgroup. That patch makes virCgroupMoveTask and virCgroupAddTaskStrController obsolete. Signed-off-by: NHenning Schild <henning.schild@siemens.com>
-
由 John Ferlan 提交于
Introduce virPolkitAgentCreate and virPolkitAgentDestroy virPolkitAgentCreate will run the polkit pkttyagent image as an asynchronous command in order to handle the local agent authentication via stdin/stdout. The code makes use of the pkttyagent --notify-fd mechanism to let it know when the agent is successfully registered. virPolkitAgentDestroy will close the command effectively reaping our child process
-
- 17 2月, 2016 1 次提交
-
-
由 Peter Krempa 提交于
Since commit 47e5b5ae virCgroupAllowDevice allows to pass -1 as either the minor or major device number and it automatically uses '*' in place of that. Reuse the new approach through the code and drop the duplicated functions.
-
- 16 2月, 2016 1 次提交
-
-
由 Andrea Bolognani 提交于
Instead of allowing any random positive number, restrict the possible values to the ones that are part of the virGICVersion enumeration.
-
- 11 2月, 2016 1 次提交
-
-
由 Michal Privoznik 提交于
Apparently we are not the only ones with dumb free functions because dbus_message_unref() does not accept NULL either. But if I were to vote, this one is even more evil. Instead of returning an error just like we do it immediately dereference any pointer passed and thus crash you app. Well done DBus! Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x7f878ebda700 (LWP 31264)] 0x00007f87be4016e5 in ?? () from /usr/lib64/libdbus-1.so.3 (gdb) bt #0 0x00007f87be4016e5 in ?? () from /usr/lib64/libdbus-1.so.3 #1 0x00007f87be3f004e in dbus_message_unref () from /usr/lib64/libdbus-1.so.3 #2 0x00007f87bf6ecf95 in virSystemdGetMachineNameByPID (pid=9849) at util/virsystemd.c:228 #3 0x00007f879761bd4d in qemuConnectCgroup (driver=0x7f87600a32a0, vm=0x7f87600c7550) at qemu/qemu_cgroup.c:909 #4 0x00007f87976386b7 in qemuProcessReconnect (opaque=0x7f87600db840) at qemu/qemu_process.c:3386 #5 0x00007f87bf6edfff in virThreadHelper (data=0x7f87600d5580) at util/virthread.c:206 #6 0x00007f87bb602334 in start_thread (arg=0x7f878ebda700) at pthread_create.c:333 #7 0x00007f87bb3481bd in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109 (gdb) frame 2 #2 0x00007f87bf6ecf95 in virSystemdGetMachineNameByPID (pid=9849) at util/virsystemd.c:228 228 dbus_message_unref(reply); (gdb) p reply $1 = (DBusMessage *) 0x0 Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 08 2月, 2016 4 次提交
-
-
由 Peter Krempa 提交于
Similarly to previous commit change the way how iothread scheduler info is stored and clean up a lot of unnecessary code.
-
由 Peter Krempa 提交于
Now that the pinning info is stored elsewhere we can delete all the obsolete code.
-
由 Peter Krempa 提交于
Move the logic from virDomainDiskDefDstDuplicates into virDomainDiskDefCheckDuplicateInfo so that we don't have to loop multiple times through the array of disks. Since the original function was called in qemuBuildDriveDevStr, it was actually called for every single disk which was quite wasteful. Additionally the target uniqueness check needed to be duplicated in the disk hotplug case, since the disk was inserted into the domain definition after the device string was formatted and thus virDomainDiskDefDstDuplicates didn't do anything in that case.
-
由 Peter Krempa 提交于
We do the check on VM start, but the user could still hotplug a disk with a conflicting serial or WWN. Reuse the checker function to fix the issue.
-