diff mbox

arm64: mm: remove unnecessary BUG_ON

Message ID 1467252124-19625-1-git-send-email-wangkefeng.wang@huawei.com
State Accepted
Commit 6c5269f33e96722f3e20dc694fba636cc1d4b3eb
Headers show

Commit Message

Kefeng Wang June 30, 2016, 2:02 a.m. UTC
The memblock_alloc() and memblock_alloc_base() will panic on their own
if no free memory, remove pointless BUG_ON.

Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com>

---
 arch/arm64/mm/mmu.c | 1 -
 1 file changed, 1 deletion(-)

-- 
2.6.0.GIT


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

Comments

Mark Rutland June 30, 2016, 3:50 p.m. UTC | #1
On Thu, Jun 30, 2016 at 10:02:04AM +0800, Kefeng Wang wrote:
> The memblock_alloc() and memblock_alloc_base() will panic on their own

> if no free memory, remove pointless BUG_ON.

> 

> Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com>


For some reason I thought we'd already removed this. FWIW:

Acked-by: Mark Rutland <mark.rutland@arm.com>


I believe it's up to Catalin to pick this up.

Mark.

> ---

>  arch/arm64/mm/mmu.c | 1 -

>  1 file changed, 1 deletion(-)

> 

> diff --git a/arch/arm64/mm/mmu.c b/arch/arm64/mm/mmu.c

> index 0f85a46..d120abc 100644

> --- a/arch/arm64/mm/mmu.c

> +++ b/arch/arm64/mm/mmu.c

> @@ -77,7 +77,6 @@ static phys_addr_t __init early_pgtable_alloc(void)

>  	void *ptr;

>  

>  	phys = memblock_alloc(PAGE_SIZE, PAGE_SIZE);

> -	BUG_ON(!phys);

>  

>  	/*

>  	 * The FIX_{PGD,PUD,PMD} slots may be in active use, but the FIX_PTE

> -- 

> 2.6.0.GIT

> 


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Catalin Marinas June 30, 2016, 4:55 p.m. UTC | #2
On Thu, Jun 30, 2016 at 10:02:04AM +0800, Kefeng Wang wrote:
> The memblock_alloc() and memblock_alloc_base() will panic on their own

> if no free memory, remove pointless BUG_ON.

> 

> Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com>


Applied. Thanks.

-- 
Catalin

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
diff mbox

Patch

diff --git a/arch/arm64/mm/mmu.c b/arch/arm64/mm/mmu.c
index 0f85a46..d120abc 100644
--- a/arch/arm64/mm/mmu.c
+++ b/arch/arm64/mm/mmu.c
@@ -77,7 +77,6 @@  static phys_addr_t __init early_pgtable_alloc(void)
 	void *ptr;
 
 	phys = memblock_alloc(PAGE_SIZE, PAGE_SIZE);
-	BUG_ON(!phys);
 
 	/*
 	 * The FIX_{PGD,PUD,PMD} slots may be in active use, but the FIX_PTE