"Francois B." <fblodr...@videotron.ca> writes: > When is this going in? Tested on my headless emac G4 (2005), > and it solves the problem.
I was going to wait until I run my back up (dump over a network to another machine) to report, since that reliably gave the timeout messages on my machine, but I also have been happily running (building ports, reading mail in emacs, viewing pages in xxxterm, reading ps files in gv) with this patch since Sunday and haven't seen the error or any clear problems. I thought the other day that the machine seemed slightly more responsive using Gnus in emacs (which can be a little soupy), but that's totally subjective and is in comparison to the 4.9 release as opposed to current without the patch. I do now see two gem0 timeout messages in my log, but there's one before as well as one after I applied the patch. Harmless and unrelated? gem0 timeout 1 (4.9 release) ---------------------- Jul 16 09:56:12 holly /bsd: OpenBSD 4.9 (GENERIC) #48: Wed Mar 2 07:02:32 MST 2011 Jul 16 09:56:12 holly /bsd: dera...@macppc.openbsd.org:/usr/src/sys/arch/macppc/compile/GENERIC ... Jul 16 10:01:43 holly ntpd[31193]: bad peer from pool pool.ntp.org (169.229.70.64) Jul 16 14:03:42 holly /bsd: gem0: device timeout Jul 16 21:00:01 holly syslogd: restart gem0 timeout 2 (current with patch applied) ---------------------- Jul 17 06:04:10 holly /bsd: OpenBSD 4.9-current (GENERIC) #0: Sat Jul 16 23:32:20 EDT 2011 Jul 17 06:04:10 holly /bsd: r...@holly.cable.rcn.com:/usr/src/sys/arch/macppc/compile/GENERIC ... Jul 17 08:38:36 holly ntpd[17064]: bad peer from pool pool.ntp.org (63.141.244.130) Jul 17 10:00:01 holly syslogd: restart Jul 18 07:58:11 holly /bsd: gem0: device timeout Jul 18 08:51:28 holly /bsd: uid 0 on /usr: file system full /var/log/messages excerpt from a recent snapshot showing the timeout message... ============================================ Jul 16 21:40:45 holly /bsd: OpenBSD 4.9-current (GENERIC) #40: Wed Jul 13 16:48:53 MDT 2011 Jul 16 21:40:45 holly /bsd: dera...@macppc.openbsd.org:/usr/src/sys/arch/macppc/compile/GENERIC Jul 16 21:40:45 holly /bsd: real mem = 402653184 (384MB) Jul 16 21:40:45 holly /bsd: avail mem = 376946688 (359MB) Jul 16 21:40:45 holly /bsd: mainbus0 at root: model PowerMac3,4 Jul 16 21:40:45 holly /bsd: cpu0 at mainbus0: 7400 (Revision 0x209): 466 MHz: 1MB backside cache Jul 16 21:40:45 holly /bsd: mem0 at mainbus0 ... Jul 16 22:06:18 holly /bsd: wd0(wdc0:0:0): timeout Jul 16 22:06:18 holly /bsd: type: ata Jul 16 22:06:18 holly /bsd: c_bcount: 2048 Jul 16 22:06:19 holly /bsd: c_skip: 0 Jul 16 22:06:19 holly /bsd: wd0f: device timeout writing fsbn 3509636 of 3509636-3509639 (wd0 bn 9264516; cn 9190 tn 15 sn 51), retrying Jul 16 22:06:19 holly /bsd: wd0: soft error (corrected) Dmesg with the patch, no wd0 timeouts since then... rebooting [ using 490664 bytes of bsd ELF symbol table ] console out [ATY,Rage128Pd]console in [keyboard] , using USB : memaddr 94000000 size 4000000, : consaddr 96008000, : ioaddr 90020000, size 20000: memtag 8000, iotag 8000: width 1280 linebytes 1280 height 960 depth 8 Copyright (c) 1982, 1986, 1989, 1991, 1993 The Regents of the University of California. All rights reserved. Copyright (c) 1995-2011 OpenBSD. All rights reserved. http://www.OpenBSD.org OpenBSD 4.9-current (GENERIC) #0: Sat Jul 16 23:32:20 EDT 2011 r...@holly.cable.rcn.com:/usr/src/sys/arch/macppc/compile/GENERIC real mem = 402653184 (384MB) avail mem = 376954880 (359MB) mainbus0 at root: model PowerMac3,4 cpu0 at mainbus0: 7400 (Revision 0x209): 466 MHz: 1MB backside cache mem0 at mainbus0 spdmem0 at mem0: 128MB SDRAM non-parity PC133CL2 spdmem1 at mem0: 256MB SDRAM non-parity PC133CL3 memc0 at mainbus0: uni-n kiic0 at memc0 offset 0xf8001000 iic0 at kiic0 mpcpcibr0 at mainbus0 pci: uni-north, Revision 0xff pci0 at mpcpcibr0 bus 0 pchb0 at pci0 dev 11 function 0 "Apple Uni-N2 AGP" rev 0x00 vgafb0 at pci0 dev 16 function 0 "ATI Rage Fury" rev 0x00, mmio wsdisplay0 at vgafb0 mux 1: console (std, vt100 emulation) mpcpcibr1 at mainbus0 pci: uni-north, Revision 0x0 pci1 at mpcpcibr1 bus 0 pchb1 at pci1 dev 11 function 0 "Apple Uni-N2 Host" rev 0x00 bge0 at pci1 dev 20 function 0 "Altima AC9100" rev 0x15, BCM5701 B5 (0x105): irq 54, address 00:40:f4:46:f0:3f brgphy0 at bge0 phy 1: BCM5701 10/100/1000baseT PHY, rev. 0 macobio0 at pci1 dev 23 function 0 "Apple Keylargo" rev 0x03 openpic0 at macobio0 offset 0x40000: version 0x4614 feature 3f0302 LE macgpio0 at macobio0 offset 0x50 macgpio1 at macgpio0 irq 47 pgs0 at macgpio0: irq 55 "gpio5" at macgpio0 not configured "gpio6" at macgpio0 not configured "gpio11" at macgpio0 not configured "extint-gpio15" at macgpio0 not configured "extint-gpio16" at macgpio0 not configured "escc-legacy" at macobio0 offset 0x12000 not configured zsc0 at macobio0 offset 0x13000: irq 22,50 zstty0 at zsc0 channel 0 zstty1 at zsc0 channel 1 tumbler0 at macobio0 offset 0x10000: irq 30,1,2 "timer" at macobio0 offset 0x15000 not configured adb0 at macobio0 offset 0x16000 irq 25: via-pmu, 0 targets apm0 at adb0: battery flags 0x9, 0% charged kiic1 at macobio0 offset 0x18000 iic1 at kiic1 wdc0 at macobio0 offset 0x1f000 irq 19: DMA wd0 at wdc0 channel 0 drive 0: <WDC WD3200AAJB-00J3A0> wd0: 16-sector PIO, LBA48, 305245MB, 625142448 sectors wd0(wdc0:0:0): using PIO mode 4, DMA mode 2, Ultra-DMA mode 4 wdc1 at macobio0 offset 0x20000 irq 20: DMA atapiscsi0 at wdc1 channel 0 drive 0 scsibus0 at atapiscsi0: 2 targets cd0 at scsibus0 targ 0 lun 0: <PIONEER, DVD-RW DVR-115D, 1.18> ATAPI 5/cdrom removable cd0(wdc1:0:0): using BIOS timings, DMA mode 2 wdc2 at macobio0 offset 0x21000 irq 21: DMA audio0 at tumbler0 ohci0 at pci1 dev 24 function 0 "Apple USB" rev 0x00: irq 27, version 1.0 ohci1 at pci1 dev 25 function 0 "Apple USB" rev 0x00: irq 28, version 1.0 usb0 at ohci0: USB revision 1.0 uhub0 at usb0 "Apple OHCI root hub" rev 1.00/1.00 addr 1 usb1 at ohci1: USB revision 1.0 uhub1 at usb1 "Apple OHCI root hub" rev 1.00/1.00 addr 1 mpcpcibr2 at mainbus0 pci: uni-north, Revision 0x16 pci2 at mpcpcibr2 bus 0 pchb2 at pci2 dev 11 function 0 "Apple Uni-N2 Host" rev 0x00 "AT&T/Lucent FW322 1394" rev 0x00 at pci2 dev 14 function 0 not configured gem0 at pci2 dev 15 function 0 "Apple Uni-N GMAC" rev 0x01: irq 41, address 00:03:93:04:f9:b2 brgphy1 at gem0 phy 0: BCM5401 10/100/1000baseT PHY, rev. 3 uhub2 at uhub1 port 1 "Chicony Generic USB Hub" rev 1.10/1.00 addr 2 uhidev0 at uhub2 port 1 configuration 1 interface 0 "Chicony PFU-65 USB Keyboard" rev 1.10/1.00 addr 3 uhidev0: iclass 3/1 ukbd0 at uhidev0: 8 modifier keys, 6 key codes wskbd0 at ukbd0: console keyboard, using wsdisplay0 uhidev1 at uhub2 port 2 configuration 1 interface 0 "Microsoft Microsoft 3-Button Mouse with IntelliEye(TM)" rev 1.10/3.00 addr 4 uhidev1: iclass 3/1 ums0 at uhidev1: 3 buttons, Z dir wsmouse0 at ums0 mux 0 vscsi0 at root scsibus1 at vscsi0: 256 targets softraid0 at root scsibus2 at softraid0: 256 targets bootpath: /pci@f2000000/mac-io@17/ata-4@1f000/disk@0:/bsd root on wd0a swap on wd0b dump on wd0b gem0: device timeout When I applied the patch, part of mutex.s was rejected. In case I messed up the hand merge, here's what that part of the file looks like in what I built from... a) mutex.S.rej ------------------------------------------------------------------------ @@ -110,16 +104,16 @@ cmpl 0,%r4,%r6 beq- .L_mutex_try_selflocked #endif - stw %r3,28(%r1) # save mtx during lcsplx - la %r4,28(%r1) + stw %r3,12(%r1) # save mtx during lcsplx + la %r4,12(%r1) stwcx. %r3,0,%r4 # unreserve owner mr %r3,%r7 # move old cpl to arg0 bl _C_LABEL(lcsplx) # call splx on old cpl - lwz %r0,36(%r1) # load return address + lwz %r0,20(%r1) # load return address mtlr %r0 - addi %r1,%r1,32 # restore stack - li %r2,0 # return zero + addi %r1,%r1,16 # restore stack + li %r3,0 # return zero blr .L_mutex_try_free: @@ -131,10 +125,10 @@ stw %r6,CI_MUTEX_LEVEL(%r4) #endif stw %r7,MTX_OLDCPL(%r3) # save old ipl - lwz %r0,36(%r1) # load return address + lwz %r0,20(%r1) # load return address mtlr %r0 - addi %r1,%r1,32 # restore stack - li %r2,1 # return nonzero + addi %r1,%r1,16 # restore stack + li %r3,1 # return nonzero blr #ifdef DIAGNOSTIC b) that part of mutex.S after I manually applied the changes: ------------------------------------------------------------------------ cmpl 0,%r4,%r6 beq- .L_mutex_try_selflocked #endif stw %r3,12(%r1) # save mtx during lcsplx la %r4,12(%r1) stwcx. %r3,0,%r4 # unreserve owner mr %r3,%r7 # move old cpl to arg0 bl _C_LABEL(lcsplx) # call splx on old cpl lwz %r0,20(%r1) # load return address mtlr %r0 addi %r1,%r1,16 # restore stack li %r3,0 # return zero blr .L_mutex_try_free: stwcx. %r4,%r5,%r3 # old owner was 0 cond store bne- .L_mutex_try_locked # branch if reserve cancelled #ifdef DIAGNOSTIC lwz %r6,CI_MUTEX_LEVEL(%r4) addi %r6,%r6,1 # curpcu->ci_mutex_level++ stw %r6,CI_MUTEX_LEVEL(%r4) #endif stw %r7,MTX_OLDCPL(%r3) # save old ipl lwz %r0,20(%r1) # load return address mtlr %r0 addi %r1,%r1,16 # restore stack li %r3,1 # return nonzero blr #ifdef DIAGNOSTIC - Mike