NetBSD-Bugs archive

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

Re: port-m68k/55990: kernel stack leak in m68k cpu_setmcontext() and reenter_syscall()



> It looks m68k/reenter_syscall.s adjusts stack pointer to prepare
> "moved stack frame by stkadj bytes" but doesn't restore %sp
> after syscall() is returned?
> (I'm not sure how reenter_syscall() was designed though)

After misc observations, these stack leaks seem caused by:
1) heavy setcontext(2) calls from pthread applications (i.e. Xorg server)
2) heavy address errors (i.e. page faults) on lower RAM (<24MB) environment

With this patch, I've been able to run a mac68k system with 10 megabytes of memory for many hours fully multiuser, whereas in the past it would freeze after just minutes or tens of minutes.

John Klos


Home | Main Index | Thread Index | Old Index