Currently, ESX driver can only issue VI method calls available in version
2.5. To send method calls available in newer versions, a SOAPAction
header needs to be set in the following format:
'SOAPAction: urn:vim25/version_number'
This patch modifies the Python code generator to optionally read
This patch implements virDomainScreenshot support for ESX versions newer
than 4.0. It adds CreateScreenshot_Task (apiVersion 4.0) and
DeleteDatastoreFile_Task (v2.5) then uses those to implement
esxDomainScreenshot function. The DeleteDatastoreFile_Task is used to
remove the screenshot file that
token to the method header definition in the .input file. If it is not
specified, 2.5 will be used so existing VI calls will work as is
without any code updates.
Regards,
Dawid Zamirski (2):
ESX: Allow method calls for VI version 2.5
ESX: Implement virDomainScreenshot
src/esx/esx_driver.c
This follows the same pattern when v8 and v9 were added. I've tested
this with my ESX 5.5 and seems to work fine.
---
src/vmx/vmx.c | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/src/vmx/vmx.c b/src/vmx/vmx.c
index 32ddd05..5dc9925 100644
--- a/src/vmx/vmx.c
+++
no ESX test system at hand for the last year or so.
Dawid Zamirski posted some patches [1] to implement virDomainScreenshot
for ESX. So I finally managed to set up some ESX test system again this
weekend and get my old code dusted up. His implementation has two
disadvantages, namely storing
Since the ESX storage implements VMFS and iSCSI storage backends and
chooses relevant backend dynamically at runtime, there was a segfault
when issuing vol-info on iSCSI volume due to unimplemented
virStorageGetInfo function. This patch implements that function that was
missing in iSCSI backend
This patch adds support for virNodeGetFreeMemory which is available in
libvirt since v0.3.3. While the php bindings alredy provide
libvirt_node_get_mem_stats from which such info could be obtained, not
all hypervisors support it, e.g. vbox and esx driver don't have it but
they do implement
On Thu, 2014-05-01 at 12:55 -0600, Eric Blake wrote:
[meta-comment]
I'm not a PHP expert, so I'll let others review the patch itself. But
when contributing patches to libvirt-php.git, it helps if you do:
git config format.subjectprefix php PATCH
to make it obvious which repo you are
This patch fixes a bug where zend_parse_parameters would segfault on
certain PHP version (spotted on PHP 5.3.2 64bit) where type specifier is
long l and variable reference is int or unsigned int. Changing the
variable type from int or unsigned int to long fixes the problem for me
and is a known
The previous patch [1] caused compiler warnings after variable types
were changed from int to long and this patch fixes this.
[1] https://www.redhat.com/archives/libvir-list/2014-June/msg00835.html
---
src/libvirt-php.c | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git
.
Sorry for the noise with such a simple patch...
Regards,
Dawid
2014-06-18 22:05 GMT+02:00 Dawid Zamirski dzamir...@dattobackup.com:
Ugh, now I know what happened - my local master branch has
commits I
have not sent pull requests for yet so it wasn't in 100
The IKeyboard COM object is needed to implement virDomainSendKey and is
available in all supported VBOX versions.
---
src/vbox/vbox_tmpl.c | 27 +++
src/vbox/vbox_uniformed_api.h | 8
2 files changed, 35 insertions(+)
diff --git a/src/vbox/vbox_tmpl.c
Since the holdtime is not supported by VBOX SDK, it's being simulated
by sleeping before sending the key-up codes. The key-up codes are
auto-generated based on XT codeset rules (adding of 0x80 to key-down)
which results in the same behavior as for QEMU implementation.
---
src/vbox/vbox_common.c |
.
Dawid Zamirski (2):
vbox: Register IKeyboard with the unified API.
vbox: Implement virDomainSendKey
src/vbox/vbox_common.c| 107 ++
src/vbox/vbox_common.h| 1 +
src/vbox/vbox_tmpl.c | 27 +++
src/vbox
For VBOX it's most likely that the connection is vbox:///session and it
runs with local non-root account. This caused permission denied when
LOCALSTATEDIR was used to create temp file. This patch makes use of the
virGetUserCacheDirectory to address this problem for non-root users.
---
From: Dawid Zamirski dzamir...@dattobackup.com
This NIC model is supported on hardware version 8 and newer and libvirt
ESX driver does support those.
---
src/vmx/vmx.c | 10 ++
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/src/vmx/vmx.c b/src/vmx/vmx.c
index ac2542a
Before this patch, when connected via vCenter, the free memory returned
was from the resorcePool (usually a cluster). This is in conflict with
e.g esxNodeGetInfo which always pulls info from the ESX host.
Since libvirt ESX driver works primarily with ESX hosts, this patch
changes
is mandatory, even for vpx connections)
so to make this consitent, these patches make virNodeGetFreeMemory
always return info from the ESX host.
Dawid Zamirski (2):
esx: add esxVI_GetInt
esx: esxNodeGetFreeMemory return info from host.
src/esx/esx_driver.c | 53
Modeled after the already existing esxVI_GetLong.
---
src/esx/esx_vi.c | 32
src/esx/esx_vi.h | 3 +++
src/esx/esx_vi_types.c | 3 +++
src/esx/esx_vi_types.h | 1 +
4 files changed, 39 insertions(+)
diff --git a/src/esx/esx_vi.c b/src/esx/esx_vi.c
://www.redhat.com/archives/libvir-list/2015-March/msg01028.html
v2:
- add virReportError in all potentially failing code paths
- coding style adjustment
- mark for 1.2.15
Dawid Zamirski (2):
vbox: Register IKeyboard with the unified API.
vbox: Implement virDomainSendKey
src/vbox/vbox_common.c
Since the holdtime is not supported by VBOX SDK, it's being simulated
by sleeping before sending the key-up codes. The key-up codes are
auto-generated based on XT codeset rules (adding of 0x80 to key-down)
which results in the same behavior as for QEMU implementation.
---
src/vbox/vbox_common.c |
The IKeyboard COM object is needed to implement virDomainSendKey and is
available in all supported VBOX versions.
---
src/vbox/vbox_tmpl.c | 27 +++
src/vbox/vbox_uniformed_api.h | 8
2 files changed, 35 insertions(+)
diff --git a/src/vbox/vbox_tmpl.c
On Tue, 2015-04-07 at 12:27 +0200, Ján Tomko wrote:
On Thu, Mar 19, 2015 at 05:43:57PM -0400, Dawid Zamirski wrote:
Since the holdtime is not supported by VBOX SDK, it's being
simulated
by sleeping before sending the key-up codes. The key-up codes are
auto-generated based on XT codeset
Hi Michal,
Thanks for reviewing. I'll send v2 soon to handle EnsureSession as
well.
Regards,
Dawid
On Wed, 2016-05-25 at 14:33 +0200, Michal Privoznik wrote:
> On 23.05.2016 23:32, Dawid Zamirski wrote:
> > This patch fixes an issue where screenshot API call was failing
> > w
This patch fixes an issue where screenshot API call was failing when
the esx/vcenter password contains special characters such as
apostrophee. The reason for failures was that passwords were escaped
for XML and stored in esxVI_Context which was then passed to raw CURL
API calls where the password
When a SCSI controller is present, ESX adds several pciBridge devices
to vmx file. This fixes an error message where it refuses to create VM
due to not enough PCI devices available. This applies only to virtualHW
version >= 7.
---
src/vmx/vmx.c | 25
This is because there's a known issue where ESX will refuse to attach
drives bigger than 4TB when virtualHW < 9. Therefore, to avoid that
use the higher virtualHW for hosts that support it.
---
https://kb.vmware.com/selfservice/microsites/search.do?language=en_US=displayKC=2054952
This patch fixes an issue where vMotion fails when VMCI device is not
present in the vmx file.
---
src/vmx/vmx.c | 2 ++
tests/xml2vmxdata/xml2vmx-fusion-in-the-wild-1.vmx | 1 +
tests/xml2vmxdata/xml2vmx-serial-network-client.vmx | 1 +
size limit and vMotion compatibility.
Dawid Zamirski (3):
esx: add pciBridge devices when SCSI is used
esx: Add VMCI device for virtualHW >= 7
esx: use newer virtualHW version for 5.1+ hosts
src/esx/esx_vi.c | 17 ++
src/vmx/vm
This patch fixes an issue where screenshot API call was failing when
the esx/vcenter password contains special characters such as
apostrophee. The reason for failures was that passwords were escaped
for XML and stored in esxVI_Context which was then passed to raw CURL API
calls where the password
ESX will refuse to attach VMDKS that have buslogic adatper type to 64bit
VMs whereas lsilogic works fine both 32bit and 64bit VMs.
---
src/esx/esx_storage_backend_vmfs.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/esx/esx_storage_backend_vmfs.c
This results in cleaner code and fixes other potential bugs, e.g.
in get_next_free_numeric_value
---
src/libvirt-php.c | 141 ++
1 file changed, 25 insertions(+), 116 deletions(-)
diff --git a/src/libvirt-php.c b/src/libvirt-php.c
index
Since addition of PHP7 the libvirt_connect regressed on PHP5 where it
was no longer reading out credential info from the php hash table
properly. This patch makes use of the loop macros that handle both PHP
versions correctly and consequently fix this issue.
---
src/libvirt-php.c | 33
Since PHP5 and 7 differ slightly on how looping over php hash tables is
done, those macros were added to abstract away those differences and
avoid using ifdefs for each php version.
---
src/libvirt-php.c | 31 +++
src/libvirt-php.h | 6 ++
2 files changed, 37
and the remaining commits make use of that.
Dawid Zamirski (3):
Define macros for looping php hash tables.
libvirt_connect: use loop macros to read cred info.
use VIRT_FOREACH macros everywhere.
src/libvirt-php.c | 205 +-
src/libvirt-php.h | 6 ++
2
On Tue, 2016-08-09 at 12:39 +, Jason Miesionczek wrote:
> ---
> src/hyperv/hyperv_driver.c | 106
> +++-
> src/hyperv/hyperv_private.h | 2 +
> 2 files changed, 107 insertions(+), 1 deletion(-)
>
>
It seems that there was initial review [1] done
On Tue, 2016-08-09 at 12:39 +, Jason Miesionczek wrote:
> ---
> src/hyperv/hyperv_driver.c | 52
> ++
> 1 file changed, 52 insertions(+)
>
> diff --git a/src/hyperv/hyperv_driver.c b/src/hyperv/hyperv_driver.c
> index 4a5e80d..b2d1abf 100644
> ---
From: Dawid Zamirski <dzamir...@dattobackup.com>
This patch adds support for virNodeGetFreeMemory which is available in
libvirt since v0.3.3. While the php bindings alredy provide
libvirt_node_get_mem_stats from which such info could be obtained, not
all hypervisors support it, e.g. vbox a
From: Dawid Zamirski <dzamir...@dattobackup.com>
This patch implements virConnectDomainXMLFromNative and
virConnectDomainXMLToNative in libvirt PHP bindings. The PHP functions
are called libvirt_domain_xml_from_native and
libvirt_domain_xml_to_native respectively.
---
src/libvirt-php.
Provides PHP bindings to libvirt's virDomainAttachDeviceFlags and
virDomainDetachDeviceFlags APIs.
---
src/libvirt-php.c | 70 ---
src/libvirt-php.h | 2 ++
2 files changed, 69 insertions(+), 3 deletions(-)
diff --git a/src/libvirt-php.c
This patch adds libvirt_domain_send_key_api which calls to
virDomainSendKey libvirt API function to send key press events to a
domain. The PHP bindings already have libvirt_domain_send_keys function
which uses VNC to provide similar functionality but that has limited
use cases and depends on a
This patch series adds more libvirt API bindings to libvirt-php. The
first patch in the series is a repost of:
https://www.redhat.com/archives/libvir-list/2014-May/msg00021.html
Dawid Zamirski (4):
implement libvirt_node_get_free_memory
implement xml_to_native and xml_from_native
implement
This commit should be squashed to previous one. Keeping it separate for
code-review purposes only as it's mostly noise due to changes of the
struct definitions in previous patch:
* vboxPrivate (aka old vboxGlobalData *data argument) no longer needs
to be passed around as g_pVBoxGlobalData is
Since VBOX API initialization method (pfnComInitialize) is not
thread-safe and must be called from the primary thread, calling it in
every vboxConnectOpen (as we used to do) leads to segmentation
faults when multiple connections are in use. Therefore the initalization
and unitialization logic has
Since those stucts are identical at the moment, this patch basically
does s/vboxGlobalData \*data/vboxPrivate *data/ with type casts in
vboxDriverLock/Unlock calls to keep the code working and take care of
unavoidable diff noise to set the stage for further commits that
actually address the issue
be squashed into 3 as it was kept separate
only for code-review purposes and 3rd patch won't compile without 4
applied on top.
[1] https://www.redhat.com/archives/libvirt-users/2012-April/msg00122.html
[2] https://www.redhat.com/archives/libvirt-users/2012-April/msg00125.htmlgq
Dawid Zamirski (4
To be passed as per-connection context info instead of using
vboxGlobalData that it will eventually replace in most cases.
---
src/vbox/vbox_uniformed_api.h | 30 ++
1 file changed, 30 insertions(+)
diff --git a/src/vbox/vbox_uniformed_api.h
On Wed, 2016-09-28 at 13:41 -0400, Dawid Zamirski wrote:
> This patch series solves (at least in my testing) vbox driver
> thread-safety issues that were also outlined on libvirt-users ML [1]
> and I was affected with.
Just to give a more practical context on the issue I'm trying
With VBox 5.1.x release new SDK header needs to be added to libvirt
sources. Sending as attachments due to the size of the first patch
being a large header file taken from VBOX SDK.
Dawid Zamirski (2):
vbox: add vbox 5.1 C API header file.
vbox: hookup the 5.1 C API to the unified driver
simply follow the same pattern as other versions did.
---
src/Makefile.am | 1 +
src/vbox/vbox_V5_1.c | 13 +
src/vbox/vbox_common.h| 2 ++
src/vbox/vbox_storage.c | 2 ++
src/vbox/vbox_tmpl.c | 2 ++
src/vbox/vbox_uniformed_api.h |
* add vboxDriver object to serve as a singleton global object that
holds references to IVirtualBox and ISession to be shared among
multiple connections. The vbox_driver is instantiated only once in
the first call vboxGetDriverConnection function that is guarded by
a mutex.
* call vbox API
ion starts a new thread, so I guess this is
not doeable right now :-/
[1] https://www.redhat.com/archives/libvir-list/2016-September/msg01306.html
[2]
https://github.com/mdaniel/virtualbox-org-svn-vbox-trunk/blob/master/src/VBox/Main/glue/initterm.cpp#L376
Dawid Zamirski (2):
vbox: change ho
On Mon, 2016-11-07 at 15:16 -0600, Eric Blake wrote:
> On 11/07/2016 03:03 PM, Dawid Zamirski wrote:
> >
> > extracted from VirutalBox SDK and reindented with cppi.
> > ---
> > src/vbox/vbox_CAPI_v5_1.h | 26117
> > ++
now that we have a new global vboxDriver object, remove the old
vboxGlobalData struct and all references to it.
---
src/vbox/vbox_common.c| 168 +--
src/vbox/vbox_common.h| 2 +-
src/vbox/vbox_network.c | 24 +--
src/vbox/vbox_storage.c | 20 +--
On Wed, 2016-11-23 at 11:00 -0500, Dawid Zamirski wrote:
> On Wed, 2016-11-23 at 08:55 -0500, John Ferlan wrote:
> > [...]
> > > +
> > > +static vboxDriverPtr
> > > +vboxGetDriverConnection(void)
> > > +{
> > > +virMutex
On Wed, 2016-11-23 at 08:55 -0500, John Ferlan wrote:
> [...]
> > +
> > +static vboxDriverPtr
> > +vboxGetDriverConnection(void)
> > +{
> > +virMutexLock(_driver_lock);
> > +
> > +if (vbox_driver) {
> > +virObjectRef(vbox_driver);
> > +} else {
> > +vbox_driver =
On Wed, 2016-11-23 at 14:00 +, Daniel P. Berrange wrote:
> On Wed, Nov 23, 2016 at 08:55:03AM -0500, John Ferlan wrote:
> > Beyond that - both patches seem fine Given recent discussion
> > about
> > removing an older Xen driver from libvirt:
> >
> >
On Wed, 2016-11-23 at 11:53 -0500, John Ferlan wrote:
>
> On 11/23/2016 11:48 AM, Dawid Zamirski wrote:
>
> Seems our responses crossed paths... Maybe it'd be best to send a
> v3...
>
> A couple of other nits I noted were the 2nd-4th arguments to
> virClassNew
> for
On Wed, 2016-11-23 at 11:33 -0500, Dawid Zamirski wrote:
> On Wed, 2016-11-23 at 11:00 -0500, Dawid Zamirski wrote:
> > On Wed, 2016-11-23 at 08:55 -0500, John Ferlan wrote:
> > > [...]
> > > > +
> > > > +static vboxDrive
now that we have a new global vboxDriver object, remove the old
vboxGlobalData struct and all references to it.
---
src/vbox/vbox_common.c| 168 +--
src/vbox/vbox_common.h| 2 +-
src/vbox/vbox_network.c | 24 +--
src/vbox/vbox_storage.c | 20 +--
libvir-list/2016-November/msg01132.html
Dawid Zamirski (2):
vbox: change how vbox API is initialized.
vbox: get rid of g_pVBoxGlobalData
src/vbox/vbox_common.c| 565 +++---
src/vbox/vbox_common.h| 2 +-
src/vbox/vbox_driver.c|
* add vboxDriver object to serve as a singleton global object that
holds references to IVirtualBox and ISession to be shared among
multiple connections. The vbox_driver is instantiated only once in
the first call vboxGetDriverConnection function that is guarded by
a mutex.
* call vbox API
On Fri, 2016-11-18 at 11:16 -0500, Dawid Zamirski wrote:
>
> Hi Andrea,
>
> Sure, in this case those patches simply enable support of VirtualBox
> 5.1.x series in libvirt (prior to that libvirt supported vbox 2.x.x
> to
> 5.0.x)- and as such it does not affect any previous v
On Fri, 2016-11-18 at 16:47 +0100, Andrea Bolognani wrote:
> Would you mind drafting one or two short sentences to describe
> the impact of these changes for users? If everything goes
> according to plans[1], they will be added to the NEWS file.
>
> Thanks!
>
>
> [1] Which it often doesn't :)
>
Sorry, forgot to CC the ML in my last reply.
Forwarded Message
From: Dawid Zamirski <dzamir...@datto.com>
To: Martin Kletzander <mklet...@redhat.com>
Subject: Re: [libvirt] [PATCH 2/4] vbox: replace vboxGlobalData with
vboxPrivate.
Date: Tue, 11 Oct 2016 10:43:23 -
On Tue, 2016-10-11 at 16:22 +0200, Martin Kletzander wrote:
> On Wed, Sep 28, 2016 at 01:41:35PM -0400, Dawid Zamirski wrote:
>
> The allocation is not guarded by any lock, so there's still a
> race. I
> think there should be a global struct that has only some lock in it
> and
On Tue, 2016-10-11 at 16:22 +0200, Martin Kletzander wrote:
> On Wed, Sep 28, 2016 at 01:41:35PM -0400, Dawid Zamirski wrote:
> >
> > * _pfnUnitilalize decrements connectionCount in g_pVBoxGlobalData
> > and
> > once it is down to 0, it calls pfnComUnitialize and
>
On Tue, 2016-10-11 at 10:58 -0400, Dawid Zamirski wrote:
> On Tue, 2016-10-11 at 16:22 +0200, Martin Kletzander wrote:
> > On Wed, Sep 28, 2016 at 01:41:35PM -0400, Dawid Zamirski wrote:
> >
>
> > I don't understand how vbox works, but if initializing
> > g_pVBoxGl
On Thu, 2016-10-13 at 12:04 +0200, Martin Kletzander wrote:
> On Wed, Oct 12, 2016 at 04:00:52PM -0400, Dawid Zamirski wrote:
> >
> > So after my initial attempts at handling this as suggested (create
> > vboxDriver struct and initialize in VIR_ONCE_GLOBAL_INIT), I
On Tue, 2016-10-11 at 10:58 -0400, Dawid Zamirski wrote:
> On Tue, 2016-10-11 at 16:22 +0200, Martin Kletzander wrote:
> > On Wed, Sep 28, 2016 at 01:41:35PM -0400, Dawid Zamirski wrote:
> >
> > The allocation is not guarded by any lock, so there's still a
> > race
On Tue, 2017-01-10 at 11:50 -0500, John Ferlan wrote:
>
> Seems reasonable - it builds for me ;-). I did take a cursory scan
> through the changes - they all seem valid.
>
> ACK series and can push everything before the release once/if the
> news
> patches series on list can come to a
ML
message size limit.
[1] https://www.redhat.com/archives/libvir-list/2016-November/msg01133.html
Regards,
Dawid
Dawid Zamirski (12):
vbox: remove SDK header files for vbox 3 and older.
vbox: remove calls to *InstallUniformedAPI macros.
vbox: remove code for old API versions.
vbox
This removes most of the code wrapped in VBOX_API_VERSION < 400
preprocessor checks. Those are the ones that can be safely removed
without needing to update driver code to accomodate it.
---
src/vbox/vbox_tmpl.c | 1390 +++---
1 file changed, 57
* the getMachineForSession is always true for 4.0+. This also means that
checkflag argument in openSessionForMachine no longer has any meaning
because it was or'ed with getMachineForSession (always true)
* remove supportScreenshot flag - vbox 4.0+ supports it
* remove detachDevicesExplicitly
* removed oldMediumInterface flag and related code that was used for
vbox 2.x
* remove accelerate2DVideo and networkRemoveInterface flags which were
also conditionals for handling legacy vbox versions.
---
src/vbox/vbox_common.c| 66 --
This function was not implemented for vbox 5+ which removed
TakeScreenShotPNGToArray but provides TakeScreenShotToArray with
BitmapFormat_PNG argument which is the same thing.
---
src/vbox/vbox_tmpl.c | 23 +++
1 file changed, 11 insertions(+), 12 deletions(-)
diff --git
VirtualBox 4.0+ uses IMedium and IHardDisk is no longer used, so
* remove typef IMedium IHardDisk
* merge UIHardDisk into UIMedium
* update all references accordingly
---
src/vbox/vbox_common.h| 1 -
src/vbox/vbox_storage.c | 32 +++
src/vbox/vbox_tmpl.c | 91
this was implemented only for vbox 3 series and was mostly stubs
anyway.
---
src/vbox/vbox_common.c| 20 --
src/vbox/vbox_tmpl.c | 648 --
src/vbox/vbox_uniformed_api.h | 22 +-
3 files changed, 2 insertions(+), 688 deletions(-)
diff
and fold vboxAttachDrivesNew into vboxAttachDrives
---
src/vbox/vbox_common.c| 45 +---
src/vbox/vbox_tmpl.c | 487 --
src/vbox/vbox_uniformed_api.h | 1 -
3 files changed, 1 insertion(+), 532 deletions(-)
diff --git
That is, for versions older than 4.0. Also do not try to include
headers for those old versions.
---
src/vbox/vbox_common.h| 10 +-
src/vbox/vbox_storage.c | 10 +-
src/vbox/vbox_uniformed_api.h | 4
3 files changed, 2 insertions(+), 22 deletions(-)
diff --git
---
docs/news.html.in | 8
1 file changed, 8 insertions(+)
diff --git a/docs/news.html.in b/docs/news.html.in
index e544cfa..2c01f00 100644
--- a/docs/news.html.in
+++ b/docs/news.html.in
@@ -53,6 +53,14 @@
Add a display of the physical size of a disk
volume in the
The patch itself is attached as compressed archive due to its size.
* delete SDK header files for vbox older than 4.0
* delete .c files for vbox older than 4.0
* update vbox_XPCOMCGlue to use oldest supported header file, that is 4.0
going forward.
* remove deleted files from Makefile.am
---
* remove _vboxIID_v2_x and _vboxIID_v3_x structs and repalce with one
_vboxIID as all supprted vbox versions have the same IID structure.
* remove vboxIIDUnion that was used to abstract version depended IID
differences.
* remove IID_MEMBER macro and use the new vboxIID directly.
---
The IVRDxServer was used because vbox < 4 used to have IVRDPServer
whereas vbox >= 4 has IVRDEServer. Now that support for legacy
versions is being removed, we can use IVRDEServer.
---
src/vbox/vbox_common.c| 36 +--
src/vbox/vbox_common.h| 2 +-
This patch updates the code generator that outputs C headers and code
for WMI classes. It has been updated to handle multiple versions (or
namespaces) of the same class which were introduced with Hyperv 2012+
---
changes in v2:
* make it pass "make syntax-check"
that is: s/hyperyVerifyresponse/hypervVerifyResponse/
---
src/hyperv/hyperv_wmi.c | 8
src/hyperv/hyperv_wmi.h | 2 +-
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/hyperv/hyperv_wmi.c b/src/hyperv/hyperv_wmi.c
index 13acd09..947101f 100644
---
This function detects hyperv version by issuing a simple query using
"v2" namespace and falling back to "v1".
---
src/hyperv/hyperv_driver.c | 92 --
1 file changed, 56 insertions(+), 36 deletions(-)
diff --git a/src/hyperv/hyperv_driver.c
This patch updates the code generator that outputs C headers and code
for WMI classes. It has been updated to handle multiple versions (or
namespaces) of the same class which were introduced with Hyperv 2012+
---
src/hyperv/hyperv_wmi_generator.py | 409 +
1
This enables this function to handle "v1" and "v2" WMI requests.
Since this commit is where complilation breakage starts:
* commits that follow should be squashed into this one
* rename hypervObjectUnified -> hypervObject as we've already broken
compilation here so there's no point in keeping
Those used to be auto-generated and are hand-written now intead. The
reason being that those are not very useful and better replacements are
in order once the driver itself implements more of the API and common
patterns start to emerge.
---
src/Makefile.am | 2 -
d */
goto cleanup;
}
/* works with v1 and v2 */
char *vmName = list->data.common->Name;
/* access property that is in v2 only */
if (priv->wmiVersion == HYPERV_WMI_VERSION_V2)
char *foo = list->data.v2->V2Property;
else
char *foo = list-&
This struct is to be passed to enumerate-and-pull wsman request (to run
"Select" queries) and provides the hypervWmiClassInfoListPtr instance
from which we can extract the version specific info using the new
hypervGetWmiClassInfo function (currently unused)
---
src/hyperv/hyperv_wmi.c | 35
On Thu, 2017-03-30 at 12:47 -0400, Dawid Zamirski wrote:
> Hello,
>
> The following patch series reworks the hyper-v driver structs and the
> code generator to provide seamless support for both Hyper-V 2008 and
> 2012 or newer. This does not implement any new libvirt APIs, i
Hyper-V 2012+ uses a new "v2" version of Msvm_* WMI classes so we will
store that info in hypervPrivate so that it is easily accessbile in the
driver API callbacks and handled accordingly.
---
src/hyperv/hyperv_private.h | 8 +++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git
Adds defintiions for "v2" WMI class variants that are needed by the
driver to handle both hyperv 2008 and 2012+
---
src/hyperv/hyperv_wmi_generator.input | 239 +-
1 file changed, 206 insertions(+), 33 deletions(-)
diff --git
basically s/data->/data.common->/
Because the data member of hypervObject is a union, get the data via
the "common" member everywhere - existing driver does not require
special handling for v1 vs v2 separately.
---
src/hyperv/hyperv_driver.c | 76 +++---
This struct is to be used to carry all the information necessary to
issue wsman requests for given WMI class. Those will be defined by the
generator code (as lists) so that they are handy for the driver code to
"extract" needed info depending on which hyper-v we're connected to.
For example:
Currently named as hypervObjecUnified to keep code
compilable/functional until all bits are in place.
This struct is a result of unserializing WMI request response.
Therefore, it needs to be able to deal with different "versions" of the
same WMI class. To accomplish this, the "data" member was
On Thu, 2017-03-30 at 16:24 -0400, Dawid Zamirski wrote:
> On Thu, 2017-03-30 at 16:07 -0400, Neal Gompa wrote:
> > On Thu, Mar 30, 2017 at 2:00 PM, Dawid Zamirski <dzamir...@datto.co
> > m>
> >
> > > b/src/hyperv/hyperv_wmi_generator.py
> > > old m
This patch updates the code generator that outputs C headers and code
for WMI classes. It has been updated to handle multiple versions (or
namespaces) of the same class which were introduced with Hyperv 2012+
---
changes in v3:
* do not change file mode
* restore accidentally deleted copyright
1 - 100 of 267 matches
Mail list logo