Commit ed6e96c7 authored by Todd Poynor's avatar Todd Poynor Committed by Greg Kroah-Hartman

staging: gasket: remove unnecessary code in coherent allocator

Remove extraneous statement in gasket_config_coherent_allocator()
Reported-by: default avatarDmitry Torokhov <dtor@chromium.org>
Signed-off-by: default avatarZhongze Hu <frankhu@chromium.org>
Signed-off-by: default avatarTodd Poynor <toddpoynor@google.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent ae27b2f9
......@@ -420,10 +420,8 @@ static int gasket_config_coherent_allocator(
if (ibuf.page_table_index >= gasket_dev->num_page_tables)
return -EFAULT;
if (ibuf.size > PAGE_SIZE * MAX_NUM_COHERENT_PAGES) {
ibuf.size = PAGE_SIZE * MAX_NUM_COHERENT_PAGES;
if (ibuf.size > PAGE_SIZE * MAX_NUM_COHERENT_PAGES)
return -ENOMEM;
}
if (ibuf.enable == 0) {
ret = gasket_free_coherent_memory(
......
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