Skip to content

Commit 7e14059

Browse files
neuschaefermpe
authored andcommitted
powerpc/mm/32: Remove the reserved memory hack
This hack, introduced in commit c5df7f7 ("powerpc: allow ioremap within reserved memory regions") is now unnecessary. Signed-off-by: Jonathan Neuschäfer <[email protected]> Signed-off-by: Michael Ellerman <[email protected]>
1 parent 57deb8f commit 7e14059

File tree

3 files changed

+1
-8
lines changed

3 files changed

+1
-8
lines changed

arch/powerpc/mm/init_32.c

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -88,11 +88,6 @@ void MMU_init(void);
8888
int __map_without_bats;
8989
int __map_without_ltlbs;
9090

91-
/*
92-
* This tells the system to allow ioremapping memory marked as reserved.
93-
*/
94-
int __allow_ioremap_reserved;
95-
9691
/* max amount of low RAM to map in */
9792
unsigned long __max_low_memory = MAX_LOW_MEM;
9893

arch/powerpc/mm/mmu_decl.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,6 @@ extern void setbat(int index, unsigned long virt, phys_addr_t phys,
9898
unsigned int size, pgprot_t prot);
9999

100100
extern int __map_without_bats;
101-
extern int __allow_ioremap_reserved;
102101
extern unsigned int rtas_data, rtas_size;
103102

104103
struct hash_pte;

arch/powerpc/mm/pgtable_32.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -148,8 +148,7 @@ __ioremap_caller(phys_addr_t addr, unsigned long size, unsigned long flags,
148148
* mem_init() sets high_memory so only do the check after that.
149149
*/
150150
if (slab_is_available() && (p < virt_to_phys(high_memory)) &&
151-
page_is_ram(__phys_to_pfn(p)) &&
152-
!(__allow_ioremap_reserved && memblock_is_region_reserved(p, size))) {
151+
page_is_ram(__phys_to_pfn(p))) {
153152
printk("__ioremap(): phys addr 0x%llx is RAM lr %ps\n",
154153
(unsigned long long)p, __builtin_return_address(0));
155154
return NULL;

0 commit comments

Comments
 (0)