Re: 2.5.70-bk4+: oops by mc -v /proc/bus/pci/00/00.0

Andrew Morton (akpm@digeo.com)
Sat, 31 May 2003 19:54:14 -0700


Alex Riesen <fork0@users.sourceforge.net> wrote:
>
> MC (Midnight Commander 4.6.0 Gentoo) segfaults trying to mmap files
> under /proc/bus/pci.

Thanks. This will fix it up.

It's pretty lame. Really we need a proper vma constructor
somewhere.

diff -puN mm/mmap.c~pci-mmap-fix mm/mmap.c
--- 25/mm/mmap.c~pci-mmap-fix 2003-05-31 19:49:20.000000000 -0700
+++ 25-akpm/mm/mmap.c 2003-05-31 19:49:35.000000000 -0700
@@ -677,6 +677,7 @@ munmap_back:
vma->vm_pgoff = pgoff;
vma->vm_file = NULL;
vma->vm_private_data = NULL;
+ vma->vm_next = NULL;
INIT_LIST_HEAD(&vma->shared);

if (file) {

_

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