On Tue, 20 Apr 2010 23:22:21 -0400 Brad <[email protected]> wrote:

> A diff for the ep(4) 3Com EtherLink III driver to clean up the ioctl
> handler code a bit and eliminate unnecessary resets when
> reconfiguring IP addresses.

First I tried to establish a baseline *without* your patch only to find
the 3C595-TX ep(4) cards I have don't work at all. I have a half dozen
of these sitting unused, so if any developer wants one for testing,
contact me off-list.

Even without it working to start with, I even tried your patch but it
didn't fix the 3c595-tx cards. I doubt I have any other cards supported
by ep(4), but I'll look. Copious notes as follows.

        jcr

------------------------------------------------------------------------
NOTE: The 3Com 3C595-TX cards will only do 10base-T half or full duplex, 
      and 100base-TX half duplex. It will not do 100Base-TX full duplex.
      This is a documeted limitation of the card itself.

Tried two different 3C595-TX cards.
Tried connecting the 3C595-TX cards to two different 10/100 switches.
Tried with and without gem kernel.
Tried with and without brad's patch applied.
Tried a xl(4) 3C905-TX card in the PCI slot to make sure it's working.

------------------------------------------------------------------------
Tried (via DOS) configuring the card to "Auto"
    A:\> 3C59XCFG.EXE CONFIGURE /AUTO

failed with
    # cat /etc/hostname.ep0
    inet 10.10.10.48 255.255.255.0 10.10.10.255
failed with
    # cat /etc/hostname.ep0
    inet 10.10.10.48 255.255.255.0 10.10.10.255 media autoselect
failed with
    # cat /etc/hostname.ep0
    inet 10.10.10.48 255.255.255.0 10.10.10.255 media 10baseT mediaopt 
half-duplex
failed with
    # cat /etc/hostname.ep0
    inet 10.10.10.48 255.255.255.0 10.10.10.255 media 10baseT mediaopt 
full-duplex
failed with
    # cat /etc/hostname.ep0
    inet 10.10.10.48 255.255.255.0 10.10.10.255 media 100baseTX mediaopt 
half-duplex

When configured to /AUTO, the card comes up at 100basetx (half-duplex)
regardless of /etc/hostname.ep0 settings, but it doesn't work.

    # cat /etc/hostname.ep0
    inet 10.10.10.48 255.255.255.0 10.10.10.255 media 10baseT mediaopt 
half-duplex
    # ifconfig ep0
    ep0: flags=8863<UP,BROADCAST,NOTRAILERS,RUNNING,SIMPLEX,MULTICAST> mtu 1500
            lladdr 00:a0:24:50:3f:ea
            priority: 0
            groups: egress
            media: Ethernet 100baseTX
            status: active
            inet 10.10.10.48 netmask 0xffffff00 broadcast 10.10.10.255
            inet6 fe80::2a0:24ff:fe50:3fea%ep0 prefixlen 64 scopeid 0x1

------------------------------------------------------------------------
Tried (via DOS) configuring the card to 10BASE-T full-duplex
    A:\> 3C59XCFG.EXE CONFIGURE /TR:10BASE-T /FULLDUPLEX:ENABLE

failed with
    # cat /etc/hostname.ep0
    inet 10.10.10.48 255.255.255.0 10.10.10.255
failed with
    # cat /etc/hostname.ep0
    inet 10.10.10.48 255.255.255.0 10.10.10.255 media autoselect
failed with
    # cat /etc/hostname.ep0
    inet 10.10.10.48 255.255.255.0 10.10.10.255 media 10baseT mediaopt 
full-duplex


------------------------------------------------------------------------
Tried (via DOS) configuring the card to 10BASE-T half-duplex
    A:\> 3C59XCFG.EXE CONFIGURE /TR:10BASE-T /FULLDUPLEX:DISABLE
failed with
    # cat /etc/hostname.ep0
    inet 10.10.10.48 255.255.255.0 10.10.10.255
failed with
    # cat /etc/hostname.ep0
    inet 10.10.10.48 255.255.255.0 10.10.10.255 media autoselect
failed with
    # cat /etc/hostname.ep0
    inet 10.10.10.48 255.255.255.0 10.10.10.255 media 10baseT mediaopt 
half-duplex

------------------------------------------------------------------------
Tried (via DOS) configuring the card to 100BASE-TX half-duplex
    A:\> 3C59XCFG.EXE CONFIGURE /TR:100BASE-TX /FULLDUPLEX:DISABLE

failed with
    # cat /etc/hostname.ep0
    inet 10.10.10.48 255.255.255.0 10.10.10.255
failed with
    # cat /etc/hostname.ep0
    inet 10.10.10.48 255.255.255.0 10.10.10.255 media autoselect
failed with
    # cat /etc/hostname.ep0
    inet 10.10.10.48 255.255.255.0 10.10.10.255 media 100baseTX mediaopt 
half-duplex

------------------------------------------------------------------------
    # cat /usr/src/sys/arch/i386/conf/GENERIC_GEM
    # GENERIC with INTELDRM_GEM
    include         "arch/i386/conf/GENERIC"
    option          INTELDRM_GEM
    option          DRMDEBUG
    option          DRMLOCKDEBUG
    option          EP_DEBUG
    # 
    # rm -fr /usr/obj/*
    # cd /usr/src/sys/dev/ic
    # patch -C </home/jcr/brad-ep_ioclt_handler.diff
    # patch </home/jcr/brad-ep_ioclt_handler.diff
    # cd /usr/src/sys/arch/i386/conf
    # config GENRIC_GEM
    # cd ../compile/GENERIC_GEM
    # mean make clean && mean make depend && mean make

------------------------------------------------------------------------
OpenBSD 4.7-current (GENERIC_GEM) #3: Mon Apr 26 10:28:56 PDT 2010
    [email protected]:/usr/src/sys/arch/i386/compile/GENERIC_GEM
cpu0: Intel(R) Pentium(R) 4 CPU 2.40GHz ("GenuineIntel" 686-class) 2.40 GHz
cpu0: 
FPU,V86,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,CNXT-ID,xTPR
real mem  = 2137550848 (2038MB)
avail mem = 2060009472 (1964MB)
mainbus0 at root
bios0 at mainbus0: AT/286+ BIOS, date 05/10/05, BIOS32 rev. 0 @ 0xfd844, SMBIOS 
rev. 2.31 @ 0xf00f0 (51 entries)
bios0: vendor IBM version "24KT55AUS" date 05/10/2005
bios0: IBM 8310XXS
acpi0 at bios0: rev 0
acpi0: tables DSDT FACP TCPA APIC BOOT
acpi0: wakeup devices USB1(S3) USB2(S3) USB3(S3) USBE(S3) SLOT(S5) KBC_(S3) 
COMA(S5) COMB(S5)
acpitimer0 at acpi0: 3579545 Hz, 24 bits
acpimadt0 at acpi0 addr 0xfee00000: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: apic clock running at 132MHz
ioapic0 at mainbus0: apid 1 pa 0xfec00000, version 20, 24 pins
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus 2 (SLOT)
acpiprt2 at acpi0: bus -1 (AGP_)
acpicpu0 at acpi0
acpitz0 at acpi0: critical temperature 105 degC
acpibtn0 at acpi0: PWRB
bios0: ROM list: 0xc0000/0xb400 0xcb800/0x4800 0xe0000/0x10000!
pci0 at mainbus0 bus 0: configuration mode 1 (bios)
pchb0 at pci0 dev 0 function 0 "Intel 82845G Host" rev 0x01
vga1 at pci0 dev 2 function 0 "Intel 82845G Video" rev 0x01
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 0x88000000, size 0x8000000
inteldrm0 at vga1: apic 1 int 16 (irq 11)
drm0 at inteldrm0
uhci0 at pci0 dev 29 function 0 "Intel 82801DB USB" rev 0x01: apic 1 int 16 
(irq 11)
uhci1 at pci0 dev 29 function 1 "Intel 82801DB USB" rev 0x01: apic 1 int 19 
(irq 10)
uhci2 at pci0 dev 29 function 2 "Intel 82801DB USB" rev 0x01: apic 1 int 18 
(irq 5)
ehci0 at pci0 dev 29 function 7 "Intel 82801DB USB" rev 0x01: apic 1 int 23 
(irq 9)
usb0 at ehci0: USB revision 2.0
uhub0 at usb0 "Intel EHCI root hub" rev 2.00/1.00 addr 1
ppb0 at pci0 dev 30 function 0 "Intel 82801BA Hub-to-PCI" rev 0x81
pci1 at ppb0 bus 2
fxp0 at pci1 dev 8 function 0 "Intel PRO/100 VE" rev 0x81, i82562: apic 1 int 
20 (irq 11), address 00:09:6b:f3:41:ad
inphy0 at fxp0 phy 1: i82562EM 10/100 PHY, rev. 0
ep0 at pci1 dev 9 function 0 "3Com 3c595 100Base-TX" rev 0x00: address 
00:a0:24:50:3f:ea, utp/100-TX default utp/autoselect apic 1 int 21 (irq 9)
pciide0 at pci1 dev 10 function 0 "CMD Technology SiI3512 SATA" rev 0x01: DMA
pciide0: using apic 1 int 22 (irq 11) for native-PCI interrupt
pciide0: port 1: device present, speed: 1.5Gb/s
wd0 at pciide0 channel 1 drive 0: <HDS722525VLSA80>
wd0: 16-sector PIO, LBA48, 238475MB, 488397168 sectors
wd0(pciide0:1:0): using BIOS timings, Ultra-DMA mode 5
cbb0 at pci1 dev 12 function 0 "Ricoh 5C475 CardBus" rev 0x81: apic 1 int 20 
(irq 11)
cardslot0 at cbb0 slot 0 flags 0
cardbus0 at cardslot0: bus 3 device 0 cacheline 0x0, lattimer 0x20
pcmcia0 at cardslot0
ichpcib0 at pci0 dev 31 function 0 "Intel 82801DB LPC" rev 0x01
pciide1 at pci0 dev 31 function 1 "Intel 82801DB IDE" rev 0x01: DMA, channel 0 
configured to compatibility, channel 1 configured to compatibility
pciide1: channel 0 ignored (disabled)
atapiscsi0 at pciide1 channel 1 drive 0
scsibus0 at atapiscsi0: 2 targets
cd0 at scsibus0 targ 0 lun 0: <LITE-ON, LTR-48246S, SUS5> ATAPI 5/cdrom 
removable
cd0(pciide1:1:0): using PIO mode 4, Ultra-DMA mode 2
ichiic0 at pci0 dev 31 function 3 "Intel 82801DB SMBus" rev 0x01: apic 1 int 17 
(irq 9)
iic0 at ichiic0
admtemp0 at iic0 addr 0x4c: adm1032
spdmem0 at iic0 addr 0x50: 1GB DDR SDRAM non-parity PC2700CL2.5
spdmem1 at iic0 addr 0x51: 1GB DDR SDRAM non-parity PC2700CL2.5
auich0 at pci0 dev 31 function 5 "Intel 82801DB AC97" rev 0x01: apic 1 int 17 
(irq 9), ICH4 AC97
ac97: codec id 0x41445374 (Analog Devices AD1981B)
ac97: codec features headphone, 20 bit DAC, No 3D Stereo
audio0 at auich0
usb1 at uhci0: USB revision 1.0
uhub1 at usb1 "Intel UHCI root hub" rev 1.00/1.00 addr 1
usb2 at uhci1: USB revision 1.0
uhub2 at usb2 "Intel UHCI root hub" rev 1.00/1.00 addr 1
usb3 at uhci2: USB revision 1.0
uhub3 at usb3 "Intel UHCI root hub" rev 1.00/1.00 addr 1
isa0 at ichpcib0
isadma0 at isa0
com0 at isa0 port 0x3f8/8 irq 4: ns16550a, 16 byte fifo
com1 at isa0 port 0x2f8/8 irq 3: ns16550a, 16 byte fifo
pckbc0 at isa0 port 0x60/5
pckbd0 at pckbc0 (kbd slot)
pckbc0: using irq 1 for kbd slot
wskbd0 at pckbd0: console keyboard, using wsdisplay0
pms0 at pckbc0 (aux slot)
pckbc0: using irq 12 for aux slot
wsmouse0 at pms0 mux 0
pcppi0 at isa0 port 0x61
midi0 at pcppi0: <PC speaker>
spkr0 at pcppi0
lpt0 at isa0 port 0x378/4 irq 7
npx0 at isa0 port 0xf0/16: reported by CPUID; using exception 16
fdc0 at isa0 port 0x3f0/6 irq 6 drq 2
fd0 at fdc0 drive 0: 1.44MB 80 cyl, 2 head, 18 sec
mtrr: Pentium Pro MTRR support
vscsi0 at root
scsibus1 at vscsi0: 256 targets
softraid0 at root
root on wd0a swap on wd0b dump on wd0b
ep0:  read 0x1b, 0x101 from EP_W3_CONFIG register
epsetmedia: ep0: medium 0x0, 0x101 to EP_W3_CONFIG
ep0:  read 0x1b, 0x101 from EP_W3_CONFIG register
epsetmedia: ep0: medium 0x0, 0x101 to EP_W3_CONFIG
ep0:  read 0x1b, 0x101 from EP_W3_CONFIG register
epsetmedia: ep0: medium 0x0, 0x101 to EP_W3_CONFIG
ep0:  read 0x1b, 0x101 from EP_W3_CONFIG register
epsetmedia: ep0: medium 0x0, 0x101 to EP_W3_CONFIG
ep0:  read 0x1b, 0x101 from EP_W3_CONFIG register
epsetmedia: ep0: medium 0x0, 0x101 to EP_W3_CONFIG
  




-- 
The OpenBSD Journal - http://www.undeadly.org

Reply via email to