lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 08 May 2009 18:42:21 +0300
From:	Pekka Enberg <penberg@...helsinki.fi>
To:	Christoph Lameter <cl@...ux-foundation.org>
Cc:	akpm@...ux-foundation.org, gorcunov@...nvz.org,
	kosaki.motohiro@...fujitsu.com, mel@....ul.ie, riel@...hat.com,
	linux-kernel@...r.kernel.org, mingo@...e.hu, rientjes@...gle.com
Subject: Re: [PATCH 2/2] SLUB: Use GFP_PANIC for early-boot allocations

On Fri, 2009-05-08 at 11:28 -0400, Christoph Lameter wrote:
> On Fri, 8 May 2009, Pekka Enberg wrote:
> 
> > This patch converts SLUB early-boot code to use GFP_PANIC instead of explicit
> > BUG_ON() calls.
> 
> Yirks this is not only early boot code. create_unique_id may be executed
> whenever a slab is created.

Updated patch here:

Subject: [PATCH 2/2] SLUB: Use GFP_PANIC for early-boot allocations
From: Pekka Enberg <penberg@...helsinki.fi>

This patch converts SLUB early-boot code to use GFP_PANIC instead of BUG_ON().

Signed-off-by: Pekka Enberg <penberg@...helsinki.fi>
---
 mm/slub.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/mm/slub.c b/mm/slub.c
index 7ab54ec..2cdf731 100644
--- a/mm/slub.c
+++ b/mm/slub.c
@@ -2109,9 +2109,8 @@ static void early_kmem_cache_node_alloc(gfp_t gfpflags, int node)
 
 	BUG_ON(kmalloc_caches->size < sizeof(struct kmem_cache_node));
 
-	page = new_slab(kmalloc_caches, gfpflags, node);
+	page = new_slab(kmalloc_caches, gfpflags | GFP_PANIC, node);
 
-	BUG_ON(!page);
 	if (page_to_nid(page) != node) {
 		printk(KERN_ERR "SLUB: Unable to allocate memory from "
 				"node %d\n", node);
-- 
1.5.6.3



--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ