hc
2024-05-10 37f49e37ab4cb5d0bc4c60eb5c6d4dd57db767bb
kernel/arch/m68k/sun3/sun3dvma.c
....@@ -7,7 +7,7 @@
77 * Contains common routines for sun3/sun3x DVMA management.
88 */
99
10
-#include <linux/bootmem.h>
10
+#include <linux/memblock.h>
1111 #include <linux/init.h>
1212 #include <linux/module.h>
1313 #include <linux/kernel.h>
....@@ -16,7 +16,6 @@
1616 #include <linux/list.h>
1717
1818 #include <asm/page.h>
19
-#include <asm/pgtable.h>
2019 #include <asm/dvma.h>
2120
2221 #undef DVMA_DEBUG
....@@ -267,7 +266,11 @@
267266
268267 list_add(&(hole->list), &hole_list);
269268
270
- iommu_use = alloc_bootmem(IOMMU_TOTAL_ENTRIES * sizeof(unsigned long));
269
+ iommu_use = memblock_alloc(IOMMU_TOTAL_ENTRIES * sizeof(unsigned long),
270
+ SMP_CACHE_BYTES);
271
+ if (!iommu_use)
272
+ panic("%s: Failed to allocate %zu bytes\n", __func__,
273
+ IOMMU_TOTAL_ENTRIES * sizeof(unsigned long));
271274
272275 dvma_unmap_iommu(DVMA_START, DVMA_SIZE);
273276