Re: [PATCH 4/5] mm: make vmg->target consistent and further simplify commit_merge()

From: Vlastimil Babka
Date: Wed Jan 29 2025 - 10:20:03 EST


On 1/27/25 16:50, Lorenzo Stoakes wrote:
> + if (flags & __VMG_FLAG_REMOVE_MIDDLE) {
> + *remove = vmg->middle;
> + remove = &vp->remove2;
> + }
> + if (flags & __VMG_FLAG_REMOVE_NEXT)
> + *remove = vmg->next;
> +
> + if (flags & __VMG_FLAG_ADJUST_MIDDLE_START)
> + adjust = vmg->middle;
> + else if (flags & __VMG_FLAG_ADJUST_NEXT_START)
> + adjust = vmg->next;
> + else
> + adjust = NULL;
> +
> + vp->adj_next = adjust;

Realized this has kinda made it more obvious that vp->adj_next is a misnomer?