Re: kernel BUG at mm/mmap.c:1990
Kyle McMartin <[email protected]>
| Newsgroups | gmane.linux.ports.hppa |
|---|---|
| Message-ID | <[email protected]> |
On Mon, Dec 11, 2006 at 11:38:13PM +0100, Helge Deller wrote:
> Maybe someone has an idea ?
>
> The "adjtimex02" test from the Linux Test Project (http://ltp.sf.net) seems to pass all test, but triggers a kernel BUG in mm/mmap.c:1990 when exiting.
> strace is attached below.
>
iirc this only bites on 32bit kernels.
This is what Jeff is referring to:
/*
* Testcase reduced from ltp, adjtimex02
*
* 1) adjtimex(2) fails with errno set to EFAULT if buf does
* not point to writable memory
*/
#include <stdio.h>
#include <unistd.h>
#include <sys/types.h>
#include <sys/timex.h>
int
main()
{
int x;
struct timex *buffp = (struct timex *) -1;
/* Check whether we are root */
if (geteuid() != 0) {
fprintf(stderr, "This needs to run as root.\n");
return(-1);
}
/* Call adjtimex(2) */
x = adjtimex(buffp);
return x;
}