Model A "internal error / kernel BUG" with Raspbian ?


9 posts
by jbeale » Fri Apr 05, 2013 3:06 pm
Just got a Model A from Allied. Installed the current version of Raspbian on a 4GB SD card and it boots up fine.
Code: Select all
pi@raspberrypi:~$ uname -a
Linux raspberrypi 3.6.11+ #371 PREEMPT Thu Feb 7 16:31:35 GMT 2013 armv6l GNU/Linux


Next, installed a cheap wired USB-ethernet adaptor.
Code: Select all
pi@raspberrypi:~$ lsusb
Bus 001 Device 002: ID 0fe6:9700 Kontron (Industrial Computer Source / ICS Advent) DM9601 Fast Ethernet Adapter
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

[dmesg log extract:]
[    2.371803] usb 1-1: new full-speed USB device number 2 using dwc_otg
[    2.380790] Indeed it is in host mode hprt0 = 00021501
[    2.582606] usb 1-1: New USB device found, idVendor=0fe6, idProduct=9700
[    2.591339] usb 1-1: New USB device strings: Mfr=0, Product=2, SerialNumber=0
[    2.600445] usb 1-1: Product: USB 2.0 10/100M Ethernet Adaptor

On the second boot this adaptor worked fine (for a while- died later). But the very first time I booted up with the USB adaptor connected (serial console via UART on GPIO pins) I captured a partial listing from the terminal window as shown below, claiming a "Kernel BUG". Is there any way to determine what happened here, and if it might happen again?

Code: Select all
[    2.591674] usb 1-1: New USB device strings: Mfr=0, Product=2, SerialNumber=0
[    2.601559] usb 1-1: Product: USB 2.0 10/100M Ethernet Adaptor
[    3.659895] udevd[142]: starting version 175
[    4.815146] dm9601 1-1:1.0: eth0: register 'dm9601' at usb-bcm2708_usb-1, Dav             icom DM9601 USB Ethernet, 00:e0:4c:53:44:58
[    5.143888] usbcore: registered new interface driver dm9601
[   15.126310] EXT4-fs (mmcblk0p2): re-mounted. Opts: (null)
[   15.567697] EXT4-fs (mmcblk0p2): re-mounted. Opts: (null)
[   16.281554] bcm2835 ALSA card created!
[   16.296020] bcm2835 ALSA chip created!
[   16.307700] bcm2835 ALSA chip created!
[   16.318555] bcm2835 ALSA chip created!
[   16.326345] bcm2835 ALSA chip created!
[   16.335888] bcm2835 ALSA chip created!
[   16.344613] bcm2835 ALSA chip created!
[   16.351976] bcm2835 ALSA chip created!
[   22.752431] skbuff: skb_over_panic: text:c026b210 len:1536 put:1536 head:c98f             8000 data:c98f8022 tail:0xc98f8622 end:0xc98f8620 dev:eth0
[   22.767930] ------------[ cut here ]------------
[   22.774217] kernel BUG at net/core/skbuff.c:127!
[   22.780527] Internal error: Oops - BUG: 0 [#1] PREEMPT ARM

Entering kdb (current=0xcab83060, pid 1438) Oops: (null)
due to oops @ 0xc02e66f0

Pid: 1438, comm:            net.agent
CPU: 0    Not tainted  (3.6.11+ #371)
PC is at skb_put+0x88/0x98
LR is at skb_put+0x88/0x98
pc : [<c02e66f0>]    lr : [<c02e66f0>]    psr: 20000193
sp : caa37cb8  ip : 60000193  fp : ca962980
r10: ca962980  r9 : f298050c  r8 : 00000000
r7 : 00000000  r6 : c0492684  r5 : c98f8620  r4 : c98f8622
r3 : c0517a48  r2 : c0517a48  r1 : 00000000  r0 : 0000007b
Flags: nzCv  IRQs off  FIQs on  Mode SVC_32  ISA ARM  Segment user
Control: 00c5387d  Table: 098b0008  DAC: 00000015
[<c0013a7c>] (unwind_backtrace+0x0/0xf0) from [<c0072a98>] (kdb_dumpregs+0x28/0x             50)
[<c0072a98>] (kdb_dumpregs+0x28/0x50) from [<c0074e1c>] (kdb_main_loop+0x3a8/0x6             fc)
[<c0074e1c>] (kdb_main_loop+0x3a8/0x6fc) from [<c0077500>] (kdb_stub+0x154/0x380             )
[<c0077500>] (kdb_stub+0x154/0x380) from [<c006e634>] (kgdb_handle_exception+0x1             f8/0x668)
more>
Last edited by jbeale on Sat Apr 06, 2013 5:36 am, edited 1 time in total.
User avatar
Posts: 2120
Joined: Tue Nov 22, 2011 11:51 pm
by jbeale » Fri Apr 05, 2013 4:40 pm
Additional notes:
1) the Model A is being powered via +5V/GND on GPIO pins. I think it's an adequate supply, but I have not yet checked the actual voltage.
2) I think I plugged in the ethernet cable to the adaptor at some point during the first boot, which later resulted in the "kernel bug" error. I assume that would not cause a fault, but wanted to mention it.

In case you're wondering why I don't just use a Model B if I want ethernet, this device will eventually be used without the network and I want minimum power use. But for initial setup, configuration, and debug, it is convenient to have network access available. Also, the adaptor cost is about $5 on ebay.
User avatar
Posts: 2120
Joined: Tue Nov 22, 2011 11:51 pm
by dom » Fri Apr 05, 2013 4:51 pm
Can you try an rpi-update? (https://github.com/Hexxeh/rpi-update).
There's been a number of USB related fixes to firmware lately.
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 4104
Joined: Wed Aug 17, 2011 7:41 pm
Location: Cambridge
by jbeale » Fri Apr 05, 2013 4:53 pm
Judging from this thread: viewtopic.php?f=66&t=34557 the DM9601 Ethernet driver is (was) Just Plain Broken.

Thanks for the quick reply Dom. The network was working after the second boot, so I will try an update and see if that helps.

EDIT: Cannot update in place; adaptor dies immediately when transferring any files...
Code: Select all
[  956.971503] skbuff: skb_over_panic: text:c026b210 len:1536 put:1536 head:c9914ba0 data:c9914bc2 tail:0xc99151c2 end:0xc99151c0 dev:eth0
[  956.987567] ------------[ cut here ]------------
[  956.994037] kernel BUG at net/core/skbuff.c:127!
[  957.000463] Internal error: Oops - BUG: 0 [#1] PREEMPT ARM
User avatar
Posts: 2120
Joined: Tue Nov 22, 2011 11:51 pm
by jbeale » Sat Apr 06, 2013 3:08 pm
Followup: I quit trying with the USB-Ethernet device, and got the network going using this $11 Wifi adaptor:
http://www.ebay.com/itm/150-MBPS-RALINK ... 0976202890

lsusb reports 148f:5370 Ralink Technology, Corp. RT5370 Wireless Adapter

Code: Select all
pi@raspberrypi:~/test$ ethtool -S wlan0
NIC statistics:
     rx_packets: 24446
     rx_bytes: 23616064
     wep_weak_iv_count: 0
     rx_duplicates: 511
     rx_fragments: 19814
     rx_dropped: 514
     tx_packets: 7604
     tx_bytes: 650298
     tx_fragments: 7604
     tx_filtered: 0
     tx_retry_failed: 121
     tx_retries: 1423
     beacon_loss: 0
     sta_state: 4
     txrate: 54000000
     rxrate: 48000000
     signal: 209
     channel: 2412
     noise: 18446744073709551615
     ch_time: 480423
     ch_time_busy: 48493
     ch_time_ext_busy: 0
     ch_time_rx: 18446744073709551615
     ch_time_tx: 18446744073709551615

pi@raspberrypi:~/test$ iwconfig
wlan0     IEEE 802.11bgn  ESSID:"myWiFi"
          Mode:Managed  Frequency:2.412 GHz  Access Point: 00:23:69:C7:88:6C
          Bit Rate=54 Mb/s   Tx-Power=20 dBm
          Retry  long limit:7   RTS thr:off   Fragment thr:off
          Power Management:on
          Link Quality=65/70  Signal level=-45 dBm
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:121  Invalid misc:515   Missed beacon:0

User avatar
Posts: 2120
Joined: Tue Nov 22, 2011 11:51 pm
by jbeale » Sat Apr 06, 2013 3:56 pm
Trying to diagnose a problem, Wifi works for a while and then quits. Leaving "ping" running shows a strange error I've never seen before. After this point, there is no network connection. Also, 'sudo reboot' just hangs, until I physically remove the wifi adaptor. at which point it proceeds to reboot. What does this mean? (note: I did already do the rpi-update as suggested)

Code: Select all
pi@raspberrypi:~$ uname -a
Linux raspberrypi 3.6.11+ #403 PREEMPT Tue Apr 2 22:48:13 BST 2013 armv6l GNU/Linux


Code: Select all
(...)
64 bytes from 192.168.10.1: icmp_req=286 ttl=64 time=270 ms
64 bytes from 192.168.10.1: icmp_req=287 ttl=64 time=4.14 ms
64 bytes from 192.168.10.1: icmp_req=288 ttl=64 time=317 ms
64 bytes from 192.168.10.1: icmp_req=289 ttl=64 time=4.16 ms
64 bytes from 192.168.10.1: icmp_req=290 ttl=64 time=4.14 ms
64 bytes from 192.168.10.1: icmp_req=291 ttl=64 time=4.80 ms
64 bytes from 192.168.10.1: icmp_req=292 ttl=64 time=4.08 ms
64 bytes from 192.168.10.1: icmp_req=293 ttl=64 time=4.33 ms
ping: sendmsg: No buffer space available
ping: sendmsg: No buffer space available
ping: sendmsg: No buffer space available
ping: sendmsg: No buffer space available
ping: sendmsg: No buffer space available
ping: sendmsg: No buffer space available
ping: sendmsg: No buffer space available
ping: sendmsg: No buffer space available
ping: sendmsg: No buffer space available
ping: sendmsg: No buffer space available
ping: sendmsg: No buffer space available
Last edited by jbeale on Sat Apr 06, 2013 5:02 pm, edited 1 time in total.
User avatar
Posts: 2120
Joined: Tue Nov 22, 2011 11:51 pm
by poing » Sat Apr 06, 2013 4:39 pm
I have no clue about your problems other than that I have 4 Pies (2xB, 2xA) and 8 of the WiFi dongles you mentioned. They run for weeks in either AP or Client mode (typically two dongles in one Pi, one as AP the other as Client ) until I reboot. This is with the 2013-02-09 Wheezy distro. Methinks you have an unrelated problem.

Just my €0.02.
Posts: 1097
Joined: Thu Mar 08, 2012 3:32 pm
by jbeale » Sat Apr 06, 2013 11:49 pm
Here's another strange item: I tried hooking up a display, keyboard and mouse, and running X, which I had not done before on this unit. Now the network seems to stay up! At least for five hours of "ping <myrouter>" so far, from an X session terminal. Before it would die after 2-3 minutes of 'ping', while logged in via serial port on GPIO pins. Interesting...

EDIT: Ah, there is a difference. To run X, I plugged in a mouse and a keyboard, so a 4-port unpowered hub entered the equation. Before, I had just the WiFi dongle plugged into the sole USB port on the Model A. So that is apparently the difference between reliable WiFi operation, and not, in this case.
User avatar
Posts: 2120
Joined: Tue Nov 22, 2011 11:51 pm
by rfreire » Tue Apr 30, 2013 3:24 pm
Hi,

I ended buying this device and found that Davicom dm9601 is part of Hall of shame, at http://elinux.org/RPi_VerifiedPeriphera ... t_adapters .

Worst, while checking its advertised USB amp requirements, I found that this device, despite of having at least 8 mentions to USB 2.0 in its package, is actually a USB 1.1 device, which means, 12 Mbps throughput to the host, even if the PHY per se is 100 Mbps capable.

Run lsusb -v, seek for bcdUSB field.

Beware.
Posts: 2
Joined: Tue Apr 30, 2013 3:17 pm