Re: alc(4) support for Atheros AR815x
Hi, I have a eeepc 1001pxd with Attansic Technology L2C working and this patch didn't break the nic. One problem: very slow connectioncan I help? try to make some tests? Just an update: slow connection was a problem with my AP wifi. So my device is working well. Thank you, best regards -- Matteo Filippetto http://op83.blogspot.com
Re: alc(4) support for Atheros AR815x
2011/5/16 Stuart Henderson s...@spacehopper.org: So far, only had reports from L1C and the new devices (which is not the point of sending out this sort of diff). This is a fairly large diff and changes behaviour for existing devices. Has anyone with a currently-working L2C tested this to make sure it doesn't break their nic? Hi, I have a eeepc 1001pxd with Attansic Technology L2C working and this patch didn't break the nic. One problem: very slow connectioncan I help? try to make some tests? Latest snapshot of i386. Attached dmesg and pcidump. Best regards. Matteo Filippetto Domain /dev/pci0: 0:0:0: Intel Pineview DMI 0x: Vendor ID: 8086 Product ID: a010 0x0004: Command: 0006 Status ID: 2090 0x0008: Class: 06 Subclass: 00 Interface: 00 Revision: 00 0x000c: BIST: 00 Header Type: 00 Latency Timer: 00 Cache Line Size: 00 0x0010: BAR empty () 0x0014: BAR empty () 0x0018: BAR empty () 0x001c: BAR empty () 0x0020: BAR empty () 0x0024: BAR empty () 0x0028: Cardbus CIS: 0x002c: Subsystem Vendor ID: 1043 Product ID: 83ac 0x0030: Expansion ROM Base Address: 0x0038: 0x003c: Interrupt Pin: 00 Line: 00 Min Gnt: 00 Max Lat: 00 0x00e0: Capability 0x09: Vendor Specific 0:2:0: Intel Pineview Video 0x: Vendor ID: 8086 Product ID: a011 0x0004: Command: 0007 Status ID: 0090 0x0008: Class: 03 Subclass: 00 Interface: 00 Revision: 00 0x000c: BIST: 00 Header Type: 80 Latency Timer: 00 Cache Line Size: 00 0x0010: BAR mem 32bit addr: 0xf7e0/0x0008 0x0014: BAR io addr: 0xdc00/0x0008 0x0018: BAR mem prefetchable 32bit addr: 0xd000/0x1000 0x001c: BAR mem 32bit addr: 0xf7d0/0x0010 0x0020: BAR empty () 0x0024: BAR empty () 0x0028: Cardbus CIS: 0x002c: Subsystem Vendor ID: 1043 Product ID: 83ac 0x0030: Expansion ROM Base Address: 0x0038: 0x003c: Interrupt Pin: 01 Line: 0f Min Gnt: 00 Max Lat: 00 0x0090: Capability 0x05: Message Signaled Interrupts (MSI) 0x00d0: Capability 0x01: Power Management 0:2:1: Intel Pineview Video 0x: Vendor ID: 8086 Product ID: a012 0x0004: Command: 0007 Status ID: 0090 0x0008: Class: 03 Subclass: 80 Interface: 00 Revision: 00 0x000c: BIST: 00 Header Type: 80 Latency Timer: 00 Cache Line Size: 00 0x0010: BAR mem 32bit addr: 0xf7e8/0x0008 0x0014: BAR empty () 0x0018: BAR empty () 0x001c: BAR empty () 0x0020: BAR empty () 0x0024: BAR empty () 0x0028: Cardbus CIS: 0x002c: Subsystem Vendor ID: 1043 Product ID: 83ac 0x0030: Expansion ROM Base Address: 0x0038: 0x003c: Interrupt Pin: 00 Line: 00 Min Gnt: 00 Max Lat: 00 0x00d0: Capability 0x01: Power Management 0:27:0: Intel 82801GB HD Audio 0x: Vendor ID: 8086 Product ID: 27d8 0x0004: Command: 0006 Status ID: 0010 0x0008: Class: 04 Subclass: 03 Interface: 00 Revision: 02 0x000c: BIST: 00 Header Type: 00 Latency Timer: 00 Cache Line Size: 08 0x0010: BAR mem 64bit addr: 0xf7cf8000/0x4000 0x0018: BAR empty () 0x001c: BAR empty () 0x0020: BAR empty () 0x0024: BAR empty () 0x0028: Cardbus CIS: 0x002c: Subsystem Vendor ID: 1043 Product ID: 8442 0x0030: Expansion ROM Base Address: 0x0038: 0x003c: Interrupt Pin: 01 Line: 04 Min Gnt: 00 Max Lat: 00 0x0050: Capability 0x01: Power Management 0x0060: Capability 0x05: Message Signaled Interrupts (MSI) 0x0070: Capability 0x10: PCI Express 0:28:0: Intel 82801GB PCIE 0x: Vendor ID: 8086 Product ID: 27d0 0x0004: Command: 0104 Status ID: 0010 0x0008: Class: 06 Subclass: 04 Interface: 00 Revision: 02 0x000c: BIST: 00 Header Type: 81 Latency Timer: 00 Cache Line Size: 08 0x0010: 0x0014: 0x0018: Primary Bus: 0 Secondary Bus: 4 Subordinate Bus: 4 Secondary Latency Timer: 00 0x001c: I/O Base: f0 I/O Limit: 00 Secondary Status: 2000 0x0020: Memory Base: fff0 Memory Limit: 0x0024: Prefetch Memory Base: fff1 Prefetch Memory Limit: 0001 0x0028: Prefetch Memory Base Upper 32 Bits: 0x002c: Prefetch Memory Limit Upper 32 Bits: 0x0030: I/O Base Upper 16 Bits: I/O Limit Upper 16 Bits: 0x0038: Expansion ROM Base Address: 0x003c: Interrupt Pin: 01 Line: 0f Bridge Control: 0002 0x0040: Capability 0x10:
Re: alc(4) support for Atheros AR815x
Since nobody with a working PCI_PRODUCT_ATTANSIC_L2C seems interested, and the devices newly added in this diff are showing up more often in submitted dmesg than the L2C version matched by the current driver, I intend to commit this tomorrow unless there are objections. On 2011/05/16 11:16, Stuart Henderson wrote: So far, only had reports from L1C and the new devices (which is not the point of sending out this sort of diff). This is a fairly large diff and changes behaviour for existing devices. Has anyone with a currently-working L2C tested this to make sure it doesn't break their nic? On 2011/05/01 20:10, Stuart Henderson wrote: On 2011/05/01 18:35, Edd Barrett wrote: I have acquired a netboot (packard bell dot s), which I think uses this NIC. Is there an updated diff? Yes I just took the 2 minutes it took to apply it and fix the minor conflicts and linewrapping issue with the diff. Untested beyond it builds. Test reports and dmesg lines from existing working alc(4) L1C and L2C wanted. If it makes new chips work that's a bonus, but the important thing is making sure it doesn't break something that already works. Doesn't seem any point disabling interrupts in the ISR though. I haven't touched that in this diff but that should probably be done too. Index: share/man/man4/alc.4 === RCS file: /cvs/src/share/man/man4/alc.4,v retrieving revision 1.2 diff -u -p -r1.2 alc.4 --- share/man/man4/alc.4 8 Aug 2009 14:12:41 - 1.2 +++ share/man/man4/alc.4 1 May 2011 18:55:25 - @@ -19,7 +19,7 @@ .Os .Sh NAME .Nm alc -.Nd Atheros AR8131/AR8132 10/100/Gigabit Ethernet device +.Nd Atheros AR813x/AR815x 10/100/Gigabit Ethernet device .Sh SYNOPSIS .Cd alc* at pci? .Cd atphy* at mii? @@ -27,8 +27,7 @@ The .Nm driver provides support for Ethernet interfaces based on the -Atheros AR8131/AR8132 Ethernet chipset, also known as -the Attansic L1C/L2C respectively. +Atheros AR813x/AR815x Ethernet chipset. .Pp The .Nm Index: sys/arch/amd64/conf/GENERIC === RCS file: /cvs/src/sys/arch/amd64/conf/GENERIC,v retrieving revision 1.316 diff -u -p -r1.316 GENERIC --- sys/arch/amd64/conf/GENERIC 10 Apr 2011 20:27:02 - 1.316 +++ sys/arch/amd64/conf/GENERIC 1 May 2011 18:55:25 - @@ -472,7 +472,7 @@ bce* at pci? # Broadcom BCM4401 vic* at pci? # VMware VMXnet virtual interface et* at pci? # Agere/LSI ET1310 age* at pci? # Attansic L1 Ethernet -alc* at pci? # Attansic L1C/L2C Ethernet +alc* at pci? # Attansic L1C/L1D/L2C Ethernet ale* at pci? # Attansic L1E Ethernet lii* at pci? # Attansic L2 Ethernet jme* at pci? # JMicron JMC250/JMC260 Ethernet Index: sys/arch/amd64/conf/RAMDISK_CD === RCS file: /cvs/src/sys/arch/amd64/conf/RAMDISK_CD,v retrieving revision 1.116 diff -u -p -r1.116 RAMDISK_CD --- sys/arch/amd64/conf/RAMDISK_CD3 Apr 2011 12:32:05 - 1.116 +++ sys/arch/amd64/conf/RAMDISK_CD1 May 2011 18:55:25 - @@ -291,7 +291,7 @@ bce* at pci? # Broadcom BCM4401 vic* at pci? # VMware VMXnet virtual interface et* at pci? # Agere/LSI ET1310 age* at pci? # Attansic L1 Ethernet -alc* at pci? # Attansic L1C/L2C Ethernet +alc* at pci? # Attansic L1C/L1D/L2C Ethernet ale* at pci? # Attansic L1E Ethernet lii* at pci? # Attansic L2 Ethernet jme* at pci? # JMicron JMC250/JMC260 Ethernet Index: sys/arch/i386/conf/GENERIC === RCS file: /cvs/src/sys/arch/i386/conf/GENERIC,v retrieving revision 1.713 diff -u -p -r1.713 GENERIC --- sys/arch/i386/conf/GENERIC10 Apr 2011 20:27:02 - 1.713 +++ sys/arch/i386/conf/GENERIC1 May 2011 18:55:25 - @@ -632,7 +632,7 @@ gem* at pci? # Sun 'gem' ethernet vic* at pci? # VMware VMXnet virtual interface et* at pci? # Agere/LSI ET1310 age* at pci? # Attansic L1 Ethernet -alc* at pci? # Attansic L1C/L2C Ethernet +alc* at pci? # Attansic L1C/L1D/L2C Ethernet ale* at pci? # Attansic L1E Ethernet lii* at pci? # Attansic L2 Ethernet jme* at pci? # JMicron JMC250/JMC260 Ethernet Index: sys/arch/i386/conf/RAMDISK_CD
Re: alc(4) support for Atheros AR815x
So far, only had reports from L1C and the new devices (which is not the point of sending out this sort of diff). This is a fairly large diff and changes behaviour for existing devices. Has anyone with a currently-working L2C tested this to make sure it doesn't break their nic? On 2011/05/01 20:10, Stuart Henderson wrote: On 2011/05/01 18:35, Edd Barrett wrote: I have acquired a netboot (packard bell dot s), which I think uses this NIC. Is there an updated diff? Yes I just took the 2 minutes it took to apply it and fix the minor conflicts and linewrapping issue with the diff. Untested beyond it builds. Test reports and dmesg lines from existing working alc(4) L1C and L2C wanted. If it makes new chips work that's a bonus, but the important thing is making sure it doesn't break something that already works. Doesn't seem any point disabling interrupts in the ISR though. I haven't touched that in this diff but that should probably be done too. Index: share/man/man4/alc.4 === RCS file: /cvs/src/share/man/man4/alc.4,v retrieving revision 1.2 diff -u -p -r1.2 alc.4 --- share/man/man4/alc.48 Aug 2009 14:12:41 - 1.2 +++ share/man/man4/alc.41 May 2011 18:55:25 - @@ -19,7 +19,7 @@ .Os .Sh NAME .Nm alc -.Nd Atheros AR8131/AR8132 10/100/Gigabit Ethernet device +.Nd Atheros AR813x/AR815x 10/100/Gigabit Ethernet device .Sh SYNOPSIS .Cd alc* at pci? .Cd atphy* at mii? @@ -27,8 +27,7 @@ The .Nm driver provides support for Ethernet interfaces based on the -Atheros AR8131/AR8132 Ethernet chipset, also known as -the Attansic L1C/L2C respectively. +Atheros AR813x/AR815x Ethernet chipset. .Pp The .Nm Index: sys/arch/amd64/conf/GENERIC === RCS file: /cvs/src/sys/arch/amd64/conf/GENERIC,v retrieving revision 1.316 diff -u -p -r1.316 GENERIC --- sys/arch/amd64/conf/GENERIC 10 Apr 2011 20:27:02 - 1.316 +++ sys/arch/amd64/conf/GENERIC 1 May 2011 18:55:25 - @@ -472,7 +472,7 @@ bce*at pci? # Broadcom BCM4401 vic* at pci? # VMware VMXnet virtual interface et*at pci? # Agere/LSI ET1310 age* at pci? # Attansic L1 Ethernet -alc* at pci? # Attansic L1C/L2C Ethernet +alc* at pci? # Attansic L1C/L1D/L2C Ethernet ale* at pci? # Attansic L1E Ethernet lii* at pci? # Attansic L2 Ethernet jme* at pci? # JMicron JMC250/JMC260 Ethernet Index: sys/arch/amd64/conf/RAMDISK_CD === RCS file: /cvs/src/sys/arch/amd64/conf/RAMDISK_CD,v retrieving revision 1.116 diff -u -p -r1.116 RAMDISK_CD --- sys/arch/amd64/conf/RAMDISK_CD 3 Apr 2011 12:32:05 - 1.116 +++ sys/arch/amd64/conf/RAMDISK_CD 1 May 2011 18:55:25 - @@ -291,7 +291,7 @@ bce*at pci? # Broadcom BCM4401 vic* at pci? # VMware VMXnet virtual interface et*at pci? # Agere/LSI ET1310 age* at pci? # Attansic L1 Ethernet -alc* at pci? # Attansic L1C/L2C Ethernet +alc* at pci? # Attansic L1C/L1D/L2C Ethernet ale* at pci? # Attansic L1E Ethernet lii* at pci? # Attansic L2 Ethernet jme* at pci? # JMicron JMC250/JMC260 Ethernet Index: sys/arch/i386/conf/GENERIC === RCS file: /cvs/src/sys/arch/i386/conf/GENERIC,v retrieving revision 1.713 diff -u -p -r1.713 GENERIC --- sys/arch/i386/conf/GENERIC 10 Apr 2011 20:27:02 - 1.713 +++ sys/arch/i386/conf/GENERIC 1 May 2011 18:55:25 - @@ -632,7 +632,7 @@ gem*at pci? # Sun 'gem' ethernet vic* at pci? # VMware VMXnet virtual interface et*at pci? # Agere/LSI ET1310 age* at pci? # Attansic L1 Ethernet -alc* at pci? # Attansic L1C/L2C Ethernet +alc* at pci? # Attansic L1C/L1D/L2C Ethernet ale* at pci? # Attansic L1E Ethernet lii* at pci? # Attansic L2 Ethernet jme* at pci? # JMicron JMC250/JMC260 Ethernet Index: sys/arch/i386/conf/RAMDISK_CD === RCS file: /cvs/src/sys/arch/i386/conf/RAMDISK_CD,v retrieving revision 1.185 diff -u -p -r1.185 RAMDISK_CD --- sys/arch/i386/conf/RAMDISK_CD 3 Apr 2011 12:32:05 - 1.185 +++ sys/arch/i386/conf/RAMDISK_CD 1 May 2011 18:55:25 - @@ -372,7 +372,7 @@ xge*at pci? # Neterion Xframe-I/II 1
Re: alc(4) support for Atheros AR815x
On Wed, May 04, 2011 at 09:32:47AM +0200, Gabriel Linder wrote: I have an alc device too, and would like to fix it. Starting from kevlo's diff I updated it some month ago to compile, and compared FreeBSD driver to add some more things, finding some bugs in their driver (reported and fixed in their tree). I now have a working alc, with and without cable at boot or after boot but I have to update my tree (lagging some months behind) and probably fix some conflicts before posting an up to date diff. It would help me if someone could answer my silly questions about differences between FreeBSD and OpenBSD internals, by the way. Slides at http://www.openbsd.org/papers/ were very useful but do not cover this :) FYI, Marius just made a huge commit which includes some alc/PHY code. I don't know if it is relevent. http://svnweb.freebsd.org/base?view=revisionrevision=221407 -- Best Regards Edd Barrett http://www.theunixzoo.co.uk
Re: alc(4) support for Atheros AR815x
On 05/02/11 14:23, Edd Barrett wrote: On Mon, May 02, 2011 at 11:02:41AM +0100, Stuart Henderson wrote: On 2011/05/02 01:16, Edd Barrett wrote: On Sun, May 01, 2011 at 08:10:56PM +0100, Stuart Henderson wrote: On 2011/05/01 18:35, Edd Barrett wrote: I have acquired a netboot (packard bell dot s), which I think uses this NIC. Is there an updated diff? Yes I just took the 2 minutes it took to apply it and fix the minor conflicts and linewrapping issue with the diff. Untested beyond it builds. Stu's diff seems to work, kevlo's diff really.. although the first time i booted my bsd.rd I was unable to install due to: alc0: watchdog timeout (missed link) I had a report of a system with alc(4) which only works if the cable is connected at boot. Is that what happens for you too? If so, try this, similar to freebsd r214542. This change was already included in kevlo's diff. It does seem like it could still be related to the link state. I managed to get another error by: * booting with no cable plugged in. * once the system is up, connect a cable * run dhclient alc0 Then as DHREQUESTs were sent some kernel messages: alc0: watchdog timeout alc0: could not disable RxQ/TxQ (0x0008)! alc0: could not disable RxQ/TxQ MAC(0x0008)! Might give some clues? After those messages, the interface does infact recieve a DHCP address and the interface does work. So I would not let this hold back the commit. Some hints : http://marc.info/?l=openbsd-techm=129651174131694w=2 http://dargor.servebeer.com/~dargor/openbsd/alc/ (very old diffs) I have an alc device too, and would like to fix it. Starting from kevlo's diff I updated it some month ago to compile, and compared FreeBSD driver to add some more things, finding some bugs in their driver (reported and fixed in their tree). I now have a working alc, with and without cable at boot or after boot but I have to update my tree (lagging some months behind) and probably fix some conflicts before posting an up to date diff. It would help me if someone could answer my silly questions about differences between FreeBSD and OpenBSD internals, by the way. Slides at http://www.openbsd.org/papers/ were very useful but do not cover this :)
Re: alc(4) support for Atheros AR815x
Edd Barrett wrote: On Mon, May 02, 2011 at 11:02:41AM +0100, Stuart Henderson wrote: On 2011/05/02 01:16, Edd Barrett wrote: On Sun, May 01, 2011 at 08:10:56PM +0100, Stuart Henderson wrote: On 2011/05/01 18:35, Edd Barrett wrote: I have acquired a netboot (packard bell dot s), which I think uses this NIC. Is there an updated diff? Yes I just took the 2 minutes it took to apply it and fix the minor conflicts and linewrapping issue with the diff. Untested beyond it builds. Stu's diff seems to work, kevlo's diff really.. although the first time i booted my bsd.rd I was unable to install due to: alc0: watchdog timeout (missed link) I had a report of a system with alc(4) which only works if the cable is connected at boot. Is that what happens for you too? If so, try this, similar to freebsd r214542. This change was already included in kevlo's diff. It does seem like it could still be related to the link state. I managed to get another error by: * booting with no cable plugged in. * once the system is up, connect a cable * run dhclient alc0 Then as DHREQUESTs were sent some kernel messages: alc0: watchdog timeout I have seen such a timeouts on age(4). The issue occurs irregularly, box just stops responding over network for a while, records watchdog timeout and then box become available again. dmesg follows (age(4) is dropped in favor of xl(4) so no watchdog timeouts recorded at the moment). From my understanding it can be a common issue with atphy(4) so both alc(4) and age(4) are affected. Alexey OpenBSD 4.7-beta (GENERIC.MP) #82: Fri Feb 5 01:05:44 MST 2010 t...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP real mem = 2145910784 (2046MB) avail mem = 2079428608 (1983MB) mainbus0 at root bios0 at mainbus0: SMBIOS rev. 2.4 @ 0xf06e0 (71 entries) bios0: vendor American Megatrends Inc. version 0603 date 07/03/2007 bios0: ASUSTeK Computer INC. P5K acpi0 at bios0: rev 0 acpi0: tables DSDT FACP APIC MCFG OEMB HPET OSFR acpi0: wakeup devices P0P2(S4) P0P1(S4) UAR1(S4) PS2K(S4) EUSB(S4) USBE(S4) P0P5(S4) P0P6(S4) P0P7(S4) P0P8(S4) P0P9(S4) USB0(S4) USB1(S4) USB2(S4) USB3(S4) USB4(S4) USB5(S4) USB6(S4) P0P4(S4) acpitimer0 at acpi0: 3579545 Hz, 24 bits acpimadt0 at acpi0 addr 0xfee0: PC-AT compat cpu0 at mainbus0: apid 0 (boot processor) cpu0: Intel(R) Core(TM)2 Duo CPU E6750 @ 2.66GHz, 2671.97 MHz cpu0: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,SBF,SSE3,MWAIT,DS-CPL,VMX,SMX,EST,TM2,CX16,xTPR,NXE,LONG cpu0: 4MB 64b/line 16-way L2 cache cpu0: apic clock running at 333MHz cpu1 at mainbus0: apid 1 (application processor) cpu1: Intel(R) Core(TM)2 Duo CPU E6750 @ 2.66GHz, 2671.61 MHz cpu1: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,SBF,SSE3,MWAIT,DS-CPL,VMX,SMX,EST,TM2,CX16,xTPR,NXE,LONG cpu1: 4MB 64b/line 16-way L2 cache ioapic0 at mainbus0: apid 2 pa 0xfec0, version 20, 24 pins acpihpet0 at acpi0: 14318179 Hz acpiprt0 at acpi0: bus 0 (PCI0) acpiprt1 at acpi0: bus 1 (P0P2) acpiprt2 at acpi0: bus 5 (P0P1) acpiprt3 at acpi0: bus -1 (P0P5) acpiprt4 at acpi0: bus -1 (P0P6) acpiprt5 at acpi0: bus -1 (P0P7) acpiprt6 at acpi0: bus 3 (P0P8) acpiprt7 at acpi0: bus 2 (P0P9) acpiprt8 at acpi0: bus 4 (P0P4) acpicpu0 at acpi0: PSS acpicpu1 at acpi0: PSS aibs0 at acpi0 acpibtn0 at acpi0: PWRB cpu0: Enhanced SpeedStep 2671 MHz: speeds: 2664, 1998 MHz pci0 at mainbus0 bus 0 pchb0 at pci0 dev 0 function 0 Intel 82G33 Host rev 0x02 ppb0 at pci0 dev 1 function 0 Intel 82G33 PCIE rev 0x02: apic 2 int 16 (irq 11) pci1 at ppb0 bus 1 vga1 at pci1 dev 0 function 0 vendor NVIDIA, unknown product 0x0400 rev 0xa1 wsdisplay0 at vga1 mux 1: console (80x25, vt100 emulation) wsdisplay0: screen 1-5 added (80x25, vt100 emulation) uhci0 at pci0 dev 26 function 0 Intel 82801I USB rev 0x02: apic 2 int 16 (irq 11) uhci1 at pci0 dev 26 function 1 Intel 82801I USB rev 0x02: apic 2 int 21 (irq 3) uhci2 at pci0 dev 26 function 2 Intel 82801I USB rev 0x02: apic 2 int 18 (irq 5) ehci0 at pci0 dev 26 function 7 Intel 82801I USB rev 0x02: apic 2 int 18 (irq 5) usb0 at ehci0: USB revision 2.0 uhub0 at usb0 Intel EHCI root hub rev 2.00/1.00 addr 1 azalia0 at pci0 dev 27 function 0 Intel 82801I HD Audio rev 0x02: apic 2 int 22 (irq 15) azalia0: codecs: Realtek ALC883 audio0 at azalia0 ppb1 at pci0 dev 28 function 0 Intel 82801I PCIE rev 0x02: apic 2 int 17 (irq 10) pci2 at ppb1 bus 4 ppb2 at pci0 dev 28 function 4 Intel 82801I PCIE rev 0x02: apic 2 int 17 (irq 10) pci3 at ppb2 bus 3 jmb0 at pci3 dev 0 function 0 JMicron JMB363 IDE/SATA rev 0x03 ahci0 at jmb0: apic 2 int 16 (irq 11), AHCI 1.0 scsibus0 at ahci0: 32 targets pciide0 at jmb0: DMA, channel 0 wired to native-PCI, channel 1 wired to native-PCI pciide0: using apic 2 int 16 (irq 11) for native-PCI interrupt pciide0: channel 0 disabled (no drives) pciide0:
Re: alc(4) support for Atheros AR815x
On Sun, 2011-05-01 at 18:35 +0100, Edd Barrett wrote: On Thu, Apr 28, 2011 at 07:21:16AM +1000, Jonathan Gray wrote: On Tue, Jan 25, 2011 at 06:24:28PM +0800, Kevin Lo wrote: Hi, The following diff adds support for Atheros AR8151/AR8152 chipsets; mostly from FreeBSD. It also fixes an issue i386/6311. Tested on Acer AOD255E. Is there an updated diff for this? It seems this never made it into the tree. I have acquired a netboot (packard bell dot s), which I think uses this NIC. Is there an updated diff? Hi Edd, A couple of days ago jsg@ asked the same question: http://marc.info/?l=openbsd-techm=130393940030183w=2 I forgot to cc tech@. Sorry, I've lacked alc hardware, I have no updated diff. Kevin
Re: alc(4) support for Atheros AR815x
On 2011/05/02 01:16, Edd Barrett wrote: On Sun, May 01, 2011 at 08:10:56PM +0100, Stuart Henderson wrote: On 2011/05/01 18:35, Edd Barrett wrote: I have acquired a netboot (packard bell dot s), which I think uses this NIC. Is there an updated diff? Yes I just took the 2 minutes it took to apply it and fix the minor conflicts and linewrapping issue with the diff. Untested beyond it builds. Stu's diff seems to work, kevlo's diff really.. although the first time i booted my bsd.rd I was unable to install due to: alc0: watchdog timeout (missed link) I had a report of a system with alc(4) which only works if the cable is connected at boot. Is that what happens for you too? If so, try this, similar to freebsd r214542. Index: if_alc.c === RCS file: /cvs/src/sys/dev/pci/if_alc.c,v retrieving revision 1.11 diff -u -p -r1.11 if_alc.c --- if_alc.c5 Apr 2011 18:01:21 - 1.11 +++ if_alc.c2 May 2011 10:01:12 - @@ -236,8 +236,8 @@ alc_miibus_statchg(struct device *dev) reg = CSR_READ_4(sc, ALC_MAC_CFG); reg |= MAC_CFG_TX_ENB | MAC_CFG_RX_ENB; CSR_WRITE_4(sc, ALC_MAC_CFG, reg); + alc_aspm(sc); } - alc_aspm(sc); } void
Re: alc(4) support for Atheros AR815x
On Mon, May 02, 2011 at 11:02:41AM +0100, Stuart Henderson wrote: On 2011/05/02 01:16, Edd Barrett wrote: On Sun, May 01, 2011 at 08:10:56PM +0100, Stuart Henderson wrote: On 2011/05/01 18:35, Edd Barrett wrote: I have acquired a netboot (packard bell dot s), which I think uses this NIC. Is there an updated diff? Yes I just took the 2 minutes it took to apply it and fix the minor conflicts and linewrapping issue with the diff. Untested beyond it builds. Stu's diff seems to work, kevlo's diff really.. although the first time i booted my bsd.rd I was unable to install due to: alc0: watchdog timeout (missed link) I had a report of a system with alc(4) which only works if the cable is connected at boot. Is that what happens for you too? If so, try this, similar to freebsd r214542. This change was already included in kevlo's diff. It does seem like it could still be related to the link state. I managed to get another error by: * booting with no cable plugged in. * once the system is up, connect a cable * run dhclient alc0 Then as DHREQUESTs were sent some kernel messages: alc0: watchdog timeout alc0: could not disable RxQ/TxQ (0x0008)! alc0: could not disable RxQ/TxQ MAC(0x0008)! Might give some clues? After those messages, the interface does infact recieve a DHCP address and the interface does work. So I would not let this hold back the commit. -- Best Regards Edd Barrett http://www.theunixzoo.co.uk
Re: alc(4) support for Atheros AR815x
On 2011/05/01 18:35, Edd Barrett wrote: I have acquired a netboot (packard bell dot s), which I think uses this NIC. Is there an updated diff? Yes I just took the 2 minutes it took to apply it and fix the minor conflicts and linewrapping issue with the diff. Untested beyond it builds. Test reports and dmesg lines from existing working alc(4) L1C and L2C wanted. If it makes new chips work that's a bonus, but the important thing is making sure it doesn't break something that already works. Doesn't seem any point disabling interrupts in the ISR though. I haven't touched that in this diff but that should probably be done too. Index: share/man/man4/alc.4 === RCS file: /cvs/src/share/man/man4/alc.4,v retrieving revision 1.2 diff -u -p -r1.2 alc.4 --- share/man/man4/alc.48 Aug 2009 14:12:41 - 1.2 +++ share/man/man4/alc.41 May 2011 18:55:25 - @@ -19,7 +19,7 @@ .Os .Sh NAME .Nm alc -.Nd Atheros AR8131/AR8132 10/100/Gigabit Ethernet device +.Nd Atheros AR813x/AR815x 10/100/Gigabit Ethernet device .Sh SYNOPSIS .Cd alc* at pci? .Cd atphy* at mii? @@ -27,8 +27,7 @@ The .Nm driver provides support for Ethernet interfaces based on the -Atheros AR8131/AR8132 Ethernet chipset, also known as -the Attansic L1C/L2C respectively. +Atheros AR813x/AR815x Ethernet chipset. .Pp The .Nm Index: sys/arch/amd64/conf/GENERIC === RCS file: /cvs/src/sys/arch/amd64/conf/GENERIC,v retrieving revision 1.316 diff -u -p -r1.316 GENERIC --- sys/arch/amd64/conf/GENERIC 10 Apr 2011 20:27:02 - 1.316 +++ sys/arch/amd64/conf/GENERIC 1 May 2011 18:55:25 - @@ -472,7 +472,7 @@ bce*at pci? # Broadcom BCM4401 vic* at pci? # VMware VMXnet virtual interface et*at pci? # Agere/LSI ET1310 age* at pci? # Attansic L1 Ethernet -alc* at pci? # Attansic L1C/L2C Ethernet +alc* at pci? # Attansic L1C/L1D/L2C Ethernet ale* at pci? # Attansic L1E Ethernet lii* at pci? # Attansic L2 Ethernet jme* at pci? # JMicron JMC250/JMC260 Ethernet Index: sys/arch/amd64/conf/RAMDISK_CD === RCS file: /cvs/src/sys/arch/amd64/conf/RAMDISK_CD,v retrieving revision 1.116 diff -u -p -r1.116 RAMDISK_CD --- sys/arch/amd64/conf/RAMDISK_CD 3 Apr 2011 12:32:05 - 1.116 +++ sys/arch/amd64/conf/RAMDISK_CD 1 May 2011 18:55:25 - @@ -291,7 +291,7 @@ bce*at pci? # Broadcom BCM4401 vic* at pci? # VMware VMXnet virtual interface et*at pci? # Agere/LSI ET1310 age* at pci? # Attansic L1 Ethernet -alc* at pci? # Attansic L1C/L2C Ethernet +alc* at pci? # Attansic L1C/L1D/L2C Ethernet ale* at pci? # Attansic L1E Ethernet lii* at pci? # Attansic L2 Ethernet jme* at pci? # JMicron JMC250/JMC260 Ethernet Index: sys/arch/i386/conf/GENERIC === RCS file: /cvs/src/sys/arch/i386/conf/GENERIC,v retrieving revision 1.713 diff -u -p -r1.713 GENERIC --- sys/arch/i386/conf/GENERIC 10 Apr 2011 20:27:02 - 1.713 +++ sys/arch/i386/conf/GENERIC 1 May 2011 18:55:25 - @@ -632,7 +632,7 @@ gem*at pci? # Sun 'gem' ethernet vic* at pci? # VMware VMXnet virtual interface et*at pci? # Agere/LSI ET1310 age* at pci? # Attansic L1 Ethernet -alc* at pci? # Attansic L1C/L2C Ethernet +alc* at pci? # Attansic L1C/L1D/L2C Ethernet ale* at pci? # Attansic L1E Ethernet lii* at pci? # Attansic L2 Ethernet jme* at pci? # JMicron JMC250/JMC260 Ethernet Index: sys/arch/i386/conf/RAMDISK_CD === RCS file: /cvs/src/sys/arch/i386/conf/RAMDISK_CD,v retrieving revision 1.185 diff -u -p -r1.185 RAMDISK_CD --- sys/arch/i386/conf/RAMDISK_CD 3 Apr 2011 12:32:05 - 1.185 +++ sys/arch/i386/conf/RAMDISK_CD 1 May 2011 18:55:25 - @@ -372,7 +372,7 @@ xge*at pci? # Neterion Xframe-I/II 1 vic* at pci? # VMware VMXnet virtual interface et*at pci? # Agere/LSI ET1310 age* at pci? # Attansic L1 Ethernet -alc* at pci? # Attansic L1C/L2C Ethernet +alc* at pci? # Attansic L1C/L1D/L2C Ethernet ale*
Re: alc(4) support for Atheros AR815x
On Sun, May 1, 2011 at 2:10 PM, Stuart Henderson s...@spacehopper.org wrote: On 2011/05/01 18:35, Edd Barrett wrote: I have acquired a netboot (packard bell dot s), which I think uses this NIC. Is there an updated diff? Yes I just took the 2 minutes it took to apply it and fix the minor conflicts and linewrapping issue with the diff. Untested beyond it builds. Test reports and dmesg lines from existing working alc(4) L1C and L2C wanted. If it makes new chips work that's a bonus, but the important thing is making sure it doesn't break something that already works. Doesn't seem any point disabling interrupts in the ISR though. I haven't touched that in this diff but that should probably be done too. Tested here on amd64.mp: No relevant changes in dmesg (i guess)... Old dmesg: OpenBSD 4.9-current (kobj) #0: Tue Apr 26 18:02:56 CDT 2011 root@maetel.00z:/usr/kobj real mem = 1608056832 (1533MB) avail mem = 1551200256 (1479MB) mainbus0 at root bios0 at mainbus0: SMBIOS rev. 2.6 @ 0xfd400 (50 entries) bios0: vendor American Megatrends Inc. version V1.3 date 11/15/2010 bios0: MSI MS-7623 acpi0 at bios0: rev 0 acpi0: sleep states S0 S3 S4 S5 acpi0: tables DSDT FACP APIC MCFG OEMB SRAT HPET SSDT acpi0: wakeup devices PCE2(S4) PCE3(S4) PCE4(S4) PCE5(S4) PCE6(S4) PCE7(S4) PCE9(S4) PCEA(S4) PCEB(S4) PCEC(S4) SBAZ(S4) PSKE(S4) PSMS(S4) ECIR(S4) PS2K(S3) PS2M(S3) P0PC(S4) UHC1(S4) UHC2(S4) UHC3(S4) USB4(S4) UHC5(S4) UHC6(S4) UHC7(S4) PWRB(S3) acpitimer0 at acpi0: 3579545 Hz, 32 bits acpimadt0 at acpi0 addr 0xfee0: PC-AT compat cpu0 at mainbus0: apid 0 (boot processor) cpu0: AMD Phenom(tm) II X4 955 Processor, 3200.65 MHz cpu0: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,MWAIT,CX16,POPCNT,NXE,MMXX,FFXSR,LONG,3DNOW2,3DNOW cpu0: 64KB 64b/line 2-way I-cache, 64KB 64b/line 2-way D-cache, 512KB 64b/line 16-way L2 cache cpu0: ITLB 32 4KB entries fully associative, 16 4MB entries fully associative cpu0: DTLB 48 4KB entries fully associative, 48 4MB entries fully associative cpu0: apic clock running at 200MHz cpu1 at mainbus0: apid 1 (application processor) cpu1: AMD Phenom(tm) II X4 955 Processor, 3200.16 MHz cpu1: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,MWAIT,CX16,POPCNT,NXE,MMXX,FFXSR,LONG,3DNOW2,3DNOW cpu1: 64KB 64b/line 2-way I-cache, 64KB 64b/line 2-way D-cache, 512KB 64b/line 16-way L2 cache cpu1: ITLB 32 4KB entries fully associative, 16 4MB entries fully associative cpu1: DTLB 48 4KB entries fully associative, 48 4MB entries fully associative cpu2 at mainbus0: apid 2 (application processor) cpu2: AMD Phenom(tm) II X4 955 Processor, 3200.15 MHz cpu2: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,MWAIT,CX16,POPCNT,NXE,MMXX,FFXSR,LONG,3DNOW2,3DNOW cpu2: 64KB 64b/line 2-way I-cache, 64KB 64b/line 2-way D-cache, 512KB 64b/line 16-way L2 cache cpu2: ITLB 32 4KB entries fully associative, 16 4MB entries fully associative cpu2: DTLB 48 4KB entries fully associative, 48 4MB entries fully associative cpu3 at mainbus0: apid 3 (application processor) cpu3: AMD Phenom(tm) II X4 955 Processor, 3200.15 MHz cpu3: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,MWAIT,CX16,POPCNT,NXE,MMXX,FFXSR,LONG,3DNOW2,3DNOW cpu3: 64KB 64b/line 2-way I-cache, 64KB 64b/line 2-way D-cache, 512KB 64b/line 16-way L2 cache cpu3: ITLB 32 4KB entries fully associative, 16 4MB entries fully associative cpu3: DTLB 48 4KB entries fully associative, 48 4MB entries fully associative ioapic0 at mainbus0: apid 4 pa 0xfec0, version 21, 24 pins acpimcfg0 at acpi0 addr 0xe000, bus 0-255 acpihpet0 at acpi0: 14318180 Hz acpiprt0 at acpi0: bus 0 (PCI0) acpiprt1 at acpi0: bus 1 (P0P1) acpiprt2 at acpi0: bus -1 (PCE2) acpiprt3 at acpi0: bus -1 (PCE3) acpiprt4 at acpi0: bus -1 (PCE4) acpiprt5 at acpi0: bus 2 (PCE5) acpiprt6 at acpi0: bus -1 (PCE6) acpiprt7 at acpi0: bus -1 (PCE7) acpiprt8 at acpi0: bus -1 (PCE9) acpiprt9 at acpi0: bus -1 (PCEA) acpiprt10 at acpi0: bus -1 (PCEB) acpiprt11 at acpi0: bus -1 (PCEC) acpiprt12 at acpi0: bus 3 (P0PC) acpicpu0 at acpi0: PSS acpicpu1 at acpi0: PSS acpicpu2 at acpi0: PSS acpicpu3 at acpi0: PSS acpibtn0 at acpi0: PWRB pci0 at mainbus0 bus 0 pchb0 at pci0 dev 0 function 0 AMD RS780 Host rev 0x00 ppb0 at pci0 dev 1 function 0 AMD RS780 PCIE rev 0x00 pci1 at ppb0 bus 1 vga1 at pci1 dev 5 function 0 vendor ATI, unknown product 0x9616 rev 0x00 wsdisplay0 at vga1 mux 1: console (80x25, vt100 emulation) wsdisplay0: screen 1-5 added (80x25, vt100 emulation) ppb1 at pci0 dev 5 function 0 AMD RS780 PCIE rev 0x00: apic 4 int 17 pci2 at ppb1 bus 2 alc0 at pci2 dev 0 function 0 Attansic Technology L1C rev 0xc0: apic 4 int 17, address 6c:62:6d:de:03:76 atphy0 at alc0 phy 0: F1 10/100/1000 PHY, rev. 11 ahci0 at pci0 dev 17 function 0 ATI SBx00 SATA rev 0x00:
Re: alc(4) support for Atheros AR815x
I mean... my alc0 still works... On Sun, May 1, 2011 at 2:49 PM, Abel Abraham Camarillo Ojeda acam...@verlet.org wrote: On Sun, May 1, 2011 at 2:10 PM, Stuart Henderson s...@spacehopper.org wrote: On 2011/05/01 18:35, Edd Barrett wrote: I have acquired a netboot (packard bell dot s), which I think uses this NIC. Is there an updated diff? Yes I just took the 2 minutes it took to apply it and fix the minor conflicts and linewrapping issue with the diff. Untested beyond it builds. Test reports and dmesg lines from existing working alc(4) L1C and L2C wanted. If it makes new chips work that's a bonus, but the important thing is making sure it doesn't break something that already works. Doesn't seem any point disabling interrupts in the ISR though. I haven't touched that in this diff but that should probably be done too. Tested here on amd64.mp: No relevant changes in dmesg (i guess)... Old dmesg: OpenBSD 4.9-current (kobj) #0: Tue Apr 26 18:02:56 CDT 2011 B B root@maetel.00z:/usr/kobj real mem = 1608056832 (1533MB) avail mem = 1551200256 (1479MB) mainbus0 at root bios0 at mainbus0: SMBIOS rev. 2.6 @ 0xfd400 (50 entries) bios0: vendor American Megatrends Inc. version V1.3 date 11/15/2010 bios0: MSI MS-7623 acpi0 at bios0: rev 0 acpi0: sleep states S0 S3 S4 S5 acpi0: tables DSDT FACP APIC MCFG OEMB SRAT HPET SSDT acpi0: wakeup devices PCE2(S4) PCE3(S4) PCE4(S4) PCE5(S4) PCE6(S4) PCE7(S4) PCE9(S4) PCEA(S4) PCEB(S4) PCEC(S4) SBAZ(S4) PSKE(S4) PSMS(S4) ECIR(S4) PS2K(S3) PS2M(S3) P0PC(S4) UHC1(S4) UHC2(S4) UHC3(S4) USB4(S4) UHC5(S4) UHC6(S4) UHC7(S4) PWRB(S3) acpitimer0 at acpi0: 3579545 Hz, 32 bits acpimadt0 at acpi0 addr 0xfee0: PC-AT compat cpu0 at mainbus0: apid 0 (boot processor) cpu0: AMD Phenom(tm) II X4 955 Processor, 3200.65 MHz cpu0: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUS H,MMX,FXSR,SSE,SSE2,HTT,SSE3,MWAIT,CX16,POPCNT,NXE,MMXX,FFXSR,LONG,3DNOW2,3DN OW cpu0: 64KB 64b/line 2-way I-cache, 64KB 64b/line 2-way D-cache, 512KB 64b/line 16-way L2 cache cpu0: ITLB 32 4KB entries fully associative, 16 4MB entries fully associative cpu0: DTLB 48 4KB entries fully associative, 48 4MB entries fully associative cpu0: apic clock running at 200MHz cpu1 at mainbus0: apid 1 (application processor) cpu1: AMD Phenom(tm) II X4 955 Processor, 3200.16 MHz cpu1: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUS H,MMX,FXSR,SSE,SSE2,HTT,SSE3,MWAIT,CX16,POPCNT,NXE,MMXX,FFXSR,LONG,3DNOW2,3DN OW cpu1: 64KB 64b/line 2-way I-cache, 64KB 64b/line 2-way D-cache, 512KB 64b/line 16-way L2 cache cpu1: ITLB 32 4KB entries fully associative, 16 4MB entries fully associative cpu1: DTLB 48 4KB entries fully associative, 48 4MB entries fully associative cpu2 at mainbus0: apid 2 (application processor) cpu2: AMD Phenom(tm) II X4 955 Processor, 3200.15 MHz cpu2: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUS H,MMX,FXSR,SSE,SSE2,HTT,SSE3,MWAIT,CX16,POPCNT,NXE,MMXX,FFXSR,LONG,3DNOW2,3DN OW cpu2: 64KB 64b/line 2-way I-cache, 64KB 64b/line 2-way D-cache, 512KB 64b/line 16-way L2 cache cpu2: ITLB 32 4KB entries fully associative, 16 4MB entries fully associative cpu2: DTLB 48 4KB entries fully associative, 48 4MB entries fully associative cpu3 at mainbus0: apid 3 (application processor) cpu3: AMD Phenom(tm) II X4 955 Processor, 3200.15 MHz cpu3: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUS H,MMX,FXSR,SSE,SSE2,HTT,SSE3,MWAIT,CX16,POPCNT,NXE,MMXX,FFXSR,LONG,3DNOW2,3DN OW cpu3: 64KB 64b/line 2-way I-cache, 64KB 64b/line 2-way D-cache, 512KB 64b/line 16-way L2 cache cpu3: ITLB 32 4KB entries fully associative, 16 4MB entries fully associative cpu3: DTLB 48 4KB entries fully associative, 48 4MB entries fully associative ioapic0 at mainbus0: apid 4 pa 0xfec0, version 21, 24 pins acpimcfg0 at acpi0 addr 0xe000, bus 0-255 acpihpet0 at acpi0: 14318180 Hz acpiprt0 at acpi0: bus 0 (PCI0) acpiprt1 at acpi0: bus 1 (P0P1) acpiprt2 at acpi0: bus -1 (PCE2) acpiprt3 at acpi0: bus -1 (PCE3) acpiprt4 at acpi0: bus -1 (PCE4) acpiprt5 at acpi0: bus 2 (PCE5) acpiprt6 at acpi0: bus -1 (PCE6) acpiprt7 at acpi0: bus -1 (PCE7) acpiprt8 at acpi0: bus -1 (PCE9) acpiprt9 at acpi0: bus -1 (PCEA) acpiprt10 at acpi0: bus -1 (PCEB) acpiprt11 at acpi0: bus -1 (PCEC) acpiprt12 at acpi0: bus 3 (P0PC) acpicpu0 at acpi0: PSS acpicpu1 at acpi0: PSS acpicpu2 at acpi0: PSS acpicpu3 at acpi0: PSS acpibtn0 at acpi0: PWRB pci0 at mainbus0 bus 0 pchb0 at pci0 dev 0 function 0 AMD RS780 Host rev 0x00 ppb0 at pci0 dev 1 function 0 AMD RS780 PCIE rev 0x00 pci1 at ppb0 bus 1 vga1 at pci1 dev 5 function 0 vendor ATI, unknown product 0x9616 rev 0x00 wsdisplay0 at vga1 mux 1: console (80x25, vt100 emulation) wsdisplay0: screen 1-5 added (80x25, vt100 emulation) ppb1 at pci0 dev 5 function 0 AMD RS780 PCIE rev 0x00: apic 4 int 17 pci2 at ppb1 bus 2 alc0 at
Re: alc(4) support for Atheros AR815x
On Sun, May 01, 2011 at 08:10:56PM +0100, Stuart Henderson wrote: On 2011/05/01 18:35, Edd Barrett wrote: I have acquired a netboot (packard bell dot s), which I think uses this NIC. Is there an updated diff? Yes I just took the 2 minutes it took to apply it and fix the minor conflicts and linewrapping issue with the diff. Untested beyond it builds. Stu's diff seems to work, although the first time i booted my bsd.rd I was unable to install due to: alc0: watchdog timeout (missed link) I rebooted and tried again and it all went smoothly. The system booted multiuser and I am able to install packages over the wire. The BCM4313 wireless is unsupported, but that is another story. If anyone knows anything about support for this card can they mail me off-list. Cheers OpenBSD 4.9-current (GENERIC.MP) #0: Mon May 2 00:51:41 BST 2011 root@ire.config:/usr/src/sys/arch/i386/compile/GENERIC.MP cpu0: Intel(R) Atom(TM) CPU N455 @ 1.66GHz (GenuineIntel 686-class) 1.67 GHz cpu0: FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,SBF,SSE3,MWAIT,DS-CPL,EST,TM2,SSSE3,CX16,xTPR,PDCM,MOVBE real mem = 1061302272 (1012MB) avail mem = 1033764864 (985MB) mainbus0 at root bios0 at mainbus0: AT/286+ BIOS, date 01/10/11, SMBIOS rev. 2.6 @ 0xe8080 (36 entries) bios0: vendor Packard Bell version V3.14(DDR3) date 01/10/2011 bios0: Packard Bell DOTS E2 acpi0 at bios0: rev 2 acpi0: sleep states S0 S3 S4 S5 acpi0: tables DSDT FACP HPET APIC MCFG SLIC BOOT SSDT WDAT acpi0: wakeup devices UHC1(S3) UHC2(S3) UHC3(S3) UHC4(S3) ECHI(S3) EXP1(S4) EXP2(S0) EXP3(S4) EXP4(S4) AZAL(S4) acpitimer0 at acpi0: 3579545 Hz, 24 bits acpihpet0 at acpi0: 14318179 Hz acpimadt0 at acpi0 addr 0xfee0: PC-AT compat cpu0 at mainbus0: apid 0 (boot processor) cpu0: apic clock running at 166MHz cpu1 at mainbus0: apid 1 (application processor) cpu1: Intel(R) Atom(TM) CPU N455 @ 1.66GHz (GenuineIntel 686-class) 1.67 GHz cpu1: FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,SBF,SSE3,MWAIT,DS-CPL,EST,TM2,SSSE3,CX16,xTPR,PDCM,MOVBE ioapic0 at mainbus0: apid 4 pa 0xfec0, version 20, 24 pins ioapic0: misconfigured as apic 0, remapped to apid 4 acpimcfg0 at acpi0 addr 0xe000, bus 0-255 acpiprt0 at acpi0: bus 0 (PCI0) acpiprt1 at acpi0: bus 1 (EXP1) acpiprt2 at acpi0: bus 2 (EXP2) acpiprt3 at acpi0: bus -1 (EXP3) acpiprt4 at acpi0: bus -1 (EXP4) acpiec0 at acpi0 acpicpu0 at acpi0: C3, C2, C1, PSS acpicpu1 at acpi0: C3, C2, C1, PSS acpipwrres0 at acpi0: FN00 acpitz0 at acpi0: critical temperature 100 degC acpibtn0 at acpi0: PWRB acpibtn1 at acpi0: SLPB acpibtn2 at acpi0: LID0 acpibat0 at acpi0: BAT0 model 13848628933250113 type Lion oem SANYO acpiac0 at acpi0: AC unit online acpivideo0 at acpi0: OVGA acpivout0 at acpivideo0: DD02 bios0: ROM list: 0xc/0xda00! 0xce000/0x1000 cpu0: Enhanced SpeedStep 1663 MHz: speeds: 1666, 1333, 1000 MHz pci0 at mainbus0 bus 0: configuration mode 1 (bios) pchb0 at pci0 dev 0 function 0 Intel Pineview DMI rev 0x00 vga1 at pci0 dev 2 function 0 Intel Pineview Video rev 0x00 wsdisplay0 at vga1 mux 1: console (80x25, vt100 emulation) wsdisplay0: screen 1-5 added (80x25, vt100 emulation) intagp0 at vga1 agp0 at intagp0: aperture at 0x4000, size 0x1000 inteldrm0 at vga1: apic 4 int 16 drm0 at inteldrm0 Intel Pineview Video rev 0x00 at pci0 dev 2 function 1 not configured azalia0 at pci0 dev 27 function 0 Intel 82801GB HD Audio rev 0x02: apic 4 int 19 azalia0: codecs: Realtek ALC272 audio0 at azalia0 ppb0 at pci0 dev 28 function 0 Intel 82801GB PCIE rev 0x02: apic 4 int 16 pci1 at ppb0 bus 1 alc0 at pci1 dev 0 function 0 Attansic Technology L2C rev 0xc1: apic 4 int 16, address 1c:75:08:d5:53:c4 atphy0 at alc0 phy 0: F2 10/100 PHY, rev. 4 ppb1 at pci0 dev 28 function 1 Intel 82801GB PCIE rev 0x02: apic 4 int 17 pci2 at ppb1 bus 2 Broadcom BCM4313 rev 0x01 at pci2 dev 0 function 0 not configured uhci0 at pci0 dev 29 function 0 Intel 82801GB USB rev 0x02: apic 4 int 18 uhci1 at pci0 dev 29 function 1 Intel 82801GB USB rev 0x02: apic 4 int 20 uhci2 at pci0 dev 29 function 2 Intel 82801GB USB rev 0x02: apic 4 int 21 uhci3 at pci0 dev 29 function 3 Intel 82801GB USB rev 0x02: apic 4 int 22 ehci0 at pci0 dev 29 function 7 Intel 82801GB USB rev 0x02: apic 4 int 22 usb0 at ehci0: USB revision 2.0 uhub0 at usb0 Intel EHCI root hub rev 2.00/1.00 addr 1 ppb2 at pci0 dev 30 function 0 Intel 82801BAM Hub-to-PCI rev 0xe2 pci3 at ppb2 bus 5 pcib0 at pci0 dev 31 function 0 Intel Tigerpoint LPC rev 0x02 ahci0 at pci0 dev 31 function 2 Intel 82801GR AHCI rev 0x02: apic 4 int 17, AHCI 1.1 ahci0: PHY offline on port 1 scsibus0 at ahci0: 32 targets sd0 at scsibus0 targ 0 lun 0: ATA, Hitachi HTS54502, PB2O SCSI3 0/direct fixed naa.5000cca62bf2b42f sd0: 238475MB, 512 bytes/sec, 488397168 sec total ichiic0 at pci0 dev 31 function 3 Intel 82801GB SMBus rev 0x02: apic 4 int 17 iic0 at ichiic0 spdmem0 at
Re: alc(4) support for Atheros AR815x
On Mon, May 02, 2011 at 01:16:55AM +0100, Edd Barrett wrote: On Sun, May 01, 2011 at 08:10:56PM +0100, Stuart Henderson wrote: On 2011/05/01 18:35, Edd Barrett wrote: I have acquired a netboot (packard bell dot s), which I think uses this NIC. Is there an updated diff? Yes I just took the 2 minutes it took to apply it and fix the minor conflicts and linewrapping issue with the diff. Untested beyond it builds. Stu's diff seems to work, although the first time i booted my bsd.rd I was unable to install due to: alc0: watchdog timeout (missed link) ^ this seems to happen quite frequently. I just had the same issue again on the installed system. -- Best Regards Edd Barrett http://www.theunixzoo.co.uk
Re: alc(4) support for Atheros AR815x
On Tue, Jan 25, 2011 at 06:24:28PM +0800, Kevin Lo wrote: Hi, The following diff adds support for Atheros AR8151/AR8152 chipsets; mostly from FreeBSD. It also fixes an issue i386/6311. Tested on Acer AOD255E. Is there an updated diff for this? It seems this never made it into the tree.
Re: alc(4) support for Atheros AR815x
On 01/25/11 11:24, Kevin Lo wrote: Hi, The following diff adds support for Atheros AR8151/AR8152 chipsets; mostly from FreeBSD. It also fixes an issue i386/6311. Tested on Acer AOD255E. Tried yesterday on EeePC 1005PX, some comments inline. @@ -515,6 +694,20 @@ alc_attach(struct device *parent, struct val = CSR_READ_4(sc, ALC_PEX_UNC_ERR_SEV); val= ~(PEX_UNC_ERR_SEV_DLP | PEX_UNC_ERR_SEV_FCP); CSR_WRITE_4(sc, ALC_PEX_UNC_ERR_SEV, val); + CSR_WRITE_4(sc, ALC_LTSSM_ID_CFG, + CSR_READ_4(sc, ALC_LTSSM_ID_CFG) ~LTSSM_ID_WRO_ENB); + CSR_WRITE_4(sc, ALC_PCIE_PHYMISC, + CSR_READ_4(sc, ALC_PCIE_PHYMISC) | + PCIE_PHYMISC_FORCE_RCV_DET); + if (sc-sc_product == PCI_PRODUCT_ATTANSIC_L2C_1 + sc-alc_rev == ATHEROS_AR8152_B_V10) { Using sc-sc_product and sc-alc_rev, but they are initialized later. @@ -551,12 +747,39 @@ alc_attach(struct device *parent, struct * used in AR8132 can't establish gigabit link even if it * shows the same PHY model/revision number of AR8131. */ - if (PCI_PRODUCT(pa-pa_id) == PCI_PRODUCT_ATTANSIC_L2C) - sc-alc_flags |= ALC_FLAG_FASTETHER | ALC_FLAG_JUMBO; - else - sc-alc_flags |= ALC_FLAG_JUMBO | ALC_FLAG_ASPM_MON; + sc-sc_product = PCI_PRODUCT(pa-pa_id); Here is sc-sc_product, sc-alc_rev initialized line 569 of if_alc.c r1.9 alc_newbuf should always use M_DONTWAIT (get rid of init), see http://marc.info/?l=openbsd-techm=129639859909043w=2
Re: alc(4) support for Atheros AR815x
See my comments inline. Damien | void | -alc_aspm(struct alc_softc *sc) | +alc_aspm(struct alc_softc *sc, int media) | { | uint32_t pmcfg; | + uint16_t linkcfg; | | pmcfg = CSR_READ_4(sc, ALC_PM_CFG); | + if ((sc-alc_flags (ALC_FLAG_APS | ALC_FLAG_PCIE)) == | + (ALC_FLAG_APS | ALC_FLAG_PCIE)) | + linkcfg = CSR_READ_2(sc, sc-alc_expcap + | + PCI_PCIE_LCSR); You should probably use pci_conf_read() here. Just turn linkcfg into a pcireg_t. | + else | + linkcfg = 0; | pmcfg = ~PM_CFG_SERDES_PD_EX_L1; | - pmcfg |= PM_CFG_SERDES_BUDS_RX_L1_ENB; | - pmcfg |= PM_CFG_SERDES_L1_ENB; | - pmcfg = ~PM_CFG_L1_ENTRY_TIMER_MASK; | + pmcfg = ~(PM_CFG_L1_ENTRY_TIMER_MASK | PM_CFG_LCKDET_TIMER_MASK); | pmcfg |= PM_CFG_MAC_ASPM_CHK; | + pmcfg |= (PM_CFG_LCKDET_TIMER_DEFAULT | PM_CFG_LCKDET_TIMER_SHIFT); | + pmcfg = ~(PM_CFG_ASPM_L1_ENB | PM_CFG_ASPM_L0S_ENB); | + | + if ((sc-alc_flags ALC_FLAG_APS) != 0) { | + /* Disable extended sync except AR8152 B v1.0 */ | + linkcfg = ~0x80; | + if (sc-sc_product == PCI_PRODUCT_ATTANSIC_L2C_1 | + sc-alc_rev == ATHEROS_AR8152_B_V10) | + linkcfg |= 0x80; I recently added the definition of the Extended Synch bit to pcireg.h so you could use PCI_PCIE_LCSR_ES instead of 0x80 here. | + CSR_WRITE_2(sc, sc-alc_expcap + PCI_PCIE_LCSR, | + linkcfg); and use pci_conf_write() here. | + pmcfg = ~(PM_CFG_EN_BUFS_RX_L0S | PM_CFG_SA_DLY_ENB | | + PM_CFG_HOTRST); | + pmcfg |= (PM_CFG_L1_ENTRY_TIMER_DEFAULT | + PM_CFG_L1_ENTRY_TIMER_SHIFT); | + pmcfg = ~PM_CFG_PM_REQ_TIMER_MASK; | + pmcfg |= (PM_CFG_PM_REQ_TIMER_DEFAULT | + PM_CFG_PM_REQ_TIMER_SHIFT); | + pmcfg |= PM_CFG_SERDES_PD_EX_L1 | PM_CFG_PCIE_RECV; | + } | + | if ((sc-alc_flags ALC_FLAG_LINK) != 0) { | - pmcfg |= PM_CFG_SERDES_PLL_L1_ENB; | - pmcfg = ~PM_CFG_CLK_SWH_L1; | - pmcfg = ~PM_CFG_ASPM_L1_ENB; | - pmcfg = ~PM_CFG_ASPM_L0S_ENB; | + if ((sc-alc_flags ALC_FLAG_L0S) != 0) | + pmcfg |= PM_CFG_ASPM_L0S_ENB; | + if ((sc-alc_flags ALC_FLAG_L1S) != 0) | + pmcfg |= PM_CFG_ASPM_L1_ENB; | + if ((sc-alc_flags ALC_FLAG_APS) != 0) { | + if (sc-sc_product == PCI_PRODUCT_ATTANSIC_L2C_1) | + pmcfg = ~PM_CFG_ASPM_L0S_ENB; | + pmcfg = ~(PM_CFG_SERDES_L1_ENB | | + PM_CFG_SERDES_PLL_L1_ENB | | + PM_CFG_SERDES_BUDS_RX_L1_ENB); | + pmcfg |= PM_CFG_CLK_SWH_L1; | + if (media == IFM_100_TX || media == IFM_1000_T) { | + pmcfg = ~PM_CFG_L1_ENTRY_TIMER_MASK; | + switch (sc-sc_product) { | + case PCI_PRODUCT_ATTANSIC_L2C_1: | + pmcfg |= (7 | + PM_CFG_L1_ENTRY_TIMER_SHIFT); | + break; | + case PCI_PRODUCT_ATTANSIC_L1D_1: | + case PCI_PRODUCT_ATTANSIC_L2C_2: | + pmcfg |= (4 | + PM_CFG_L1_ENTRY_TIMER_SHIFT); | + break; | + default: | + pmcfg |= (15 | + PM_CFG_L1_ENTRY_TIMER_SHIFT); | + break; | + } | + } | + } else { | + pmcfg |= PM_CFG_SERDES_L1_ENB | | + PM_CFG_SERDES_PLL_L1_ENB | | + PM_CFG_SERDES_BUDS_RX_L1_ENB; | + pmcfg = ~(PM_CFG_CLK_SWH_L1 | | + PM_CFG_ASPM_L1_ENB | PM_CFG_ASPM_L0S_ENB); | + } | } else { | - pmcfg = ~PM_CFG_SERDES_PLL_L1_ENB; | + pmcfg = ~(PM_CFG_SERDES_BUDS_RX_L1_ENB | PM_CFG_SERDES_L1_ENB | | + PM_CFG_SERDES_PLL_L1_ENB); | pmcfg |= PM_CFG_CLK_SWH_L1; | - pmcfg = ~PM_CFG_ASPM_L1_ENB; | - pmcfg = ~PM_CFG_ASPM_L0S_ENB; | + if ((sc-alc_flags ALC_FLAG_L1S) != 0) | + pmcfg |= PM_CFG_ASPM_L1_ENB; | } | CSR_WRITE_4(sc, ALC_PM_CFG, pmcfg); | }