This is a cache of https://discuss.96boards.org/t/rock960-with-dm9601-usb-ethernet-adapter/6768. It is a snapshot of the page at 2024-10-31T11:09:32.156+0000.
Rock960 with DM9601 USB ethernet adapter - Rock960 - 96Boards Forum

Rock960 with DM9601 USB ethernet adapter

Hi,

We are trying to attach DM9601 based USB ethernet adapter into Rock960 board. In lsusb we can see the device:

Bus 006 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 005 Device 002: ID 0fe6:9700 Kontron (Industrial Computer Source / ICS Advent) DM9601 Fast Ethernet Adapter
Bus 005 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 003: ID 1a2c:0e24 China Resource Semico Co., Ltd 
Bus 001 Device 002: ID 05e3:0608 Genesys Logic, Inc. Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

But we can see any wired network interfaces in ifconfig or ip addr.

Got this issue with both debian (kernel version 4.4.103) and ubuntu (kernel version 4.4.154) distributions.

Is DM9601 support is disabled in these OS kernels? How can I use this adapter with Rock960 board?

Looks to me like the kernel does not have CONFIG_USB_NET_DM9601 enabled.
To fix you will probably have to recompile the kernel with this setting
changed.

The kernel compilation guide for this board is here:

Thanks for providing some direction!

I follow the above guide and starts to build the kernel but to me it seems like this (and most of the rock960) documentations are out-dated.

In latest source I see CONFIG_USB_NET_DM9601 is set to y, so without doing any modifications I build the kernel. After couple of modifications I manage to get HDMI output with this kernel but still, it is not fire the Debian rootfs. I can see only “_” character in my display.

Curious. @hipboi, are you aware of any recent kernel changes (or problems with the docs).

Just now I manage to build kernel successfully. I follow instructions in here: https://github.com/96rocks/manifests

In this kernel CONFIG_USB_NET_DM9601 is set to y and still this adapter is not getting listed in network interfaces.

Can you share whatever appears in the dmesg during the plugin sequence?

I got following during the adapter plugin:

[  248.263446] usb 3-1.4: new full-speed USB device number 4 using xhci-hcd
[  248.341403] usb 3-1.4: New USB device found, idVendor=0fe6, idProduct=9700
[  248.342031] usb 3-1.4: New USB device strings: Mfr=0, Product=2, SerialNumber=0
[  248.342917] usb 3-1.4: Product: USB 2.0 10/100M Ethernet Adaptor

I checked this same adapter with Raspberry Pi 3 (Raspbian) and ubuntu 16.04 and it works without any issues.

It looks like this is still a kernel problem then. Normally the driver will show a message that looks like this during the hotplug sequence (obviously with dm9601 instead of asix but the message should be of the same form):

asix 1-7:1.0 eth0: register 'asix' at usb-0000:00:14.0-7, ASIX AX88772B USB 2.0 Ethernet, 00:00:00:00:11:2b

You can double check the behaviour on RPi3 to be sure but I’ve double checked the source code and this message should apply to dm9601 too.

It is not at all clear what is going wrong in the kernel. You could modify drivers/net/usb/usbnet.c and drivers/net/usb/dm9601.c to uncomment the #define DEBUG (and #define VERBOSE lines in usbnet.c). This will cause more information to be placed in the dmesg buffer when the dm9601 drivers tries to initialize.

So with this change we will either we get new debug output (and therefore new clues on what is going wrong) or we get no new debug output (which tells us it didn’t try to initialise).

PS Can you also confirm that you checked the contents of /proc/version (or the Linux version string in dmesg) after re-compiling the kernel. If this doesn’t have your username and the date you compiled the kernel in it something has gone wrong…

The document uses an older branch of the kernel but it should work. We will update it for the new branch.

To fix your issue, we will setup a package repository to update the kernel for you. Please wait for the next 24 hours update.

I am sorry there is some issue with the u-boot packages, the repository is not online yet. I will update on Monday.

Thanks hipboi, please let us know once you pushed packages.

I think we have fixed this in the new released image, can you test it?

Debian stretch desktop:

https://dl.vamrs.com/products/rock960/images/debian/rock960ab-debian-stretch-desktop-armhf-20181218_2036-gpt.img.gz

ubuntu bionic minial:

https://dl.vamrs.com/products/rock960/images/ubuntu/rock960ab-ubuntu-bionic-minimal-arm64-20181218_2036-gpt.img.gz

Use modprobe dm9601 should get the USB ethernet adapter working.

1 Like

Thanks @hipboi, now issue is resolved.

I just installed the *20181218* image on a rock960 C version, it seems to work fine.
Is this image fully compatible with C or something somewhere could break?