diff options
author | Marco Stornelli <marco.stornelli@gmail.com> | 2012-01-13 01:20:58 (GMT) |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-01-13 04:13:13 (GMT) |
commit | fdb5950754eb3dedb9fea7c8828d3e51d9dbc3f7 (patch) | |
tree | 57d9804de982ab233c2fe2c553466a12387e1866 | |
parent | 028ee4be34a09a6d48bdf30ab991ae933a7bc036 (diff) | |
download | linux-fdb5950754eb3dedb9fea7c8828d3e51d9dbc3f7.tar.xz |
ramoops: fix use of rounddown_pow_of_two()
The return value of rounddown_pow_of_two wasn't evaluated, so the
operation was a no-op.
Signed-off-by: Marco Stornelli <marco.stornelli@gmail.com>
Reported-by: Andrew Morton <akpm@linux-foundation.org>
Reviewed-by: WANG Cong <xiyou.wangcong@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | drivers/char/ramoops.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/char/ramoops.c b/drivers/char/ramoops.c index feda90c..9c152ab 100644 --- a/drivers/char/ramoops.c +++ b/drivers/char/ramoops.c @@ -125,8 +125,8 @@ static int __init ramoops_probe(struct platform_device *pdev) goto fail3; } - rounddown_pow_of_two(pdata->mem_size); - rounddown_pow_of_two(pdata->record_size); + pdata->mem_size = rounddown_pow_of_two(pdata->mem_size); + pdata->record_size = rounddown_pow_of_two(pdata->record_size); /* Check for the minimum memory size */ if (pdata->mem_size < MIN_MEM_SIZE && |