Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 23 Mar 2002 13:37:49 +0100
From:      Matthias Schuendehuette <msch@snafu.de>
To:        freebsd-stable@freebsd.org
Subject:   Re: ATA-tags broken on STABLE (long!)
Message-ID:  <E16okmL-00021L-00@smart.eusc.inter.net>

next in thread | raw e-mail | index | archive | help
Well, same (kernel-panic with hw.ata.tags="1") for me:

...
atapci0: <VIA 82C686 ATA100 controller> port 0xd000-0xd00f at device \
	7.1 on pci0
atapci0: Correcting VIA config for southbridge data corruption bug
ata0: at 0x1f0 irq 14 on atapci0
ata1: at 0x170 irq 15 on atapci0
...
ad0: 43979MB <IBM-DTLA-307045> [89355/16/63] at ata0-master UDMA100

I fired up 'gdb' according to the developers handbook on the 
vmcore-file. Here's the log of the session:

************************************************************

root@mscu - /usr/obj/usr/src/sys/MSCU

502 # gdb -k kernel.debug /var/crash/vmcore.5
GNU gdb 4.18
Copyright 1998 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and 
you are
welcome to change it and/or distribute copies of it under certain 
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for 
details.
This GDB was configured as "i386-unknown-freebsd"...
IdlePTD at phsyical address 0x004e2000
initial pcb at physical address 0x0034c9a0
panicstr: page fault
panic messages:
---
Fatal trap 12: page fault while in kernel mode
fault virtual address	= 0x70
fault code		= supervisor read, page not present
instruction pointer	= 0x8:0xc0185730
stack pointer	        = 0x10:0xc030585c
frame pointer	        = 0x10:0xc0305880
code segment		= base 0x0, limit 0xfffff, type 0x1b
			= DPL 0, pres 1, def32 1, gran 1
processor eflags	= interrupt enabled, resume, IOPL = 0
current process		= Idle
interrupt mask		= net tty bio cam 
trap number		= 12
panic: page fault

syncing disks... 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 
giving up on 1 buffers
Uptime: 16s

dumping to dev #da/0x20001, offset 262272
dump 255 254 253 252 251 250 249 248 247 246 245 244 243 242 241 240 
239 238 237 236 235 234 233 232 231 230 229 228 227 226 225 224 223 222 
221 220 219 218 217 216 215 214 213 212 211 210 209 208 207 206 205 204 
203 202 201 200 199 198 197 196 195 194 193 192 191 190 189 188 187 186 
185 184 183 182 181 180 179 178 177 176 175 174 173 172 171 170 169 168 
167 166 165 164 163 162 161 160 159 158 157 156 155 154 153 152 151 150 
149 148 147 146 145 144 143 142 141 140 139 138 137 136 135 134 133 132 
131 130 129 128 127 126 125 124 123 122 121 120 119 118 117 116 115 114 
113 112 111 110 109 108 107 106 105 104 103 102 101 100 99 98 97 96 95 
94 93 92 91 90 89 88 87 86 85 84 83 82 81 80 79 78 77 76 75 74 73 72 71 
70 69 68 67 66 65 64 63 62 61 60 59 58 57 56 55 54 53 52 51 50 49 48 47 
46 45 44 43 42 41 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 
22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 
---
#0  dumpsys () at /usr/src/sys/kern/kern_shutdown.c:487
487		if (dumping++) {
(kgdb) where
#0  dumpsys () at /usr/src/sys/kern/kern_shutdown.c:487
#1  0xc01826ff in boot (howto=256) at 
/usr/src/sys/kern/kern_shutdown.c:316
#2  0xc0182b24 in poweroff_wait (junk=0xc02faccc, howto=-1070618641)
    at /usr/src/sys/kern/kern_shutdown.c:595
#3  0xc02a4936 in trap_fatal (frame=0xc030581c, eva=112)
    at /usr/src/sys/i386/i386/trap.c:966
#4  0xc02a4609 in trap_pfault (frame=0xc030581c, usermode=0, eva=112)
    at /usr/src/sys/i386/i386/trap.c:859
#5  0xc02a41f3 in trap (frame={tf_fs = 16, tf_es = 16, tf_ds = 16,
	tf_edi = 0, tf_esi = -1055602944, tf_ebp = -1070573440,
	tf_isp = -1070573496, tf_ebx = 0, tf_edx = 1014, tf_ecx = -1055641088,
	tf_eax = 4194304, tf_trapno = 12, tf_err = 0, tf_eip = -1072146640,
	tf_cs = 8, tf_eflags = 66118, tf_esp = 496, tf_ss = -1055602900})
    at /usr/src/sys/i386/i386/trap.c:458
#6  0xc0185730 in tsleep (ident=0xc114c700, priority=16, 
    wmesg=0xc02c5c46 "atacmd", timo=1000) at
	/usr/src/sys/kern/kern_synch.c:436
#7  0xc0136b9d in ata_command
	(atadev=0xc114c72c, command=236 'ì', lba=0, count=0, feature=0,
	flags=2) at /usr/src/sys/dev/ata/ata-all.c:1048
#8  0xc01356b7 in ata_getparam (atadev=0xc114c72c, command=236)
    at /usr/src/sys/dev/ata/ata-all.c:428
#9  0xc013637e in ata_reinit (ch=0xc114c700)
    at /usr/src/sys/dev/ata/ata-all.c:845
#10 0xc013e2ba in ad_timeout (request=0xc11d2600)
    at /usr/src/sys/dev/ata/ata-disk.c:893
#11 0xc018858d in softclock () at /usr/src/sys/kern/kern_timeout.c:131
(kgdb) up 7
#7  0xc0136b9d in ata_command (atadev=0xc114c72c, command=236 'ì',
	lba=0, count=0, feature=0, flags=2) at
	/usr/src/sys/dev/ata/ata-all.c:1048
(kgdb) list
1043	
1044		/* enable interrupt */
1045		if (atadev->channel->flags & ATA_QUEUED)
1046		    ATA_OUTB(atadev->channel->r_altio, ATA_ALTSTAT, ATA_A_4BIT);
1047	
1048		if (tsleep((caddr_t)atadev->channel, PRIBIO, "atacmd", 10 * hz)) 
{
1049		    ata_prtdev(atadev, "timeout waiting for interrupt\n");
1050		    atadev->channel->active &= ~ATA_WAIT_INTR;
1051		    error = -1;
1052		}
(kgdb) up
#8  0xc01356b7 in ata_getparam (atadev=0xc114c72c, command=236)
    at /usr/src/sys/dev/ata/ata-all.c:428
(kgdb) list
423	    struct ata_params *ata_parm;
424	    int retry = 0;
425	
426	    /* apparently some devices needs this repeated */
427	    do {
428		if (ata_command(atadev, command, 0, 0, 0, ATA_WAIT_INTR)) {
429		    ata_prtdev(atadev, "%s identify failed\n",
430			       command == ATA_C_ATAPI_IDENTIFY ? "ATAPI" : "ATA");
431		    return -1;
432		}
(kgdb) up
#9  0xc013637e in ata_reinit (ch=0xc114c700)
    at /usr/src/sys/dev/ata/ata-all.c:845
(kgdb) list
840		printf("\n");
841	#if NATADISK > 0
842	    if (newdev & ATA_ATA_MASTER && !ch->device[MASTER].driver)
843		ad_attach(&ch->device[MASTER]);
844	    else if (ch->devices & ATA_ATA_MASTER && \
			ch->device[MASTER].driver) {
845		ata_getparam(&ch->device[MASTER], ATA_C_ATA_IDENTIFY);
846		ad_reinit(&ch->device[MASTER]);
847	    }
848	    if (newdev & ATA_ATA_SLAVE && !ch->device[SLAVE].driver)
849		ad_attach(&ch->device[SLAVE]);
(kgdb) up
#10 0xc013e2ba in ad_timeout (request=0xc11d2600)
    at /usr/src/sys/dev/ata/ata-disk.c:893
(kgdb) list
888		request->bp->b_flags |= B_ERROR;
889		devstat_end_transaction_buf(&adp->stats, request->bp);
890		biodone(request->bp);
891		ad_free(request);
892	    }
893	    ata_reinit(adp->device->channel);
894	}
895	
896	void
897	ad_reinit(struct ata_device *atadev)
(kgdb) up
#11 0xc018858d in softclock () at /usr/src/sys/kern/kern_timeout.c:131
(kgdb) list
126					} else {
127						c->c_flags =
128						    (c->c_flags & ~CALLOUT_PENDING);
129					}
130					splx(s);
131					c_func(c_arg);
132					s = splhigh();
133					steps = 0;
134					c = nextsoftcheck;
135				}
(kgdb) quit

************************************************************

Hope that helps....
-- 
Ciao/BSD - Matthias

Matthias Schuendehuette	<msch@snafu.de>, Berlin (Germany)
Powered by FreeBSD 4.5-STABLE

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-stable" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E16okmL-00021L-00>