|
@@ -3411,9 +3411,9 @@ static int __init d40_lcla_allocate(struct d40_base *base)
|
|
* To full fill this hardware requirement without wasting 256 kb
|
|
* To full fill this hardware requirement without wasting 256 kb
|
|
* we allocate pages until we get an aligned one.
|
|
* we allocate pages until we get an aligned one.
|
|
*/
|
|
*/
|
|
- page_list = kmalloc(sizeof(unsigned long) * MAX_LCLA_ALLOC_ATTEMPTS,
|
|
|
|
- GFP_KERNEL);
|
|
|
|
-
|
|
|
|
|
|
+ page_list = kmalloc_array(MAX_LCLA_ALLOC_ATTEMPTS,
|
|
|
|
+ sizeof(*page_list),
|
|
|
|
+ GFP_KERNEL);
|
|
if (!page_list) {
|
|
if (!page_list) {
|
|
ret = -ENOMEM;
|
|
ret = -ENOMEM;
|
|
goto failure;
|
|
goto failure;
|