lkml.org 
[lkml]   [2013]   [Jul]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    SubjectRE: [PATCH 1/1] Drivers: base: memory: Export symbols for onlining memory blocks
    Date


    > -----Original Message-----
    > From: Michal Hocko [mailto:mhocko@suse.cz]
    > Sent: Monday, July 22, 2013 8:37 AM
    > To: KY Srinivasan
    > Cc: gregkh@linuxfoundation.org; linux-kernel@vger.kernel.org;
    > devel@linuxdriverproject.org; olaf@aepfle.de; apw@canonical.com;
    > andi@firstfloor.org; akpm@linux-foundation.org; linux-mm@kvack.org;
    > kamezawa.hiroyuki@gmail.com; hannes@cmpxchg.org; yinghan@google.com;
    > jasowang@redhat.com; kay@vrfy.org
    > Subject: Re: [PATCH 1/1] Drivers: base: memory: Export symbols for onlining
    > memory blocks
    >
    > On Fri 19-07-13 12:23:05, K. Y. Srinivasan wrote:
    > > The current machinery for hot-adding memory requires having udev
    > > rules to bring the memory segments online. Export the necessary functionality
    > > to to bring the memory segment online without involving user space code.
    >
    > Why? Who is going to use it and for what purpose?
    > If you need to do it from the kernel cannot you use usermod helper
    > thread?
    >
    > Besides that this is far from being complete. memory_block_change_state
    > seems to depend on device_hotplug_lock and find_memory_block is
    > currently called with mem_sysfs_mutex held. None of them is exported
    > AFAICS.

    You are right; not all of the required symbols are exported (yet). Let me answer your
    other questions first:

    The Hyper-V balloon driver can use this functionality. I have prototyped the in-kernel
    "onlining" of hot added memory without requiring any help from user level code that
    performs significantly better than having user level code involved in the hot add process.
    With this change, I am able to successfully hot-add and online the hot-added memory
    even under extreme memory pressure which is what you would want given that we are
    hot-adding memory to alleviate memory pressure. The current scheme of involving user
    level code to close this loop obviously does not perform well under high memory pressure.


    I can, if you prefer export all of the necessary functionality in one patch.


    Regards,

    K. Y




    \
     
     \ /
      Last update: 2013-07-23 17:41    [W:3.469 / U:0.804 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site