> > We call it from atomic context, so we can not sleep, also we do not have > > any existing context coming from the caller. I see that GFP_ATOMIC is high-level > > flag and is differ from __GFP_ATOMIC. It is defined as: > > > > #define GFP_ATOMIC (__GFP_HIGH|__GFP_ATOMIC|__GFP_KSWAPD_RECLAIM) > > > > so basically we would like to have __GFP_KSWAPD_RECLAIM that is included in it, > > because it will also help in case of high memory pressure and wake-up kswapd to > > reclaim memory. > > > > We also can extract: > > > > __GFP_ATOMIC | __GFP_HIGH | __GFP_RETRY_MAYFAIL | __GFP_KSWAPD_RECLAIM > > > > but that is longer then > > > > GFP_ATMOC | __GFP_RETRY_MAYFAIL > > OK, if you are always in the atomic context then GFP_ATOMIC is > sufficient. __GFP_RETRY_MAYFAIL will make no difference for allocations > which do not reclaim (and thus not retry). Sorry this was not clear to > me from the previous description. > Ahh. OK. Then adding __GFP_RETRY_MAYFAIL to GFP_ATOMIC will not make any effect. Thank you for your explanation! -- Vlad Rezki