Subject: spontaneous reboot only once after power-up
To: None <port-dreamcast@netbsd.org>
From: ITOH Yasufumi <itohy@netbsd.org>
List: port-dreamcast
Date: 10/29/2002 23:29:39
  Hello,

I have almost finished the Male Bus driver,
and am working on some peripheral drivers.
I'd like to commit some of them.

However, I have a weird problem.
The kernel reboot at the context switching (tsleep(), kthread_create1()),
only once after power-up.
Load the kernel again, and it works without problems.

The problem is rather difficult to reproduce.
If the kernel size changes (by adding debug print, adding another function,
change the optimization option from -O1 to -O2, etc),
the problem may disappear.

I'm puzzled....
I suspect this is caused by using uninitialized memory somewhere,
but I can't find one in maple driver.
The problem is always on kthread_create1() or tsleep(),
and any problem in context switching code?
Why does it occur only once?

I use IP slave to load a kernel.
On my Dreamcast, this kernel reboots itself after detecting BbA
(rtk0 and ukphy0) only once after power-up.

ftp://ftp.netbsd.org/pub/NetBSD/misc/itohy/dreamcast/netbsd.test.gz

My current working source is based on cvs update at Oct 27 (~0 GMT)
plus following difference.

ftp://ftp.netbsd.org/pub/NetBSD/misc/itohy/dreamcast/sys_arch_dreamcast-20021029.tar.gz

Regards,
-- 
ITOH Yasufumi