mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Vegard Nossum" <vegard.nossum@gmail.com>
To: "Johannes Weiner" <hannes@saeurebad.de>
Cc: "Linux Kernel Mailing List" <linux-kernel@vger.kernel.org>
Subject: Re: 9a2d43b: __alloc_bootmem_core(): zero-sized request
Date: Fri, 22 Aug 2008 21:54:07 +0200	[thread overview]
Message-ID: <19f34abd0808221254i5212c6c6g823060699adca16@mail.gmail.com> (raw)
In-Reply-To: <19f34abd0808221224s4674e5aaq34bd0a874dfba699@mail.gmail.com>

On Fri, Aug 22, 2008 at 9:24 PM, Vegard Nossum <vegard.nossum@gmail.com> wrote:
> Hi,
>
> I was trying out
>
> commit 9a2d43b7566caeeeb414aa628bc2759028897dbb
> Date:   Tue Jul 15 21:21:43 2008 +0200
>
> ..as part of the debugging of a different issue, but I got this:
>
> __alloc_bootmem_core(): zero-sized request
> ------------[ cut here ]------------
> kernel BUG at /uio/arkimedes/s29/vegardno/git-working/linux-2.6/mm/bootmem.c:247!
[...]

Don't know how much it helps, but I tried this patch:

diff --git a/mm/bootmem.c b/mm/bootmem.c
index 8d9f60e..56298cb 100644
--- a/mm/bootmem.c
+++ b/mm/bootmem.c
@@ -244,7 +244,7 @@ __alloc_bootmem_core(struct bootmem_data *bdata, unsigned lo
ng size,

        if (!size) {
                printk("__alloc_bootmem_core(): zero-sized request\n");
-               BUG();
+               return ZERO_SIZE_PTR;
        }
        BUG_ON(align & (align-1));

...and I got this (it was apparently a bad idea ;-)):

__alloc_bootmem_core(): zero-sized request
Dentry cache hash table entries: -2147483648 (order: -13, 0 bytes)
__alloc_bootmem_core(): zero-sized request
Inode-cache hash table entries: -2147483648 (o -13, 0 bytes)
Bad page state in process 'swapper'
page:000000f0 flags:0x00000000 mapping:00000000 mapcount:1 count:0
Trying to fix it up, but a reboot is needed
Backtrace:
Pid: 0, comm: swapper Not tainted 2.6.26-00014-g9a2d43b-dirty #36
 [<c01823b0>] bad_page+0x90/0xd0
 [<c018351b>] free_hot_cold_page+0x21b/0x230
 [<c018357a>] free_hot_page+0xa/0x10
 [<c01835ab>] __free_pages+0x2b/0x40
 [<c01849d2>] __free_pages_bootmem+0x82/0xa0
 [<c082baeb>] free_all_bootmem_core+0xfb/0x1d0
 [<c082bbcd>] free_all_bootmem+0xd/0x10
 [<c08268fa>] mem_init+0x7a/0x3a0
 [<c082e612>] ? inode_init_early+0x62/0xb0
 [<c082e408>] ? vfs_caches_init_early+0x18/0xb0
 [<c08159fa>] start_kernel+0x25a/0x390
 [<c0815180>] ? unknown_bootoption+0x0/0x210
 [<c0815008>] __init_begin+0x8/0x10
 =======================
list_add corruption. next->prev should be prev (0000000c), but was
00000000. (next=00000000).
------------[ cut here ]------------
kernel BUG at /uio/arkimedes/s29/vegardno/git-working/linux-2.6/lib/list_debug.c:27!


Vegard

-- 
"The animistic metaphor of the bug that maliciously sneaked in while
the programmer was not looking is intellectually dishonest as it
disguises that the error is the programmer's own creation."
	-- E. W. Dijkstra, EWD1036

  reply	other threads:[~2008-08-22 19:54 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-22 19:24 Vegard Nossum
2008-08-22 19:54 ` Vegard Nossum [this message]
2008-08-23  7:12 ` Johannes Weiner
2008-08-24  7:58   ` Vegard Nossum
2008-08-24  8:22     ` Yinghai Lu
2008-08-24  8:43       ` Vegard Nossum
2008-08-24  8:58         ` Yinghai Lu
2008-08-24  8:23     ` Vegard Nossum

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=19f34abd0808221254i5212c6c6g823060699adca16@mail.gmail.com \
    --to=vegard.nossum@gmail.com \
    --cc=hannes@saeurebad.de \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®