powerpc/188177: ADMtek USB To LAN Converter does not work

Josef Larsson josla972 at student.liu.se
Tue Apr 1 19:40:01 UTC 2014


>Number:         188177
>Category:       powerpc
>Synopsis:       ADMtek USB To LAN Converter does not work
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ppc
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Apr 01 19:40:00 UTC 2014
>Closed-Date:
>Last-Modified:
>Originator:     Josef Larsson
>Release:        10.0-RELEASE
>Organization:
Private
>Environment:
FreeBSD ifree 10.0-RELEASE FreeBSD 10.0-RELEASE #2 r263739: Tue Apr  1 11:30:28 CEST 2014     root at ifree:/usr/obj/usr/src/10.0.0/sys/MYKERNEL  powerpc
>Description:
(About the uname -a output: I use an experimental kernel where I tried using aue as a module instead. The problem is also present with the GENERIC kernel.)

I'm having problems with my ADMtek USB ethernet adapter on my Mac Mini G4 (PowerPC). It works flawlessly on the raspberry pi. The driver is detected on the Mac Mini but I cannot use it, even ping does not work. Comparing the MAC addresses, it seems that there might be an endian issue.

Device (dmesg output):

aue0: <ADMtek USB To LAN Converter, rev 2.00/1.01, addr 5> on usbus0
miibus1: <MII bus> on aue0

Mac mini:

ue0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=80000<LINKSTATE>
        ether 05:00:05:1b:b4:28
        inet 192.168.0.8 netmask 0xffffff00 broadcast 192.168.0.255
        inet6 fe80::20d:93ff:fe60:fc1c%ue0 prefixlen 64 scopeid 0x3
        nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
        media: Ethernet autoselect (100baseTX <full-duplex>)
        status: active

raspberry pi (FreeBSD fbsdpi 10.0-CURRENT FreeBSD 10.0-CURRENT #9 r250604M: Mon May 13 21:20:03 CEST 2013):

ue1: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=80000<LINKSTATE>
        ether 00:05:1b:05:28:b4
        inet ***.***.***.*** netmask 0xffffff00 broadcast ***.***.***.***
        nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
        media: Ethernet autoselect (100baseTX <full-duplex>)
        status: active
>How-To-Repeat:
I guess you would need a similar USB ethernet adapter and a powerpc to reproduce it.
>Fix:
I am unsure about a fix, but at least I did some investigation:

If I interpreted the code correctly, the MAC address is read from eeprom as 3 words which are then saved contiguously in memory.

In the following function there is an interesting line:
static uint16_t aue_csr_read_2(struct aue_softc *sc, uint16_t reg)

return (le16toh(val));

This is probably correct if we can guarantee that the earlier function call uether_do_request(&sc->sc_ue, &req, &val, 1000); results in a value that comes in little endian form, but is this necessarily the case? I think the USB standard uses little endian form, but I am not sure if this is compensated for by the USB stack.

Maybe I am looking at the wrong things, but I still do find it peculiar that the MAC adresses differs when I use ifconfig.

>Release-Note:
>Audit-Trail:
>Unformatted:


More information about the freebsd-ppc mailing list