On 06/09/11 22:31, Konrad Rzeszutek Wilk wrote:
> On Fri, Aug 19, 2011 at 03:57:17PM +0100, David Vrabel wrote:
>>
>> --- a/drivers/xen/balloon.c
>> +++ b/drivers/xen/balloon.c
>> @@ -557,15 +557,20 @@ EXPORT_SYMBOL(free_xenballooned_pages);
>>
>> static int __init balloon_init(void)
>> {
>> + domid_t domid = DOMID_SELF;
>> unsigned long pfn, extra_pfn_end;
>> struct page *page;
>> + int ret;
>
> long int?
int looks correct to me. From arch/x86/include/asm/xen/hypercall.h:
static inline int
HYPERVISOR_memory_op(unsigned int cmd, void *arg)
{
return _hypercall2(int, memory_op, cmd, arg);
}
>>
>> if (!xen_domain())
>> return -ENODEV;
>>
>> pr_info("xen/balloon: Initialising balloon driver.\n");
>>
>> - balloon_stats.current_pages = xen_pv_domain() ?
>> min(xen_start_info->nr_pages, max_pfn) : max_pfn;
>> + ret = HYPERVISOR_memory_op(XENMEM_current_reservation, &domid);
>> + if (ret < 0)
>> + return ret;
>> + balloon_stats.current_pages = ret;
>> balloon_stats.target_pages = balloon_stats.current_pages;
>> balloon_stats.balloon_low = 0;
>> balloon_stats.balloon_high = 0;
>> --
>> 1.7.2.5
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|