[PATCH 6/8] Pmalloc selftest
Igor Stoppa
igor.stoppa at huawei.com
Sun Mar 25 01:32:57 UTC 2018
On 14/03/18 14:25, Matthew Wilcox wrote:
> On Tue, Mar 13, 2018 at 11:45:52PM +0200, Igor Stoppa wrote:
>> Add basic self-test functionality for pmalloc.
>
> Here're some additional tests for your test-suite:
>
> for (i = 1; i; i *= 2)
> pzalloc(pool, i - 1, GFP_KERNEL);
>
Ok, I have almost finished the rewrite.
I still have to address this comment.
When I run the test, eventually the system runs out of memory, it keeps
getting allocation errors from vmalloc, until i finally overflows and
becomes 0.
Am I supposed to do something about it?
If pmalloc receives a request that the vmalloc backend cannot satisfy, I
would prefer that vmalloc itself produces the warning and pmalloc
returns NULL.
This doesn't look like a test case that one can leave always enabled in
a build, but maybe I'm missing the point.
--
igor
--
To unsubscribe from this list: send the line "unsubscribe linux-security-module" in
the body of a message to majordomo at vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
More information about the Linux-security-module-archive
mailing list