Re: [PATCH]: Remove PF_MEMDIE as it is redundant

Robert Love (rml@tech9.net)
08 Jan 2003 18:46:55 -0500


On Wed, 2003-01-08 at 18:49, Juan Quintela wrote:

> That is a nice theory, and I think that this could be true in the
> past, but in 2.4.2X, PF_MEMDIE only appears in the two places that I
> show, and it is completely redundant, look at the patch, we are just
> |-ing both PF_MEMALLOC and PF_MEMDIE and later we are &-ing against
> the or of the two. Use find & grep yourself if you don't believe me.

I realize this.

The issue is that PF_MEMALLOC can be _cleared_. In that case, if you
only set PF_MEMALLOC, that check can be false when we want it true. So
we need a flag that is more persistent.

PF_MEMDIE, which is not cleared on various allocation paths in the VM,
ensures that the check holds true for all OOM'ed tasks.

I thought the same as you, "hey this thing is worthless let us dump it",
and Rik and Andrew told me otherwise.

I am not saying you are wrong, though - I could be very wrong. But my
point is not what you say above; it is that the flag is needed because
just setting PF_MEMALLOC is insufficient since it can be unset.

Robert Love

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/