diff options
Diffstat (limited to 'litmus')
-rw-r--r-- | litmus/color.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/litmus/color.c b/litmus/color.c index 2a942d22a676..c3e2a1072360 100644 --- a/litmus/color.c +++ b/litmus/color.c | |||
@@ -69,10 +69,13 @@ static int __init init_color(void) | |||
69 | MPRINT("Cache size: %lu line-size: %lu ways: %lu sets: %lu\n", | 69 | MPRINT("Cache size: %lu line-size: %lu ways: %lu sets: %lu\n", |
70 | color_cache_info.size, color_cache_info.line_size, | 70 | color_cache_info.size, color_cache_info.line_size, |
71 | color_cache_info.ways, color_cache_info.sets); | 71 | color_cache_info.ways, color_cache_info.sets); |
72 | if (!color_cache_info.size){ | ||
73 | printk(KERN_WARNING "No cache information found.\n"); | ||
74 | return -EINVAL; | ||
75 | } | ||
72 | BUG_ON(color_cache_info.size <= 1048576 || | 76 | BUG_ON(color_cache_info.size <= 1048576 || |
73 | color_cache_info.ways < 15 || | 77 | color_cache_info.ways < 15 || |
74 | color_cache_info.line_size != 64 || | 78 | color_cache_info.line_size != 64); |
75 | color_cache_info.sets < 4096); | ||
76 | setup_mask(); | 79 | setup_mask(); |
77 | return init_color_lists(); | 80 | return init_color_lists(); |
78 | } | 81 | } |