Commit 33f65df7 authored by Vegard Nossum's avatar Vegard Nossum

crypto: don't track xor test pages with kmemcheck

The xor tests are run on uninitialized data, because it is doesn't
really matter what the underlying data is. Annotate this false-
positive warning.
Acked-by: default avatarPekka Enberg <penberg@cs.helsinki.fi>
Signed-off-by: default avatarVegard Nossum <vegard.nossum@gmail.com>
parent c175eea4
...@@ -101,7 +101,12 @@ calibrate_xor_blocks(void) ...@@ -101,7 +101,12 @@ calibrate_xor_blocks(void)
void *b1, *b2; void *b1, *b2;
struct xor_block_template *f, *fastest; struct xor_block_template *f, *fastest;
b1 = (void *) __get_free_pages(GFP_KERNEL, 2); /*
* Note: Since the memory is not actually used for _anything_ but to
* test the XOR speed, we don't really want kmemcheck to warn about
* reading uninitialized bytes here.
*/
b1 = (void *) __get_free_pages(GFP_KERNEL | __GFP_NOTRACK, 2);
if (!b1) { if (!b1) {
printk(KERN_WARNING "xor: Yikes! No memory available.\n"); printk(KERN_WARNING "xor: Yikes! No memory available.\n");
return -ENOMEM; return -ENOMEM;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment