hc
2023-12-11 d2ccde1c8e90d38cee87a1b0309ad2827f3fd30d
kernel/drivers/firmware/memmap.c
....@@ -1,17 +1,8 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * linux/drivers/firmware/memmap.c
34 * Copyright (C) 2008 SUSE LINUX Products GmbH
45 * by Bernhard Walle <bernhard.walle@gmx.de>
5
- *
6
- * This program is free software; you can redistribute it and/or modify
7
- * it under the terms of the GNU General Public License v2.0 as published by
8
- * the Free Software Foundation
9
- *
10
- * This program is distributed in the hope that it will be useful,
11
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
- * GNU General Public License for more details.
14
- *
156 */
167
178 #include <linux/string.h>
....@@ -19,7 +10,7 @@
1910 #include <linux/kernel.h>
2011 #include <linux/module.h>
2112 #include <linux/types.h>
22
-#include <linux/bootmem.h>
13
+#include <linux/memblock.h>
2314 #include <linux/slab.h>
2415 #include <linux/mm.h>
2516
....@@ -333,7 +324,8 @@
333324 {
334325 struct firmware_map_entry *entry;
335326
336
- entry = memblock_virt_alloc(sizeof(struct firmware_map_entry), 0);
327
+ entry = memblock_alloc(sizeof(struct firmware_map_entry),
328
+ SMP_CACHE_BYTES);
337329 if (WARN_ON(!entry))
338330 return -ENOMEM;
339331