[LCA2019 Chat] Headless RPi setup, cdcether not working?

Joel Wirāmu Pauling aenertia at aenertia.net
Tue Jan 29 16:15:15 AEDT 2019


I Enable the gpio serial it works with UART normally but due to
architectural issues with the broadcom SOCs can interfere with perf.

On Tue., 29 Jan. 2019, 18:02 Marc MERLIN <marc at merlins.org wrote:

> On Tue, Jan 29, 2019 at 07:04:24AM +1100, Wes Cilldhaire wrote:
> >
> >
> > ----- On 26 Jan, 2019, at 7:17 PM, martin f krafft madduck at madduck.net
> wrote:
> > > On the Pi I just get the message
> >
> > > "udc-core: couldn't find an available UDC - added [g_cdc] to list
> > > of pending drivers."
> >
> > > which the article says means that I didn't enable the dwc2 properly.
> >
> > > But hey:
> >
> > > # grep dwc /proc/cmdline
> > > 8250.nr_uarts=0 bcm2708_fb.fbwidth=656 bcm2708_fb.fbheight=416
> > > bcm2708_fb.fbswap=1 smsc95xx.macaddr=B8:27:EB:3B:08:DD
> > > vc_mem.mem_base=0x1ec00000 vc_mem.mem_size=0x20000000
> > > dwc_otg.lpm_enable=0 console=ttyS0,115200 console=tty1
> > > root=PARTUUID=9a617d9a-02 rootfstype=ext4 elevator=deadline
> > > fsck.repair=yes rootwait modules-load=dwc2,g_cdc
> > > ^^^^^^^^^^
> >
> > You need to add the dtoverlay=dwc2 line in config.txt as well so the
> device actually appears in the device tree for the module to find.
> >
> > Yes, I overlooked this step too initially, something about its position
> in the instructions seems to make one's mind skip over it :)
> > (null)
>
> I can't get cdc_ether working
>
> I used the rPi image that was available from the burner near rego.
>
> As indicated here, I did this:
> root at raspberrypi:~# grep dwc2 /boot/config.txt
> dtoverlay=dwc2
> root at raspberrypi:~# grep dwc2 /boot/*.txt
>
> /boot/cmdline.txt:dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1
> root=PARTUUID=b4261201-02 rootfstype=ext4 elevator=deadline
>  fsck.repair=yes rootwait splash plymouth.ignore-serial-consoles
> modules-load=dwc2,g_ether
> /boot/config.txt:dtoverlay=dwc2
>
> interface seems to come up:
> [    5.655024] dwc2 20980000.usb: 20980000.usb supply vusb_d not found,
> using dummy regulator
> [    5.655159] dwc2 20980000.usb: 20980000.usb supply vusb_a not found,
> using dummy regulator
> [    6.113258] dwc2 20980000.usb: EPs: 8, dedicated fifos, 4080 entries in
> SPRAM
> [    6.154975] dwc2 20980000.usb: DWC OTG Controller
> [    6.162747] dwc2 20980000.usb: new USB bus registered, assigned bus
> number 1
> [    6.252180] dwc2 20980000.usb: irq 33, io mem 0x20980000
> [    7.044669] g_ether gadget: Ethernet Gadget, version: Memorial Day 2008
> [    7.053989] g_ether gadget: g_ether ready
> [    7.060353] dwc2 20980000.usb: bound driver g_ether
> [    7.189129] dwc2 20980000.usb: new device is high-speed
> [    7.236167] i2c /dev entries driver
> [    7.565138] dwc2 20980000.usb: new device is high-speed
> [    7.693246] dwc2 20980000.usb: new device is high-speed
> [    7.766371] dwc2 20980000.usb: new address 10
> [    7.787912] g_ether gadget: high-speed config #1: CDC Ethernet (ECM)
>
> I give it an IP:
> root at raspberrypi:~# ifconfig usb0
> usb0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
>         inet 192.168.1.2  netmask 255.255.255.0  broadcast 192.168.1.255
>         inet6 fe80::15e4:95ea:e740:aa7d  prefixlen 64  scopeid 0x20<link>
>         ether be:e6:a6:5b:35:18  txqueuelen 1000  (Ethernet)
>
> On my computer, I give it an IP too:
> root at raspberrypi:~# ifconfig usb0
> usb0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
>         inet 192.168.1.2  netmask 255.255.255.0  broadcast 192.168.1.255
>         inet6 fe80::15e4:95ea:e740:aa7d  prefixlen 64  scopeid 0x20<link>
>
> dmesg says:
> Jan 28 20:38:26 saruman kernel: [728255.209791] usb 1-2: new high-speed
> USB device number 40 using xhci_hcd
> Jan 28 20:38:26 saruman kernel: [728255.358611] usb 1-2: New USB device
> found, idVendor=0525, idProduct=a4a2, bcdDevice= 4.14
> Jan 28 20:38:26 saruman kernel: [728255.358615] usb 1-2: New USB device
> strings: Mfr=1, Product=2, SerialNumber=0
> Jan 28 20:38:26 saruman kernel: [728255.358617] usb 1-2: Product:
> RNDIS/Ethernet Gadget
> Jan 28 20:38:26 saruman kernel: [728255.358619] usb 1-2: Manufacturer:
> Linux 4.14.79+ with 20980000.usb
> Jan 28 20:38:26 saruman kernel: [728255.359846] cdc_subset: probe of
> 1-2:1.0 failed with error -22
> Jan 28 20:38:26 saruman kernel: [728255.361388] cdc_ether 1-2:1.0 usb0:
> register 'cdc_ether' at usb-0000:00:14.0-2, CDC Ethernet Device,
> 62:3c:c9:7f:9d:e5
>
> Not sure if cdc_subset probe failed is bad.
>
> If I ping my computer from the rPi, I see its packets on my laptop:
> 20:58:43.391704 ARP, Request who-has 192.168.1.1 tell 192.168.1.2, length
> 28
> 20:58:43.391727 ARP, Reply 192.168.1.1 is-at 62:3c:c9:7f:9d:e5, length 28
>
> But no packet from my laptop never seems to make it back to the rPi.
>
> For those who got it to work, do I have the wrong rPi image or some
> other driver problem that causes the rPi not to get packets back in?
>
> Thanks,
> Marc
> --
> "A mouse is a device used to point at the xterm you want to type in" -
> A.S.R.
> Microsoft is to operating systems ....
>                                       .... what McDonalds is to gourmet
> cooking
> Home page: http://marc.merlins.org/                       | PGP
> 7F55D5F27AAF9D08
> --
> Chat mailing list
> Chat at lists.lca2019.linux.org.au
> http://lists.lca2019.linux.org.au/mailman/listinfo/chat
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lca2019.linux.org.au/pipermail/chat/attachments/20190129/14845c90/attachment-0001.html>


More information about the Chat mailing list