From 671d16fbbd9ed66b34e8d908d5d0713c06815b52 Mon Sep 17 00:00:00 2001 From: Christoph Lameter Date: Fri, 15 Feb 2008 23:45:24 -0800 Subject: [PATCH] --- yaml --- r: 86679 b: refs/heads/master c: e153362a50a34439718a938a851bba977116e19a h: refs/heads/master i: 86677: 76919e006a08d6bdf1e4277e4fa7d4c4f64851b4 86675: fac7b3110658c924fa287850b1ef53e3dc180d7b 86671: 9e9cf737268cbdfd99135cd893e3b8358907ad1b v: v3 --- [refs] | 2 +- trunk/mm/slub.c | 27 ++++----------------------- 2 files changed, 5 insertions(+), 24 deletions(-) diff --git a/[refs] b/[refs] index 96419994f1fe..fc2a135b5693 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: d9acf4b7b62d783d84273a61aed41a0f025b08ac +refs/heads/master: e153362a50a34439718a938a851bba977116e19a diff --git a/trunk/mm/slub.c b/trunk/mm/slub.c index e01d399894c4..d7d0d866b6b2 100644 --- a/trunk/mm/slub.c +++ b/trunk/mm/slub.c @@ -997,30 +997,11 @@ static unsigned long kmem_cache_flags(unsigned long objsize, void (*ctor)(struct kmem_cache *, void *)) { /* - * The page->offset field is only 16 bit wide. This is an offset - * in units of words from the beginning of an object. If the slab - * size is bigger then we cannot move the free pointer behind the - * object anymore. - * - * On 32 bit platforms the limit is 256k. On 64bit platforms - * the limit is 512k. - * - * Debugging or ctor may create a need to move the free - * pointer. Fail if this happens. + * Enable debugging if selected on the kernel commandline. */ - if (objsize >= 65535 * sizeof(void *)) { - BUG_ON(flags & (SLAB_RED_ZONE | SLAB_POISON | - SLAB_STORE_USER | SLAB_DESTROY_BY_RCU)); - BUG_ON(ctor); - } else { - /* - * Enable debugging if selected on the kernel commandline. - */ - if (slub_debug && (!slub_debug_slabs || - strncmp(slub_debug_slabs, name, - strlen(slub_debug_slabs)) == 0)) - flags |= slub_debug; - } + if (slub_debug && (!slub_debug_slabs || + strncmp(slub_debug_slabs, name, strlen(slub_debug_slabs)) == 0)) + flags |= slub_debug; return flags; }