RE: [PATCH 2/2] Drivers: hv: balloon: Online the hot-added memory "in context"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




> -----Original Message-----
> From: Dave Hansen [mailto:dave@xxxxxxxx]
> Sent: Wednesday, July 24, 2013 5:04 PM
> To: KY Srinivasan
> Cc: gregkh@xxxxxxxxxxxxxxxxxxx; linux-kernel@xxxxxxxxxxxxxxx;
> devel@xxxxxxxxxxxxxxxxxxxxxx; olaf@xxxxxxxxx; apw@xxxxxxxxxxxxx;
> andi@xxxxxxxxxxxxxx; akpm@xxxxxxxxxxxxxxxxxxxx; linux-mm@xxxxxxxxx;
> kamezawa.hiroyuki@xxxxxxxxx; mhocko@xxxxxxx; hannes@xxxxxxxxxxx;
> yinghan@xxxxxxxxxx
> Subject: Re: [PATCH 2/2] Drivers: hv: balloon: Online the hot-added memory "in
> context"
> 
> On 07/24/2013 02:29 PM, K. Y. Srinivasan wrote:
> >  		/*
> > -		 * Wait for the memory block to be onlined.
> > -		 * Since the hot add has succeeded, it is ok to
> > -		 * proceed even if the pages in the hot added region
> > -		 * have not been "onlined" within the allowed time.
> > +		 * Before proceeding to hot add the next segment,
> > +		 * online the segment that has been hot added.
> >  		 */
> > -		wait_for_completion_timeout(&dm_device.ol_waitevent,
> 5*HZ);
> > +		online_memory_block(start_pfn);
> 
> Ahhhhh....  You've got a timeout in the code in order to tell the
> hypervisor that you were successfully able to add the memory?  The
> userspace addition code probably wasn't running within this timeout
> period.  right?

As I have always said, the onlining would not occur within a specified amount
of time (under some conditions). The timeout here is to ensure that we are able 
to online the memory before attempting to hot-add more memory. With the ability
to online memory from within the kernel, we don't need this timeout and the code is
much more predictable.

Regards,

K. Y



_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel




[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux