forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-12-19 9370bb92b2d16684ee45cf24e879c93c509162da
kernel/arch/sh/kernel/cpu/sh4/sq.c
....@@ -1,3 +1,4 @@
1
+// SPDX-License-Identifier: GPL-2.0
12 /*
23 * arch/sh/kernel/cpu/sh4/sq.c
34 *
....@@ -5,10 +6,6 @@
56 *
67 * Copyright (C) 2001 - 2006 Paul Mundt
78 * Copyright (C) 2001, 2002 M. R. Brown
8
- *
9
- * This file is subject to the terms and conditions of the GNU General Public
10
- * License. See the file "COPYING" in the main directory of this archive
11
- * for more details.
129 */
1310 #include <linux/init.h>
1411 #include <linux/cpu.h>
....@@ -106,7 +103,8 @@
106103 #if defined(CONFIG_MMU)
107104 struct vm_struct *vma;
108105
109
- vma = __get_vm_area(map->size, VM_ALLOC, map->sq_addr, SQ_ADDRMAX);
106
+ vma = __get_vm_area_caller(map->size, VM_ALLOC, map->sq_addr,
107
+ SQ_ADDRMAX, __builtin_return_address(0));
110108 if (!vma)
111109 return -ENOMEM;
112110
....@@ -383,7 +381,7 @@
383381 if (unlikely(!sq_cache))
384382 return ret;
385383
386
- sq_bitmap = kzalloc(size, GFP_KERNEL);
384
+ sq_bitmap = kcalloc(size, sizeof(long), GFP_KERNEL);
387385 if (unlikely(!sq_bitmap))
388386 goto out;
389387