Skip to contentSkip to conversation

iq81340mc: oops with SATA VIA

DISCUSSION Williams, Dan J 3 participants 5 messages Mar 7, 2007 1 message not in the archive

Subsystems (3)
lore
Share & tools
lore
#1 lore raw
In reply to a message not in the archive
Quoted 4 lines

From: Martin Michlmayr [mailto:[email protected]]
Sent: Monday, February 12, 2007 4:41 AM

* Williams, Dan J <[email protected]> [2007-02-07 17:43]:

Quoted 8 lines
Quoted 3 lines

The access to 0xfffb04a7 should be remapped to 0xfec604a7.

It looks like __io is not being called in your case.

It seems it's called, but it still fails:

sata_via 0000:00:01.0: routed to hard irq line 9
ata1: SATA max UDMA/133 cmd 0xFFFB04A0 ctl 0xFFFB04AA bmdma 0xFFFB0480

irq 25

Quoted 17 lines

__iop13xx_io: io_addr: 0xfffb04aa io_virt: fec604aa __iop13xx_io: io_addr: 0xfffb04a7 io_virt: fec604a7 Unhandled fault: imprecise external abort (0x406) at 0x005db000

Internal error: : 406 [#1]
Modules linked in:
CPU: 0
PC is at ata_check_status+0x34/0x3c
LR is at 0x60000093
pc : [<401e44e0>]    lr : [<60000093>]    Not tainted

sp : 40641da8 ip : 60000093 fp : 40641db4
r10: 4fc97be4 r9 : 00000019 r8 : 00000001
r7 : 4fcca400 r6 : 407142a4 r5 : 00000053 r4 : 407142a4 r3 : 403acfe0 r2 : 00000000 r1 : 60000093 r0 : fec604a7
Flags: nzCv IRQs off FIQs on Mode SVC_32 Segment kernel
Control: 400397F
Table: 00004018 DAC: 00000035
Process swapper (pid: 1, stack limit = 0x40640250)

Quoted 2 lines
Stack: (0x40641da8 to 0x40642000)

1da0: 40641dc8 40641db8 401e540c 401e44b8 407142a4

40641ddc

Quoted 1 line

1dc0: 40641dcc 401e5674 401e53cc 20000013 40641df0 40641de0 401e56cc

401e5638

Quoted 1 line

1de0: 00000001 40641e38 40641df4 401e01d0 401e56ac fffb04a0 fffb04aa

fffb0480

Quoted 1 line

1e00: 00000019 4fc97be0 4062e848 4062e800 00000000 4062e8ec 4062e800

40641e5a

Quoted 1 line

1e20: 4fcca400 4062e838 00000002 40641e84 40641e3c 401e82e8 401dffe0

4062e8b0

Quoted 1 line

1e40: 40641e60 40641e50 401721bc 4062e848 4062e800 40641e70 40f11e64

403bf1d8

Quoted 1 line

1e60: 4062e800 00000000 00000000 403e2784 40023444 4062e8ec 40641ea4

40641e88

Quoted 1 line

1e80: 4018403c 401e7f60 4062e848 4062e848 4fc253e0 403bf20c 40641ecc

40641ea8

Quoted 1 line

1ea0: 401a8c40 40183fe0 403bf20c 4062e848 4fc253e0 401a8e9c 40023444

40022f64

Quoted 1 line

1ec0: 40641ee8 40641ed0 401a8dac 401a8be4 4062e91c 4062e848 403bf20c

40641f00

Quoted 1 line

1ee0: 40641eec 401a8f80 401a8d20 00000000 40641f04 40641f2c 40641f04

401a80a4

Quoted 1 line

1f00: 401a8ea8 403b7140 403b7140 4062e890 403bf20c 403bf220 403b7040

00000000

Quoted 1 line

1f20: 40641f3c 40641f30 401a8af0 401a805c 40641f60 40641f40 401a8438

401a8adc

Quoted 1 line

1f40: 403bf20c 00000000 403bf20c 00000000 40023444 40641f74 40641f64

401a91a8

Quoted 1 line

1f60: 401a83d4 403bf1d8 40641f90 40641f78 40184218 401a9154 40022ed4

00000000

Quoted 1 line

1f80: 40640000 40641fa0 40641f94 4001db60 401841a8 40641ff4 40641fa4

400280a8

Quoted 1 line

1fa0: 4001db54 40641fb0 40028e04 4003b81c 00000000 00000000 4002802c

40041a54

Quoted 1 line

1fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000

00000000

Quoted 1 line

1fe0: 00000000 00000000 00000000 40641ff8 40041a54 40028038 00000000

00000000

Quoted 38 lines
Backtrace:
[<401e44ac>] (ata_check_status+0x0/0x3c) from [<401e540c>]
(ata_bmdma_freeze+0x4c/0x74)
[<401e53c0>] (ata_bmdma_freeze+0x0/0x74) from [<401e5674>]
(__ata_port_freeze+0x48/0x74)
 r4 = 407142A4
[<401e562c>] (__ata_port_freeze+0x0/0x74) from [<401e56cc>]
(ata_eh_freeze_port+0x2c/0x44)
 r4 = 20000013
[<401e56a0>] (ata_eh_freeze_port+0x0/0x44) from [<401e01d0>]
(ata_device_add+0x1fc/0x520)
 r4 = 00000001
[<401dffd4>] (ata_device_add+0x0/0x520) from [<401e82e8>]
(svia_init_one+0x394/0x4e4)
[<401e7f54>] (svia_init_one+0x0/0x4e4) from [<4018403c>]
(pci_device_probe+0x68/0x8c)
[<40183fd4>] (pci_device_probe+0x0/0x8c) from [<401a8c40>]
(really_probe+0x68/0x13c)
 r7 = 403BF20C  r6 = 4FC253E0  r5 = 4062E848  r4 = 4062E848
[<401a8bd8>] (really_probe+0x0/0x13c) from [<401a8dac>]
(driver_probe_device+0x98/0xc4)
[<401a8d14>] (driver_probe_device+0x0/0xc4) from [<401a8f80>]
(__driver_attach+0xe4/0xe8)
 r6 = 403BF20C  r5 = 4062E848  r4 = 4062E91C
[<401a8e9c>] (__driver_attach+0x0/0xe8) from [<401a80a4>]
(bus_for_each_dev+0x54/0x80)
 r5 = 40641F04  r4 = 00000000
[<401a8050>] (bus_for_each_dev+0x0/0x80) from [<401a8af0>]
(driver_attach+0x20/0x28)
 r7 = 00000000  r6 = 403B7040  r5 = 403BF220  r4 = 403BF20C
[<401a8ad0>] (driver_attach+0x0/0x28) from [<401a8438>]
(bus_add_driver+0x70/0x194)
[<401a83c8>] (bus_add_driver+0x0/0x194) from [<401a91a8>]
(driver_register+0x60/0x9c)
 r8 = 40023444  r7 = 00000000  r6 = 403BF20C  r5 = 00000000
 r4 = 403BF20C
[<401a9148>] (driver_register+0x0/0x9c) from [<40184218>]
(__pci_register_driver+0x7c/0xc4)
Quoted 9 lines
 r4 = 403BF1D8
[<4018419c>] (__pci_register_driver+0x0/0xc4) from [<4001db60>]
(svia_init+0x18/0x20)
 r6 = 40640000  r5 = 00000000  r4 = 40022ED4
[<4001db48>] (svia_init+0x0/0x20) from [<400280a8>] (init+0x7c/0x29c)
[<4002802c>] (init+0x0/0x29c) from [<40041a54>] (do_exit+0x0/0x888)
Code: e89da800 e5900050 ebf93cc8 e5d03000 (e20300ff)
 <0>Kernel panic - not syncing: Attempted to kill init!

Martin I am copying linux-ide because I am wondering if this issue is due to a case where the fact that iop13xx posts i/o writes is causing issues. On IA the driver would be stalled until an i/o write completed. On iop13xx the driver is free to continue running. Perhaps someone with more knowledge about the sata_via hardware can answer if this would be an issue, because everything thus far looks correct in the iop13xx code.

Quoted 3 lines

--
Martin Michlmayr
http://www.cyrius.com/

--
Dan

#2 lore raw
Quoted 6 lines

Martin I am copying linux-ide because I am wondering if this issue is due to a case where the fact that iop13xx posts i/o writes is causing issues. On IA the driver would be stalled until an i/o write completed. On iop13xx the driver is free to continue running. Perhaps someone with more knowledge about the sata_via hardware can answer if this would be an issue, because everything thus far looks correct in the iop13xx code.

outb/w/l and friends are required not to post. If you are using mmio operations then the MMIO ops code in libata does any posting of writes required and handles it properly. If you are emulating outb/w/l without avoiding posting then it wont work as with many other drivers.

Alan

#3 lore raw
Quoted 7 lines · Alan Cox
Quoted 6 lines

Martin I am copying linux-ide because I am wondering if this issue is due to a case where the fact that iop13xx posts i/o writes is causing issues. On IA the driver would be stalled until an i/o write completed. On iop13xx the driver is free to continue running. Perhaps someone with more knowledge about the sata_via hardware can answer if this would be an issue, because everything thus far looks correct in the iop13xx code.

Quoted 5 lines

outb/w/l and friends are required not to post. If you are using mmio operations then the MMIO ops code in libata does any posting of writes required and handles it properly. If you are emulating outb/w/l without avoiding posting then it wont work as with many other drivers.

I see... in this case the iop13xx board support code is indeed violating the delayed assumption.

Martin can you give the attached patch a try to see if it resolves the oops? It has only been compile tested. The patch spins the processor on the ATU outbound-queue-busy bit whenever out*() is called.

Quoted 1 line

Alan

Thanks for the help.

--
Dan

iop13xx: fix implementation of delayed pci i/o writes

From: Dan Williams <[email protected]>

iop13xx internally posts all write transactions including delayed transcations to the ATU-E and ATU-X busses. This causes a problem for devices and drivers that rely on delayed actions for software/hardware timing purposes. This patch prevents out[bwl] transactions from completing until the outbound transaction queue of the ATU is empty.

---

 arch/arm/mach-iop13xx/io.c        |  145 +++++++++++++++++++++++++++++++++++--
 include/asm-arm/arch-iop13xx/io.h |   63 +++++++++++++++-
 2 files changed, 198 insertions(+), 10 deletions(-)
arch/arm/mach-iop13xx/io.c +138 -7
index e79a1b6..d516878 100644
@@ -21,25 +21,156 @@
 #include <asm/hardware.h>
 #include <asm/io.h>
 
-void * __iomem __iop13xx_io(unsigned long io_addr)
+static int select_atu_for_io(unsigned long io_addr)
 {
-	void __iomem * io_virt;
-
 	switch (io_addr) {
 	case IOP13XX_PCIE_LOWER_IO_PA ... IOP13XX_PCIE_UPPER_IO_PA:
-		io_virt = (void *) IOP13XX_PCIE_IO_PHYS_TO_VIRT(io_addr);
+		return IOP13XX_INIT_ATU_ATUE;
 		break;
 	case IOP13XX_PCIX_LOWER_IO_PA ... IOP13XX_PCIX_UPPER_IO_PA:
-		io_virt = (void *) IOP13XX_PCIX_IO_PHYS_TO_VIRT(io_addr);
+		return IOP13XX_INIT_ATU_ATUX;
 		break;
-	default:
-		BUG();
 	}
 
+	return IOP13XX_INIT_ATU_NONE;	
+}
+
+static void wait_for_atue_outq(void)
+{
+	while (__raw_readl(IOP13XX_ATUE_PCSR) & (IOP13XX_ATUE_PCSR_OUT_Q_BUSY))
+		cpu_relax();
+}
+
+static void wait_for_atux_outq(void)
+{
+	while (__raw_readl(IOP13XX_ATUX_PCSR) & (IOP13XX_ATUX_PCSR_OUT_Q_BUSY))
+		cpu_relax();
+}
+
+void * __iomem __iop13xx_io(unsigned long io_addr)
+{
+	void __iomem * io_virt;
+	int atu = select_atu_for_io(io_addr);
+
+	if (atu == IOP13XX_INIT_ATU_ATUE)
+		io_virt = (void *) IOP13XX_PCIE_IO_PHYS_TO_VIRT(io_addr);
+	else if (atu == IOP13XX_INIT_ATU_ATUX)
+		io_virt = (void *) IOP13XX_PCIX_IO_PHYS_TO_VIRT(io_addr);
+	else
+		BUG();
+
 	return io_virt;
 }
 EXPORT_SYMBOL(__iop13xx_io);
 
+void __iop13xx_outb(u8 v, unsigned long io_addr)
+{
+	int atu = select_atu_for_io(io_addr);
+	void __iomem * io_virt;
+
+	if (atu == IOP13XX_INIT_ATU_ATUE) {
+		io_virt = (void *) IOP13XX_PCIE_IO_PHYS_TO_VIRT(io_addr);
+		__raw_writeb(v, io_virt);
+		wait_for_atue_outq();
+	} else if (atu == IOP13XX_INIT_ATU_ATUX) {
+		io_virt = (void *) IOP13XX_PCIX_IO_PHYS_TO_VIRT(io_addr);
+		__raw_writeb(v, io_virt);
+		wait_for_atux_outq();
+	} else
+		BUG();
+}
+EXPORT_SYMBOL(__iop13xx_outb);
+
+void __iop13xx_outw(u16 v, unsigned long io_addr)
+{
+	int atu = select_atu_for_io(io_addr);
+	void __iomem * io_virt;
+
+	if (atu == IOP13XX_INIT_ATU_ATUE) {
+		io_virt = (void *) IOP13XX_PCIE_IO_PHYS_TO_VIRT(io_addr);
+		__raw_writew(cpu_to_le16(v), io_virt);
+		wait_for_atue_outq();
+	} else if (atu == IOP13XX_INIT_ATU_ATUX) {
+		io_virt = (void *) IOP13XX_PCIX_IO_PHYS_TO_VIRT(io_addr);
+		__raw_writew(cpu_to_le16(v), io_virt);
+		wait_for_atux_outq();
+	} else
+		BUG();
+}
+EXPORT_SYMBOL(__iop13xx_outw);
+
+void __iop13xx_outl(u32 v, unsigned long io_addr)
+{
+	int atu = select_atu_for_io(io_addr);
+	void __iomem * io_virt;
+
+	if (atu == IOP13XX_INIT_ATU_ATUE) {
+		io_virt = (void *) IOP13XX_PCIE_IO_PHYS_TO_VIRT(io_addr);
+		__raw_writel(cpu_to_le32(v), io_virt);
+		wait_for_atue_outq();
+	} else if (atu == IOP13XX_INIT_ATU_ATUX) {
+		io_virt = (void *) IOP13XX_PCIX_IO_PHYS_TO_VIRT(io_addr);
+		__raw_writel(cpu_to_le32(v), io_virt);
+		wait_for_atux_outq();
+	} else
+		BUG();
+}
+EXPORT_SYMBOL(__iop13xx_outl);
+
+void __iop13xx_outsb(unsigned long io_addr, void *d, unsigned long l)
+{
+	int atu = select_atu_for_io(io_addr);
+	void __iomem * io_virt;
+
+	if (atu == IOP13XX_INIT_ATU_ATUE) {
+		io_virt = (void *) IOP13XX_PCIE_IO_PHYS_TO_VIRT(io_addr);
+		__raw_writesb(io_virt, d, l);
+		wait_for_atue_outq();
+	} else if (atu == IOP13XX_INIT_ATU_ATUX) {
+		io_virt = (void *) IOP13XX_PCIX_IO_PHYS_TO_VIRT(io_addr);
+		__raw_writesb(io_virt, d, l);
+		wait_for_atux_outq();
+	} else
+		BUG();
+}
+EXPORT_SYMBOL(__iop13xx_outsb);
+
+void __iop13xx_outsw(unsigned long io_addr, void *d, unsigned long l)
+{
+	int atu = select_atu_for_io(io_addr);
+	void __iomem * io_virt;
+
+	if (atu == IOP13XX_INIT_ATU_ATUE) {
+		io_virt = (void *) IOP13XX_PCIE_IO_PHYS_TO_VIRT(io_addr);
+		__raw_writesw(io_virt, d, l);
+		wait_for_atue_outq();
+	} else if (atu == IOP13XX_INIT_ATU_ATUX) {
+		io_virt = (void *) IOP13XX_PCIX_IO_PHYS_TO_VIRT(io_addr);
+		__raw_writesw(io_virt, d, l);
+		wait_for_atux_outq();
+	} else
+		BUG();
+}
+EXPORT_SYMBOL(__iop13xx_outsw);
+
+void __iop13xx_outsl(unsigned long io_addr, void *d, unsigned long l)
+{
+	int atu = select_atu_for_io(io_addr);
+	void __iomem * io_virt;
+
+	if (atu == IOP13XX_INIT_ATU_ATUE) {
+		io_virt = (void *) IOP13XX_PCIE_IO_PHYS_TO_VIRT(io_addr);
+		__raw_writesl(io_virt, d, l);
+		wait_for_atue_outq();
+	} else if (atu == IOP13XX_INIT_ATU_ATUX) {
+		io_virt = (void *) IOP13XX_PCIX_IO_PHYS_TO_VIRT(io_addr);
+		__raw_writesl(io_virt, d, l);
+		wait_for_atux_outq();
+	} else
+		BUG();
+}
+EXPORT_SYMBOL(__iop13xx_outsl);
+
 void * __iomem __iop13xx_ioremap(unsigned long cookie, size_t size,
 	unsigned long flags)
 {
include/asm-arm/arch-iop13xx/io.h +60 -3

76 lines not on this page · raw message

#4 lore raw
Quoted 3 lines · Dan Williams

Martin can you give the attached patch a try to see if it resolves the oops? It has only been compile tested. The patch spins the processor on the ATU outbound-queue-busy bit whenever out*() is called.

Nope, that doesn't seem to work:

Linux version 2.6.21-rc3 (tbm@em64t) (gcc version 4.1.2 20061028 (prerelease) (Debian 4.1.1-19)) #23 Wed Mar 7 12:33:00 UTC 2007
CPU: XScale-V3 based processor [69056818] revision 8 (ARMv5TE), cr=0400397f
Machine: Intel IQ81340MC
Memory policy: ECC disabled, Data cache writeback
CPU0: D VIVT undefined 5 cache
CPU0: I cache: 32768 bytes, associativity 4, 32 byte lines, 256 sets
CPU0: D cache: 32768 bytes, associativity 4, 32 byte lines, 256 sets
Built 1 zonelists. Total pages: 65024
Kernel command line: console=ttyS1,115200 root=/dev/ram0
PID hash table entries: 1024 (order: 10, 4096 bytes)
Console: colour dummy device 80x30
Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)
Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)
Memory: 256MB = 256MB total
Memory: 255744KB available (3624K code, 273K data, 128K init)
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
NET: Registered protocol family 16
PCI: bus0: Fast back to back transfers disabled
PCI: bus1: Fast back to back transfers enabled
ATUX: Initialized (16M @ resource/virtual: 80000000/51000000)
ATUE: Initialized (0M @ resource/virtual: c0000000/00000000)
SCSI subsystem initialized
NET: Registered protocol family 2
IP route cache hash table entries: 2048 (order: 1, 8192 bytes)
TCP established hash table entries: 8192 (order: 4, 65536 bytes)
TCP bind hash table entries: 8192 (order: 3, 32768 bytes)
TCP: Hash tables configured (established 8192 bind 8192)
TCP reno registered
NetWinder Floating Point Emulator V0.97 (double precision)
Installing knfsd (copyright (C) 1996 [email protected]).
JFFS2 version 2.2. (NAND) (C) 2001-2006 Red Hat, Inc.
io scheduler noop registered
io scheduler deadline registered (default)
Serial: 8250/16550 driver $Revision: 1.90 $ 2 ports, IRQ sharing disabled
serial8250.0: ttyS0 at MMIO 0xffd82340 (irq = 52) is a XScale
serial8250.1: ttyS1 at MMIO 0xffd82300 (irq = 51) is a XScale
RAMDISK driver initialized: 2 RAM disks of 8192K size 1024 blocksize
nbd: registered device at major 43
Intel(R) PRO/1000 Network Driver - version 7.3.20-k2-NAPI
Copyright (c) 1999-2006 Intel Corporation.
e1000: 0000:00:02.0: e1000_probe: (PCI:33MHz:64-bit) 00:0e:0c:b9:ab:72
e1000: eth0: e1000_probe: Intel(R) PRO/1000 Network Connection
e1000: 0000:00:02.1: e1000_probe: (PCI:33MHz:64-bit) 00:0e:0c:b9:ab:73
e1000: eth1: e1000_probe: Intel(R) PRO/1000 Network Connection
Loading iSCSI transport class v2.0-724.
sata_via 0000:00:01.0: routed to hard irq line 9
ata1: SATA max UDMA/133 cmd 0xfffb04a0 ctl 0xfffb04aa bmdma 0xfffb0480 irq 25
Unhandled fault: imprecise external abort (0x406) at 0x23212064

Internal error: : 406 [#1]
Modules linked in:
CPU: 0
PC is at ata_bmdma_freeze+0x3c/0x50
LR is at __iop13xx_io+0x14/0x4c
pc : [<401e9b30>]    lr : [<4003372c>]    Not tainted

sp : 40651dbc ip : 40651d98 fp : 40651dcc
r10: 4fce1cf0 r9 : 4fce1cec r8 : 00000001
r7 : 4fcd440c r6 : 406702b4 r5 : 00000053 r4 : 406702b4 r3 : 00000001 r2 : fffe04a7 r1 : fee80074 r0 : fec604a7
Flags: nZCv IRQs off FIQs on Mode SVC_32 Segment kernel
Control: 400397F
Table: 00004018 DAC: 00000035
Process swapper (pid: 1, stack limit = 0x40650250)

Stack: (0x40651dbc to 0x40652000)

1da0: 406702b4
1dc0: 40651de0 40651dd0 401ea07c 401e9b00 20000013 40651df4 40651de4 401ea0d4 1de0: 401ea040 00000001 40651e3c 40651df8 401e4448 401ea0b4 fffb04a0 fffb04aa 1e00: fffb0480 00000019 4062e848 00000019 40651e5a 4062e8ec 00000000 40651e5a 1e20: 4062e800 00000003 4fcd440c 4062e848 40651e84 40651e40 401ec984 401e422c 1e40: 40651e60 40651e50 40174c78 40175b50 4062e800 40651e70 40f11e64 403c8fc8 1e60: 4062e800 00000000 00000000 403eb0a4 40023884 4062e8ec 40651ea4 40651e88 1e80: 40187938 401ec6d4 4062e848 4062e848 4fce3fc0 403c8ffc 40651ecc 40651ea8 1ea0: 401acce8 401878dc 403c8ffc 4062e848 4fce3fc0 401acf90 40023884 400233b0 1ec0: 40651ee8 40651ed0 401ace94 401acc7c 4062e920 4062e848 403c8ffc 40651f00 1ee0: 40651eec 401ad074 401ace08 00000000 40651f04 40651f2c 40651f04 401ac13c 1f00: 401acf9c 403c0fc0 403c0fc0 4062e890 403c8ffc 403c9010 403c0ec0 00000000 1f20: 40651f3c 40651f30 401acb88 401ac0f4 40651f60 40651f40 401ac4c8 401acb74 1f40: 403c8ffc 00000000 403c8ffc 00000000 40023884 40651f74 40651f64 401ad29c 1f60: 401ac464 403c8fc8 40651f90 40651f78 40187b18 401ad248 40023328 00000000 1f80: 40650000 40651fa0 40651f94 4001df78 40187aa4 40651ff4 40651fa4 400087a0 1fa0: 4001df68 40651fb0 40028c44 4003b8b8 00000000 00000000 40008724 40041a44 1fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 1fe0: 00000000 00000000 00000000 40651ff8 40041a44 40008730 00000000 00000000

Backtrace:
[<401e9af4>] (ata_bmdma_freeze+0x0/0x50) from [<401ea07c>] (__ata_port_freeze+0x48/0x74)
 r4 = 406702B4
[<401ea034>] (__ata_port_freeze+0x0/0x74) from [<401ea0d4>] (ata_eh_freeze_port+0x2c/0x44)
 r4 = 20000013
[<401ea0a8>] (ata_eh_freeze_port+0x0/0x44) from [<401e4448>] (ata_device_add+0x228/0x4e4)
 r4 = 00000001
[<401e4220>] (ata_device_add+0x0/0x4e4) from [<401ec984>] (svia_init_one+0x2bc/0x57c)
[<401ec6c8>] (svia_init_one+0x0/0x57c) from [<40187938>] (pci_device_probe+0x68/0x8c)
[<401878d0>] (pci_device_probe+0x0/0x8c) from [<401acce8>] (really_probe+0x78/0x18c)
 r7 = 403C8FFC  r6 = 4FCE3FC0  r5 = 4062E848  r4 = 4062E848
[<401acc70>] (really_probe+0x0/0x18c) from [<401ace94>] (driver_probe_device+0x98/0xc4)
[<401acdfc>] (driver_probe_device+0x0/0xc4) from [<401ad074>] (__driver_attach+0xe4/0xe8)
 r6 = 403C8FFC  r5 = 4062E848  r4 = 4062E920
[<401acf90>] (__driver_attach+0x0/0xe8) from [<401ac13c>] (bus_for_each_dev+0x54/0x80)
 r5 = 40651F04  r4 = 00000000
[<401ac0e8>] (bus_for_each_dev+0x0/0x80) from [<401acb88>] (driver_attach+0x20/0x28)
 r7 = 00000000  r6 = 403C0EC0  r5 = 403C9010  r4 = 403C8FFC
[<401acb68>] (driver_attach+0x0/0x28) from [<401ac4c8>] (bus_add_driver+0x70/0x194)
[<401ac458>] (bus_add_driver+0x0/0x194) from [<401ad29c>] (driver_register+0x60/0x9c)
 r8 = 40023884  r7 = 00000000  r6 = 403C8FFC  r5 = 00000000
 r4 = 403C8FFC
[<401ad23c>] (driver_register+0x0/0x9c) from [<40187b18>] (__pci_register_driver+0x80/0xc8)
 r4 = 403C8FC8
[<40187a98>] (__pci_register_driver+0x0/0xc8) from [<4001df78>] (svia_init+0x1c/0x28)
 r6 = 40650000  r5 = 00000000  r4 = 40023328
[<4001df5c>] (svia_init+0x0/0x28) from [<400087a0>] (init+0x7c/0x1d4)
[<40008724>] (init+0x0/0x1d4) from [<40041a44>] (do_exit+0x0/0x880)
Code: e5943004 e1a00004 e1a0e00f e593f020 (e1a00004)
Kernel panic - not syncing: Attempted to kill init!
Signature · 2 lines
Martin Michlmayr
http://www.cyrius.com/
#5 lore raw
Quoted 7 lines · Martin Michlmayr
Quoted 3 lines · Dan Williams

Martin can you give the attached patch a try to see if it resolves the oops? It has only been compile tested. The patch spins the processor on the ATU outbound-queue-busy bit whenever out*() is called.

Nope, that doesn't seem to work:

Ok, this actually makes sense because the hardware will not allow delayed writes to pass each other. The patch would only help in the case where ordering between posted and delayed writes needed to be maintained, and it looks like sata_via only exposes a delayed write interface. I'll put together a patch to dump more diagnostics on an external abort.