What you're trying to do should work. I've just checked an ASIX usb2 ether
dongle on a pi4 as '#l1', usbd recognises it and I can mount '#l1' on /net
and configure it. I did have to add etherusb to the kernel config and rebuild
first, as you did.

The tricky part is that the real usb ether driver is /sys/src/cmd/usb/ether,
which makes the device appear in /dev because that's the default directory
where usbd mounts itself. (Use the -m flag for a different dir if you really
want to.)

The etherusb 'device' in the kernel is just a stub, which passes packets
directly between the usb endpoint to the network interface, without having
to go back and forth to the usb driver process. Just a performance shortcut;
you can use a usb ether driver without etherusb but it's slower.

When you start a usb ether driver, it tries a "bind" command with each
of the '#l' ctl files in the kernel to see if one of them works as etherusb.
If etherusb is configured in the kernel and enabled by a kernel parameter
eg ether1=type=usb, the bind will succeed and link the '#l1' device with
the usb ether driver which did the bind. You can then mount '#l1' on /net
in the usual way and configure /net/ether1.

You should see a kernel message when the etherusb and usb ether drivers
link up, with the MAC address of the dongle. For instance I see

etherusb asix: 000606e00ae7

This should happen whether usbd starts the driver automatically or you
do it by hand with usb/ether.

Do you get any interesting error messages if you try 'usb/ether -d' ?


------------------------------------------
9fans: 9fans
Permalink: 
https://9fans.topicbox.com/groups/9fans/T668643d11149fab4-Mfe74a807004d1901910c0e32
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription

Reply via email to