All of lore.kernel.org
 help / color / mirror / Atom feed
From: Greg Ungerer <gerg@snapgear.com>
To: David Howells <dhowells@redhat.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: BUG: failure at mm/nommu.c:518/add_nommu_region()
Date: Wed, 06 May 2009 12:00:03 +1000	[thread overview]
Message-ID: <4A00EF23.4050302@snapgear.com> (raw)
In-Reply-To: <3662.1241530861@redhat.com>

Hi David,

David Howells wrote:
> Greg Ungerer <gerg@snapgear.com> wrote:
> 
>> BUG: failure at mm/nommu.c:518/add_nommu_region()!
> 
> Can you find out some more information about the region in question, perhaps
> with the attached patch?

Yep, last part of the boot log now:

...
uclinux[mtd]: RAM probe address=0x168fc0 size=0xd7000
Creating 1 MTD partitions on "RAM":
0x000000000000-0x0000000d7000 : "ROMfs"
TCP cubic registered
NET: Registered protocol family 17
VFS: Mounted root (romfs filesystem) readonly on device 31:0.
Freeing unused kernel memory: 44k freed (0x152000 - 0x15c000)
___ REGION ERROR ___
18b790-191db0
fs=romfs file=init
BUG: failure at mm/nommu.c:532/add_nommu_region()!
Kernel panic - not syncing: BUG!


> Also if you can check to see whether the region is within the ROMFS image.

Yes, it is. As per the uclinux/mtd trace output (at top of trace
above). The start physical address of the ROMFS is 0x168fc0, and
it will end at 0x23ffc0.

Regards
Greg




> David
> ---
> diff --git a/mm/nommu.c b/mm/nommu.c
> index cdc6f60..ba9e230 100644
> --- a/mm/nommu.c
> +++ b/mm/nommu.c
> @@ -515,7 +515,18 @@ static void add_nommu_region(struct vm_region *region)
>  
>  	validate_nommu_regions();
>  
> -	BUG_ON(region->vm_start & ~PAGE_MASK);
> +	if (region->vm_start & ~PAGE_MASK) {
> +		printk(KERN_ERR "___ REGION ERROR ___\n");
> +		printk(KERN_ERR "%lx-%lx\n", region->vm_start, region->vm_end);
> +		printk(KERN_ERR "fs=%s file=%s\n",
> +		       region->vm_file ?
> +		       region->vm_file->f_path.dentry->d_inode->i_sb->s_type->name :
> +		       "*anon*",
> +		       region->vm_file ?
> +		       region->vm_file->f_path.dentry->d_name.name :
> +		       (const unsigned char *) "*anon*");
> +		BUG();
> +	}
>  
>  	parent = NULL;
>  	p = &nommu_region_tree.rb_node;
> 

-- 
------------------------------------------------------------------------
Greg Ungerer  --  Principal Engineer        EMAIL:     gerg@snapgear.com
SnapGear Group, McAfee                      PHONE:       +61 7 3435 2888
825 Stanley St,                             FAX:         +61 7 3891 3630
Woolloongabba, QLD, 4102, Australia         WEB: http://www.SnapGear.com

  reply	other threads:[~2009-05-06  2:00 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-05  1:30 BUG: failure at mm/nommu.c:518/add_nommu_region() Greg Ungerer
2009-05-05 13:41 ` David Howells
2009-05-06  2:00   ` Greg Ungerer [this message]
2009-05-06 11:21     ` David Howells
2009-05-06 14:11     ` David Howells
2009-05-07  0:13       ` Greg Ungerer
2009-05-07  8:38         ` David Howells
2009-05-07  8:45           ` Greg Ungerer

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=4A00EF23.4050302@snapgear.com \
    --to=gerg@snapgear.com \
    --cc=dhowells@redhat.com \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.