File tree Expand file tree Collapse file tree 1 file changed +15
-3
lines changed Expand file tree Collapse file tree 1 file changed +15
-3
lines changed Original file line number Diff line number Diff line change @@ -203,7 +203,19 @@ void __init efi_init(void)
203
203
204
204
reserve_regions ();
205
205
early_memunmap (memmap .map , params .mmap_size );
206
- memblock_mark_nomap (params .mmap & PAGE_MASK ,
207
- PAGE_ALIGN (params .mmap_size +
208
- (params .mmap & ~PAGE_MASK )));
206
+
207
+ if (IS_ENABLED (CONFIG_ARM )) {
208
+ /*
209
+ * ARM currently does not allow ioremap_cache() to be called on
210
+ * memory regions that are covered by struct page. So remove the
211
+ * UEFI memory map from the linear mapping.
212
+ */
213
+ memblock_mark_nomap (params .mmap & PAGE_MASK ,
214
+ PAGE_ALIGN (params .mmap_size +
215
+ (params .mmap & ~PAGE_MASK )));
216
+ } else {
217
+ memblock_reserve (params .mmap & PAGE_MASK ,
218
+ PAGE_ALIGN (params .mmap_size +
219
+ (params .mmap & ~PAGE_MASK )));
220
+ }
209
221
}
You can’t perform that action at this time.
0 commit comments