Re: [PATCH v2 1/4] lib/rhashtable: simplify bucket_table_alloc()

2018-06-25 Thread Michal Hocko
On Fri 22-06-18 11:15:40, Davidlohr Bueso wrote: > As of ce91f6ee5b3 (mm: kvmalloc does not fallback to vmalloc for incompatible > gfp flag), > we can simplify the caller and trust kvzalloc() to just do the right thing. > For the > case of the GFP_ATOMIC context, we can drop the __GFP_NORETRY

Re: [PATCH v2 1/4] lib/rhashtable: simplify bucket_table_alloc()

2018-06-25 Thread Michal Hocko
On Fri 22-06-18 11:15:40, Davidlohr Bueso wrote: > As of ce91f6ee5b3 (mm: kvmalloc does not fallback to vmalloc for incompatible > gfp flag), > we can simplify the caller and trust kvzalloc() to just do the right thing. > For the > case of the GFP_ATOMIC context, we can drop the __GFP_NORETRY

Re: [PATCH v2 1/4] lib/rhashtable: simplify bucket_table_alloc()

2018-06-22 Thread Davidlohr Bueso
On Fri, 22 Jun 2018, Davidlohr Bueso wrote: This slightly changes the gfp flags passed on to nested_table_alloc() as it will now also use GFP_ATOMIC | __GFP_NOWARN. However, I consider this a positive consequence as for the same reasons we want nowarn semantics in bucket_table_alloc(). If

Re: [PATCH v2 1/4] lib/rhashtable: simplify bucket_table_alloc()

2018-06-22 Thread Davidlohr Bueso
On Fri, 22 Jun 2018, Davidlohr Bueso wrote: This slightly changes the gfp flags passed on to nested_table_alloc() as it will now also use GFP_ATOMIC | __GFP_NOWARN. However, I consider this a positive consequence as for the same reasons we want nowarn semantics in bucket_table_alloc(). If

Re: [PATCH v2 1/4] lib/rhashtable: simplify bucket_table_alloc()

2018-06-22 Thread Davidlohr Bueso
Cc'ing Neil. On Fri, 22 Jun 2018, Davidlohr Bueso wrote: As of ce91f6ee5b3 (mm: kvmalloc does not fallback to vmalloc for incompatible gfp flag), we can simplify the caller and trust kvzalloc() to just do the right thing. For the case of the GFP_ATOMIC context, we can drop the __GFP_NORETRY

Re: [PATCH v2 1/4] lib/rhashtable: simplify bucket_table_alloc()

2018-06-22 Thread Davidlohr Bueso
Cc'ing Neil. On Fri, 22 Jun 2018, Davidlohr Bueso wrote: As of ce91f6ee5b3 (mm: kvmalloc does not fallback to vmalloc for incompatible gfp flag), we can simplify the caller and trust kvzalloc() to just do the right thing. For the case of the GFP_ATOMIC context, we can drop the __GFP_NORETRY

[PATCH v2 1/4] lib/rhashtable: simplify bucket_table_alloc()

2018-06-22 Thread Davidlohr Bueso
As of ce91f6ee5b3 (mm: kvmalloc does not fallback to vmalloc for incompatible gfp flag), we can simplify the caller and trust kvzalloc() to just do the right thing. For the case of the GFP_ATOMIC context, we can drop the __GFP_NORETRY flag for obvious reasons, and for the __GFP_NOWARN case,

[PATCH v2 1/4] lib/rhashtable: simplify bucket_table_alloc()

2018-06-22 Thread Davidlohr Bueso
As of ce91f6ee5b3 (mm: kvmalloc does not fallback to vmalloc for incompatible gfp flag), we can simplify the caller and trust kvzalloc() to just do the right thing. For the case of the GFP_ATOMIC context, we can drop the __GFP_NORETRY flag for obvious reasons, and for the __GFP_NOWARN case,