>> >>> + >>> + if (mapping) { >>> + /* >>> + * uniform split has xas_split_alloc() called before >>> + * irq is disabled, since xas_nomem() might not be >>> + * able to allocate enough memory. >>> + */ >>> + if (uniform_split) >>> + xas_split(xas, folio, old_order); >>> + else { >>> + xas_set_order(xas, folio->index, split_order); >>> + xas_set_err(xas, -ENOMEM); >>> + if (xas_nomem(xas, 0)) >> >> 0 gfp? > > This is inside lru_lock and allocation cannot sleep, so I am not sure > current_gfp_context(mapping_gfp_mask(mapping) & GFP_RECLAIM_MASK); can > be used. > > I need Matthew to help me out about this. Talked to Matthew about this, will use GFP_NOWAIT here, since we can fail here and probably should not get into atomic reserves. Best Regards, Yan, Zi