Google luky.org euqset.org

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 2.6.10-mm2: panic when munmap()ping the stack


On Mon, Jan 10, 2005 at 04:01:58PM -0800, Jeremy Fitzhardinge wrote:
> This program causes an instant panic for me:
>         #include <sys/mman.h>
>         int main(int argc, char **argv)
>         {
>         	munmap((char *)(((unsigned long)&argc) & ~4095), 4096*2);
>         
>         	return 0;
>         }
> I'm not sure if setting the signal handler is necessary or not.  My
> environment is largeish, so the stack is 2 pages; you might need to
> adjust it.
> There's a message on the console saying something like "panic: bad pgd:
> 0x00000e13".  It was a bit too quick to see.
> Plain 2.6.10 segfaults as expected; I haven't tried -mm1 to see what it
> does.
> Config attached.

$ grep -nr pgd_ERROR .
./arch/i386/kernel/vm86.c:151:          pgd_ERROR(*pgd);
./arch/arm/mm/fault-armv.c:67:  pgd_ERROR(*pgd);
./arch/sh/mm/init.c:94:         pgd_ERROR(*pgd);
./arch/m68k/atari/stram.c:679:          pgd_ERROR(*dir);
./arch/ppc64/mm/init.c:327:             pgd_ERROR(*dir);
./arch/parisc/kernel/pci-dma.c:206:             pgd_ERROR(*dir);
./arch/parisc/mm/kmap.c:116:            pgd_ERROR(*dir);
./mm/swapfile.c:530:            pgd_ERROR(*pgd);
./mm/msync.c:106:               pgd_ERROR(*pgd);
./mm/memory.c:162:              pgd_ERROR(*pgd);
./mm/memory.c:446:                      pgd_ERROR(*src_pgd);
./mm/memory.c:580:              pgd_ERROR(*pgd);
./mm/vmalloc.c:95:              pgd_ERROR(*pgd);
./mm/mprotect.c:100:            pgd_ERROR(*pgd);
(includes etc.)

Anyway, it's blatant pagetable corruption. Does binary searching -mm2
reveal anything?


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


$B$3$N>pJs$,$"$J$?$NC5$7$F$$?$b$N$+$I$&$+A*Br$7$F$/$@$5$!#(B
yes/$B$^$5$K$3$l$@!*(B   no/$B0c$&$J$!(B   part/$B0lIt8+$D$+$C$?(B   try/$B$3$l$G;n$7$F$_$k(B

$B$"$J$?$,C5$7$F$$?>pJs$O$I$N$h$&$J$3$H$+!"$4<+M3$K5-F~2<$5$!#FC$K!V$^$5$K$3$l$@!*!W$H8@$&>l9g$O5-F~$r$*4j$$7$^$9!#(B
$BNc(B:$B!VJ#?t$N%^%7%s$+$i(BCATV$B7PM3$G(Bipmasquerade$B$rMxMQ$7$F(BWeb$B$r;2>H$7$?$>l9g$N@_Dj$K$D$$F!W(B
References: