libxendevicemodel: initialise extent.pad to zero

The pad field needs to be zero as required by the hypervisor.

Instead of setting the pad separately, use C99 initialiser.

Signed-off-by: Wei Liu <wei.liu2@citrix.com>
Reviewed-by: Paul Durrant <paul.durrant@citrix.com>
This commit is contained in:
Wei Liu committed 2017-09-28 11:57:45 +01:00
1 parent 1c2ea5ee05
commit 71b7b4e0f5
1 file changed
+4 -4
+4 -4
View File
@@ -483,10 +483,10 @@ int xendevicemodel_modified_memory(
xendevicemodel_handle *dmod, domid_t domid, uint64_t first_pfn,
uint32_t nr)
{
struct xen_dm_op_modified_memory_extent extent;
extent.first_pfn = first_pfn;
extent.nr = nr;
struct xen_dm_op_modified_memory_extent extent = {
.first_pfn = first_pfn,
.nr = nr,
};
return xendevicemodel_modified_memory_bulk(dmod, domid, &extent, 1);
}
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.