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:	Sat, 22 Dec 2007 14:37:27 +0100
From:	Ingo Molnar <mingo@...e.hu>
To:	Pekka J Enberg <penberg@...helsinki.fi>
Cc:	akpm@...ux-foundation.org, linux-kernel@...r.kernel.org,
	andi@...stfloor.org, clameter@....com, a.p.zijlstra@...llo.nl
Subject: Re: [PATCH] slub: /proc/slabinfo ABI compatibility


* Ingo Molnar <mingo@...e.hu> wrote:

> > From: Pekka Enberg <penberg@...helsinki.fi>
> > 
> > This adds a read-only /proc/slabinfo file that is ABI compatible with 
> > SLAB for SLUB.
> > 
> > Cc: Ingo Molnar <mingo@...e.hu>
> 
> Tested-by: Ingo Molnar <mingo@...e.hu>

Pekka, i stuck your patch into the x86.git random-test-grid, and it 
found the following build error after a few iterations:

  mm/slub.c: In function 's_show':
  mm/slub.c:4188: error: implicit declaration of function 'count_partial'

find the (tested) fix below.

	Ingo

----------------->
Subject: SLUB: build fix
From: Ingo Molnar <mingo@...e.hu>

fix:

 mm/slub.c: In function 's_show':
 mm/slub.c:4188: error: implicit declaration of function 'count_partial'

Signed-off-by: Ingo Molnar <mingo@...e.hu>
---
 mm/slub.c |   26 +++++++++++++-------------
 1 file changed, 13 insertions(+), 13 deletions(-)

Index: linux/mm/slub.c
===================================================================
--- linux.orig/mm/slub.c
+++ linux/mm/slub.c
@@ -3079,6 +3079,19 @@ void *__kmalloc_node_track_caller(size_t
 	return slab_alloc(s, gfpflags, node, caller);
 }
 
+static unsigned long count_partial(struct kmem_cache_node *n)
+{
+	unsigned long flags;
+	unsigned long x = 0;
+	struct page *page;
+
+	spin_lock_irqsave(&n->list_lock, flags);
+	list_for_each_entry(page, &n->partial, lru)
+		x += page->inuse;
+	spin_unlock_irqrestore(&n->list_lock, flags);
+	return x;
+}
+
 #if defined(CONFIG_SYSFS) && defined(CONFIG_SLUB_DEBUG)
 static int validate_slab(struct kmem_cache *s, struct page *page,
 						unsigned long *map)
@@ -3464,19 +3477,6 @@ static int list_locations(struct kmem_ca
 	return n;
 }
 
-static unsigned long count_partial(struct kmem_cache_node *n)
-{
-	unsigned long flags;
-	unsigned long x = 0;
-	struct page *page;
-
-	spin_lock_irqsave(&n->list_lock, flags);
-	list_for_each_entry(page, &n->partial, lru)
-		x += page->inuse;
-	spin_unlock_irqrestore(&n->list_lock, flags);
-	return x;
-}
-
 enum slab_stat_type {
 	SL_FULL,
 	SL_PARTIAL,
--
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