It's by design - I am of the religion that thinks that
free(malloc());
is always legal, even when the malloc() fails.
> Is it worthwhile to clean this up, or do other places in the code rely
> on this behavior of free_page?
There might be any number of places who just free a page, it doesn't even
slow down free_page(), because the 0 case just falls out quite naturally
from having to test for out-of-range and reserved pages anyway.
Linus
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/