lkml.org 
[lkml]   [2020]   [Sep]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v3] mm: cma: indefinitely retry allocations in cma_alloc
On 2020-09-25 05:18, David Hildenbrand wrote:
> On 24.09.20 07:16, Chris Goldsworthy wrote:
>> - GFP_KERNEL | (no_warn ? __GFP_NOWARN : 0));
>> + GFP_KERNEL | (gfp_mask & __GFP_NOWARN));
>
> Right, we definetly don't want to pass the flag further down.
>
> Alternative would be cma_alloc_nofail(). That helps avoid people
> passing
> stuff like GFP_USER and wondering why it doesn't have an effect.

But since we're doing a logical AND with __GFP_NOWARN, we're not passing
any other values down - this makes it equivalent to the previous
version, in that only __GFP_NOWARN can be passed to
alloc_contig_range().

--
The Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora
Forum,
a Linux Foundation Collaborative Project

\
 
 \ /
  Last update: 2020-09-26 01:14    [W:0.063 / U:0.300 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site