Subject: Re: i386 - Cannot boot from wd(Promise Ultra100) with infinite
To: None <bouyer@antioche.eu.org>
From: NISHIO Yasuhiro <nishio@hh.iij4u.or.jp>
List: current-users
Date: 10/13/2003 15:40:40
Bouyer san,
Thank you for advice.

>When the kernel loops on intr, can you try to enter ddb, and get a
>stack trace for the atabus* threads ?
>ps will give you the PID of the threads, you can get the trace via
>trace/t 0t<pid>

Unfortunately, I cannot get ddb prompt when kernel loops on intr.
I use following kernel and console's break(~# key on tip command).

 - my custom build kernel that has ``options DDB''
	(kernel conf is pointed on my last mail)
 - releng.netbsd.org's GENERIC kernel(20030921, 0928).

Ofcourse, using bootable kernel, I can get it.
When the kernel loops on intr, I can do only reset the system.

I'm using serial console with tip command(~# for break). Is there any
difference between Serial console and PC console(VGA)?  If so, I'll try
to use PC console.

Following is my anothor try(boot with -d flag).

 - kernel conf
	GENERIC
	($NetBSD: GENERIC,v 1.575 2003/10/10 04:50:07 grog Exp $)
 - /etc/mk.conf
	(empty)
 - build method
	./build.sh -U kernel=GENERIC
	(build on NetBSD cerberus.bb.yhn.jp 1.6ZC NetBSD 1.6ZC (CERBERUS))
 - gcc -v
	gcc version 3.3.1
 - kernel source
	around 2003/Oct/13 03:00(UTC)
 - using -d boot flag

# nm /gennetbsd | egrep 'wdc.*intr'
c02dcdf8 T __wdccommand_intr
c050d164 T wdc_ata_bio_intr
c04f1d5c T wdc_atapi_intr
c02db2b2 T wdcintr

>> NetBSD/i386 BIOS Boot, Revision 2.12
>> (root@mercury.bb.yhn.jp, Thu Oct  3 13:58:04 JST 2002)
>> Memory: 634/523248 k
Press return to boot now, any other key for boot menu
booting hd0a:netbsd - starting in 0
type "?" or "help" for help.
> boot hd0a:gennetbsd -d
booting hd0a:gennetbsd (howto 0x40)
7843808+134724+406072 [380240+308202]=0x8a83ac
Stopped at      netbsd:breakpoint+0x4:  leave
db> break c02dcdf8
db> break c050d164 
db> break c04f1d5c
db> break c02db2b2
db> c
BIOS CFG: Model-SubM-Rev: fc-01-00, 0x70<KBDINT,RTC,IC2>
Copyright (c) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
    The NetBSD Foundation, Inc.  All rights reserved.
Copyright (c) 1982, 1986, 1989, 1991, 1993
    The Regents of the University of California.  All rights reserved.

	:
	
cbb1: interrupting at irq 5
cardslot1 at cbb1 slot 1 flags 0
cardbus1 at cardslot1: bus 0 device 0
pcmcia1 at cardslot1
fd0 at fdc0 drive 0: 1.44MB, 80 cyl, 2 head, 18 sec
Kernelized RAIDframe activated
Breakpoint in pid 4.1 (atabus0) at      netbsd:wdcintr: pushl   %ebp
db> c
pdcide0:0: bogus intr
Breakpoint in pid 4.1 (atabus0) at      netbsd:wdcintr: pushl   %ebp
db> c
pdcide0:1: bogus intr
Breakpoint in pid 4.1 (atabus0) at      netbsd:wdcintr: pushl   %ebp
db> c
pdcide0:0: bogus intr
Breakpoint in pid 4.1 (atabus0) at      netbsd:wdcintr: pushl   %ebp
db> c
pdcide0:1: bogus intr
Breakpoint in pid 4.1 (atabus0) at      netbsd:wdcintr: pushl   %ebp
db> ps
 PID           PPID     PGRP        UID S   FLAGS LWPS          COMMAND    WAIT
 7                0        0          0 2 0x20200    1        cardslot1
 6                0        0          0 2 0x20200    1        cardslot0
 5                0        0          0 2 0x20200    1          atabus1
>4                0        0          0 2 0x20200    1          atabus0
 3                0        0          0 2 0x20200    1          usbtask  usbtsk
 2                0        0          0 2 0x20200    1             usb0  usbdly
 1                0        0          0 2       0    1             init initexe
 0               -1        0          0 2 0x20200    1          swapper  cfpend
db> trace/t 0t4
trace: pid 4 at 0x0
uvm_fault(0xc08e2b20, 0, 0, 1) -> 0xe
kernel: page fault trap, code=0
Faulted in DDB; continuing...
db> trace
wdcintr(c12024e4,c1200010,30,10,10) at netbsd:wdcintr
pdc20265_pci_intr(c1202400,4,c0100010,30,10) at netbsd:pdc20265_pci_intr+0xc7
Bad frame pointer: 0xc1206700
db> reboot
syncing disks... done
rebooting...
============================================================
Full log is at 

	http://www.hh.iij4u.or.jp/~nishio/netbsd/ddb/

	- gennetbsd.log (Full Log)
	- GENERIC.bz2 (bzip2ed kernel conf)
	- gennetbsd.bz2 (bzip2ed kernelf ile)

Thanks in advance.
-- 
NISHIO Yasuhiro