You need to sign in or sign up before continuing.
- 10 7月, 2013 1 次提交
-
-
由 Michal Privoznik 提交于
Actually, I'm turning this function into a macro as filename, function name and line number needs to be passed. The new function virAsprintfInternal is introduced with the extended set of arguments.
-
- 04 7月, 2013 1 次提交
-
-
While iterating with virDomainObjListForEach it is safe to remove current element. But while iterating, 'doms' lock is already taken, so can't use standard virDomainObjListRemove. So introduce virDomainObjListRemoveLocked for this purpose. Signed-off-by: NMarek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
-
- 03 7月, 2013 3 次提交
-
-
由 Daniel P. Berrange 提交于
Ensure that all APIs which list storage objects filter them against the access control system. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Daniel P. Berrange 提交于
Ensure that all APIs which list node device objects filter them against the access control system. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Daniel P. Berrange 提交于
Ensure that all APIs which list network objects filter them against the access control system. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 02 7月, 2013 1 次提交
-
-
由 Roman Bogorodskiy 提交于
iptablesContext holds only 4 pairs of iptables (table, chain) and there's no need to pass it around. This is a first step towards separating bridge_driver.c in platform-specific parts.
-
- 27 6月, 2013 1 次提交
-
-
由 Laine Stump 提交于
Any device which belongs to an "IOMMU group" (used by vfio) will have links to all devices of its group listed in /sys/bus/pci/$device/iommu_group/devices; /sys/bus/pci/$device/iommu_group is actually a link to /sys/kernel/iommu_groups/$n, where $n is the group number (there will be a corresponding device node at /dev/vfio/$n once the devices are bound to the vfio-pci driver) The following functions are added: virPCIDeviceGetIOMMUGroupList Gets a virPCIDeviceList with one virPCIDeviceList for each device in the same IOMMU group as the provided virPCIDevice (a copy of the original device object is included in the list. virPCIDeviceAddressIOMMUGroupIterate Calls the function @actor once for each device in the group that contains the given virPCIDeviceAddress. virPCIDeviceAddressGetIOMMUGroupAddresses Fills in a virPCIDeviceAddressPtr * with an array of virPCIDeviceAddress, one for each device in the iommu group of the provided virPCIDeviceAddress (including a copy of the original). virPCIDeviceAddressGetIOMMUGroupNum Returns the group number as an int (a valid group number will always be 0 or greater). If there is no iommu_group link in the device's directory (usually indicating that vfio isn't loaded), -2 will be returned. On any real error, -1 will be returned.
-
- 26 6月, 2013 3 次提交
-
-
由 Laine Stump 提交于
Make a copy of the device and add the copy to the list. (virPCIDeviceListAdd() adds the original object to the list instead).
-
由 Laine Stump 提交于
This function has utility outside of virpci.c, so make it public. Also the name didn't fit convention, so change it to virPCIDeviceAddressParse.
-
由 Laine Stump 提交于
I realized after the fact that it's probably better in the long run to give this function a name that matches the name of the link used in sysfs to hold the group (iommu_group). I'm changing it now because I'm about to add several more functions that deal with iommu groups.
-
- 25 6月, 2013 7 次提交
-
-
由 Jiri Denemark 提交于
This patch implements extensible variants of all internal migration APIs used for v3 migration.
-
由 Jiri Denemark 提交于
-
由 Jiri Denemark 提交于
All APIs that take typed parameters are only using params address in their entry point debug messages. With the new VIR_TYPED_PARAMS_DEBUG macro, all functions can easily log all individual typed parameters passed to them.
-
由 Jiri Denemark 提交于
-
由 Jiri Denemark 提交于
This API is useful for checking whether only a specific subset of supported typed parameters were passed.
-
由 Jiri Denemark 提交于
-
由 Laine Stump 提交于
* virPCIDeviceFindByIDs - find a device on a list w/o creating an object This makes searching for an existing device on a list lighter weight. * virPCIDeviceCopy - make a copy of an existing virPCIDevice object. * virPCIDeviceGetDriverPathAndName - construct new strings containing 1) the name of the driver bound to this device. 2) the full path to the sysfs config for that driver. (This code was lifted from virPCIDeviceUnbindFromStub, and replaced there with a call to this new function).
-
- 24 6月, 2013 2 次提交
-
-
由 Daniel P. Berrange 提交于
Add a new 'access_drivers' config parameter to the libvirtd.conf configuration file. This allows admins to setup the default access control drivers to use for API authorization. The same driver is to be used by all internal drivers & APIs Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Daniel P. Berrange 提交于
This patch introduces the virAccessManagerPtr class as the interface between virtualization drivers and the access control drivers. The viraccessperm.h file defines the various permissions that will be used for each type of object libvirt manages Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 21 6月, 2013 1 次提交
-
-
由 Ján Tomko 提交于
Add <features> and <compat> elements to volume target XML. <compat> is a string which for qcow2 represents the QEMU version it should be compatible with. Valid values are 0.10 and 1.1. 1.1 is implicit if the <features> element is present, otherwise qemu-img default is used. 0.10 can be specified to explicitly create older images after the qemu-img default changes. <features> contains optional features, so far <lazy_refcounts/> is available, which enables caching of reference counters, improving performance for snapshots.
-
- 14 6月, 2013 2 次提交
-
-
由 Roman Bogorodskiy 提交于
This method is useful not only in virnetdev.c.
-
由 Ján Tomko 提交于
Call virLogVMessage instead of virLogMessage, since libudev called us with a va_list object, not a list of arguments. Honor message priority and strip the trailing newline. https://bugzilla.redhat.com/show_bug.cgi?id=969152
-
- 12 6月, 2013 1 次提交
-
-
- 07 6月, 2013 1 次提交
-
-
由 Michal Privoznik 提交于
This internal API checks, if passed address is a wildcard address.
-
- 01 6月, 2013 1 次提交
-
-
由 Daniel P. Berrange 提交于
We can't use GNULIB's fprintf-posix due to licensing incompatibilities. We do already have a portable formatting via virAsprintf() which we got from GNULIB though. We can use to create a virFilePrintf() function. But really gnulib could just provide a 'fprintf' module, that depended on just its 'asprintf' module. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 22 5月, 2013 1 次提交
-
-
由 Guannan Ren 提交于
-vnc :5900,share=allow-exclusive allows clients to ask for exclusive access which is implemented by dropping other connections Connecting multiple clients in parallel requires all clients asking for a shared session (vncviewer: -shared switch) -vnc :5900,share=force-shared disables exclusive client access. Useful for shared desktop sessions, where you don't want someone forgetting specify -shared disconnect everybody else. -vnc :5900,share=ignore completely ignores the shared flag and allows everybody connect unconditionally
-
- 21 5月, 2013 1 次提交
-
-
由 Daniel P. Berrange 提交于
Introduce use of a virDomainDefPtr in the domain lookup APIs to simplify introduction of ACL security checks. The virDomainPtr cannot be safely used, since the app may have supplied mis-matching name/uuid/id fields. eg the name points to domain X, while the uuid points to domain Y. Resolving the virDomainPtr to a virDomainDefPtr ensures a consistent name/uuid/id set. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 16 5月, 2013 1 次提交
-
-
由 Osier Yang 提交于
E.g. % sg_map /dev/sg0 /dev/sda /dev/sg1 /dev/sr0 What the helper gets for /dev/sg0 is /dev/sda, it will be used by later patch.
-
- 15 5月, 2013 1 次提交
-
-
由 Osier Yang 提交于
QEMU introduced "discard" option for drive since commit a9384aff53, <...> @var{discard} is one of "ignore" (or "off") or "unmap" (or "on") and controls whether @dfn{discard} (also known as @dfn{trim} or @dfn{unmap}) requests are ignored or passed to the filesystem. Some machine types may not support discard requests. </...> This patch exposes the support in libvirt. QEMU supported "discard" for "-drive" since v1.5.0-rc0: % git tag --contains a9384aff53 contains v1.5.0-rc0 v1.5.0-rc1 So this only detects the capability bit using virQEMUCapsProbeQMPCommandLine.
-
- 14 5月, 2013 2 次提交
-
-
由 Eric Blake 提交于
In an upcoming patch, I need the way to safely transfer a nested virJSON object out of its parent container for independent use, even after the parent is freed. * src/util/virjson.h (virJSONValueObjectRemoveKey): New function. (_virJSONObject, _virJSONArray): Use correct type. * src/util/virjson.c (virJSONValueObjectRemoveKey): Implement it. * src/libvirt_private.syms (virjson.h): Export it. * tests/jsontest.c (mymain): Test it. Signed-off-by: NEric Blake <eblake@redhat.com>
-
由 Gene Czarcinski 提交于
network: static route support for <network> This patch adds the <route> subelement of <network> to define a static route. the address and prefix (or netmask) attribute identify the destination network, and the gateway attribute specifies the next hop address (which must be directly reachable from the containing <network>) which is to receive the packets destined for "address/(prefix|netmask)". These attributes are translated into an "ip route add" command that is executed when the network is started. The command used is of the following form: ip route add <address>/<prefix> via <gateway> \ dev <virbr-bridge> proto static metric <metric> Tests are done to validate that the input data are correct. For example, for a static route ip definition, the address must be a network address and not a host address. Additional checks are added to ensure that the specified gateway is directly reachable via this network (i.e. that the gateway IP address is in the same subnet as one of the IP's defined for the network). prefix='0' is supported for both family='ipv4' address='0.0.0.0' netmask='0.0.0.0' or prefix='0', and for family='ipv6' address='::', prefix=0', although care should be taken to not override a desired system default route. Anytime an attempt is made to define a static route which *exactly* duplicates an existing static route (for example, address=::, prefix=0, metric=1), the following error message will be sent to syslog: RTNETLINK answers: File exists This can be overridden by decreasing the metric value for the route that should be preferred, or increasing the metric for the route that shouldn't be preferred (and is thus in place only in anticipation that the preferred route may be removed in the future). Caution should be used when manipulating route metrics, especially for a default route. Note: The use of the command-line interface should be replaced by direct use of libnl so that error conditions can be handled better. But, that is being left as an exercise for another day. Signed-off-by: NGene Czarcinski <gene@czarc.net> Signed-off-by: NLaine Stump <laine@laine.org>
-
- 13 5月, 2013 2 次提交
-
-
由 Daniel P. Berrange 提交于
Add a virFileNBDDeviceAssociate method, which given a filename will setup a NBD device, using qemu-nbd as the server. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Han Cheng 提交于
This patch adds util functions for scsi hostdev. Signed-off-by: NHan Cheng <hanc.fnst@cn.fujitsu.com> Signed-off-by: NOsier Yang <jyang@redhat.com>
-
- 11 5月, 2013 2 次提交
-
-
由 Daniel P. Berrange 提交于
Currently the fdstream function hardcodes the location of the iohelper to LIBEXECDIR "/libvirt_iohelper". This is not convenient when trying to write test cases which use this code. Add a virFDStreamSetIOHelper method to allow the test cases to point to the location of the un-installed iohelper binary. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Laine Stump 提交于
These all existed before virfile.c was created, and for some reason weren't moved. This is mostly straightfoward, although the syntax rule prohibiting write() had to be changed to have an exception for virfile.c instead of virutil.c. This movement pointed out that there is a function called virBuildPath(), and another almost identical function called virFileBuildPath(). They really should be a single function, which I'll take care of as soon as I figure out what the arglist should look like.
-
- 08 5月, 2013 2 次提交
-
-
由 Daniel P. Berrange 提交于
Since PIDs can be reused, polkit prefers to be given a (PID,start time) pair. If given a PID on its own, it will attempt to lookup the start time in /proc/pid/stat, though this is subject to races. It is safer if the client app resolves the PID start time itself, because as long as the app has the client socket open, the client PID won't be reused. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Daniel P. Berrange 提交于
There are various methods named "virXXXXSecurityContext", which are specific to SELinux. Rename them all to "virXXXXSELinuxContext". They will still raise errors at runtime if SELinux is not compiled in Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 05 5月, 2013 1 次提交
-
-
由 Michal Privoznik 提交于
The code adaptation is not done right now, but in subsequent patches. Hence I am not implementing syntax-check rule as it would break compilation. Developers are strongly advised to use these new macros. They are similar to VIR_ALLOC() logic: VIR_STRDUP(dst, src) returns zero on success, -1 otherwise. In case you don't want to report OOM error, use the _QUIET variant of a macro.
-
- 02 5月, 2013 1 次提交
-
-
由 Michal Privoznik 提交于
The source code base needs to be adapted as well. Some files include virutil.h just for the string related functions (here, the include is substituted to match the new file), some include virutil.h without any need (here, the include is removed), and some require both.
-
- 27 4月, 2013 1 次提交
-
-
由 Paolo Bonzini 提交于
This will be used on a tap file descriptor returned by the bridge helper to populate the <target> element, because the helper does not provide the interface name. Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
-