Re: [PATCH RFC] mm/memory_hotplug: Introduce memory block types

2018-09-28 Thread Dave Hansen
It's really nice if these kinds of things are broken up. First, replace the old want_memblock parameter, then add the parameter to the __add_page() calls. > +/* > + * NONE: No memory block is to be created (e.g. device memory). > + * NORMAL: Memory block that represents normal (boot or hotp

Re: [PATCH RFC] mm/memory_hotplug: Introduce memory block types

2018-10-01 Thread Dave Hansen
> How should a policy in user space look like when new memory gets added > - on s390x? Not onlining paravirtualized memory is very wrong. Because we're going to balloon it away in a moment anyway? We have auto-onlining. Why isn't that being used on s390? > So the type of memory is very importa

Re: [PATCH RFC] mm/memory_hotplug: Introduce memory block types

2018-10-03 Thread Dave Hansen
On 10/03/2018 06:52 AM, Vitaly Kuznetsov wrote: > It is more than just memmaps (e.g. forking udev process doing memory > onlining also needs memory) but yes, the main idea is to make the > onlining synchronous with hotplug. That's a good theoretical concern. But, is it a problem we need to solve

Re: [PATCH RFC PKS/PMEM 22/58] fs/f2fs: Utilize new kmap_thread()

2020-10-12 Thread Dave Hansen
On 10/12/20 9:19 AM, Eric Biggers wrote: > On Sun, Oct 11, 2020 at 11:56:35PM -0700, Ira Weiny wrote: >>> And I still don't really understand. After this patchset, there is still >>> code >>> nearly identical to the above (doing a temporary mapping just for a memcpy) >>> that >>> would still be

Re: [PATCH] staging: lustre: fix GFP_ATOMIC macro usage

2014-01-21 Thread Dave Hansen
On 01/21/2014 12:02 PM, Dilger, Andreas wrote: > The Lustre allocation macros track the memory usage across the whole > filesystem, > not just of a single structure that a mempool/slab/whatever would do. > This is > useful to know for debugging purposes (e.g. user complains about not having > enoug

[staging] unused rtl8192u/ieee80211/digest.c ?

2014-02-03 Thread Dave Hansen
I was doing some code audits looking at scattergather uses, and noticed that update() in drivers/staging/rtl8192u/ieee80211/digest.c uses sg.page which doesn't exist any longer, so this can't possibly compile. Turns out that digest.c is actually unused. It doesn't get referenced in a Makefile or

Re: [RFC 0/6] Module for tracking/accounting shared memory buffers

2016-10-12 Thread Dave Hansen
On 10/11/2016 04:50 PM, Ruchi Kandoi wrote: > Any process holding a reference to these buffers will keep the kernel from > reclaiming its backing pages. mm counters don't provide a complete picture of > these allocations, since they only account for pages that are mapped into a > process's address

Re: [PATCH V2] staging: android: lowmemorykiller: imporve lmk to avoid deadlock issue

2015-08-03 Thread Dave Hansen
On 08/02/2015 10:53 PM, Wang, Biao wrote: > Consider the following case: > Task A trigger lmk with a lock held, while task B try to > get this lock, but unfortunately B is the very culprit task lmk select to > kill. Then B will never be killed, and A will forever select B to kill. > Such dead lock

Re: [PATCH 1/1] Drivers: base: memory: Export symbols for onlining memory blocks

2013-07-23 Thread Dave Hansen
On 07/23/2013 07:52 AM, KY Srinivasan wrote: > The current scheme of involving user > level code to close this loop obviously does not perform well under high > memory pressure. Adding memory usually requires allocating some large, contiguous areas of memory for use as mem_map[] and other VM str

Re: [PATCH 1/1] Drivers: base: memory: Export symbols for onlining memory blocks

2013-07-23 Thread Dave Hansen
On 07/23/2013 08:54 AM, KY Srinivasan wrote: >> > Adding memory usually requires allocating some large, contiguous areas >> > of memory for use as mem_map[] and other VM structures. That's really >> > hard to do under heavy memory pressure. How are you accomplishing this? > I cannot avoid failure

Re: [PATCH 1/1] Drivers: base: memory: Export symbols for onlining memory blocks

2013-07-24 Thread Dave Hansen
On 07/23/2013 10:21 AM, KY Srinivasan wrote: >> You have allocated some large, physically contiguous areas of memory >> under heavy pressure. But you also contend that there is too much >> memory pressure to run a small userspace helper. Under heavy memory >> pressure, I'd expect large, kernel al

Re: [PATCH 1/1] Drivers: base: memory: Export symbols for onlining memory blocks

2013-07-24 Thread Dave Hansen
On 07/24/2013 12:45 PM, KY Srinivasan wrote: > All I am saying is that I see two classes of failures: (a) Our > inability to allocate memory to manage the memory that is being hot added > and (b) Our inability to bring the hot added memory online within a reasonable > amount of time. I am not sure

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

2013-07-24 Thread Dave Hansen
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 "onlin

Re: [PATCH 1/1] Drivers: base: memory: Export symbols for onlining memory blocks

2013-07-25 Thread Dave Hansen
On 07/25/2013 04:14 AM, KY Srinivasan wrote: > As promised, I have sent out the patches for (a) an implementation of an > in-kernel API > for onlining and a consumer for this API. While I don't know the exact > reason why the > user mode code is delayed (under some low memory conditions), what i

Re: [PATCH 1/1] Drivers: base: memory: Export symbols for onlining memory blocks

2013-07-25 Thread Dave Hansen
On 07/25/2013 08:15 AM, Kay Sievers wrote: > Complexity, well, it's just a bit of code which belongs in the kernel. > The mentioned unconditional hotplug loop through userspace is > absolutely pointless. Such defaults never belong in userspace tools if > they do not involve data that is only availa