bone_capemgr bone_capemgr: loader: failed to load slot-4 (prio 0)

671 views
Skip to first unread message

William Hermans

unread,
Oct 12, 2016, 9:33:22 PM10/12/16
to BeagleBoard
So I've been searching the groups here for the last several hours. I've tried several things, even noted that the device tree "binary" file (compiled file in /lib/firmware) was marked as executable. So I set the executable bit via chmod -x . . .Anyway, this is a custom device tree overlay binary, that enabled several GPO's 6 GPI's, and all 3 "dual channel" pwm modules. Plus I think uart4. The overlay fails to load at boot via /boot/uEnv.txt.

william@beaglebone:~$ dmesg |grep controller
[    0.000000] Kernel command line: console=tty0 console=ttyO0,115200n8 bone_capemgr.enable_partno=controller root=/dev/mmcblk0p1 rootfstype=ext4 rootwait coherent_pool=1M quiet cape_universal=enable ipv6.disable=1
. . .
[    2.167008] IPv6: Loaded, but administratively disabled, reboot required to enable
[    2.426546] bone_capemgr bone_capemgr: enabled_partno PARTNO 'lcontroller' VER 'N/A' PR '0'
[    2.426586] bone_capemgr bone_capemgr: slot #4: 'Override Board Name,00A0,Override Manuf,controller'
[    3.437016] bone_capemgr bone_capemgr: loader: failed to load slot-4 controller:00A0 (prio 0)



I have tried this with cape_universal=enable, as well as commented out( simply removed the text ).

william@beaglebone:~$ uname -r
4.4.14-ti-r34
william@beaglebone
:~$ cat /etc/dogtag
BeagleBoard.org Debian Image 2016-05-01
william@beaglebone
:~$ dtc -v
Version: DTC 1.4.1

So here is the funny part.

william@beaglebone:~$ sudo config-pin overlay controller
[sudo] password for william:
Loading led-controller overlay

william@beaglebone
:~$ dmesg |grep controller
[    0.000000] Kernel command line: console=tty0 console=ttyO0,115200n8 bone_capemgr.enable_partno=controller root=/dev/mmcblk0p1 rootfstype=ext4 rootwait coherent_pool=1M quiet cape_universal=enable ipv6.disable=1
[    2.426546] bone_capemgr bone_capemgr: enabled_partno PARTNO 'controller' VER 'N/A' PR '0'
[    2.426586] bone_capemgr bone_capemgr: slot #4: 'Override Board Name,00A0,Override Manuf,controller'
[    3.437016] bone_capemgr bone_capemgr: loader: failed to load slot-4 controller:00A0 (prio 0)
[ 1972.395048] bone_capemgr bone_capemgr: part_number 'controller', version 'N/A'
[ 1972.395115] bone_capemgr bone_capemgr: slot #5: 'Override Board Name,00A0,Override Manuf,controller'
[ 1972.526297] bone_capemgr bone_capemgr: slot #5: dtbo 'controller-00A0.dtbo' loaded; overlay id #0



Is this a known issue ? Or maybe I'm doing something wrong ? Maybe I need a different board file loaded at boot ?

william@beaglebone:~$ cat /boot/uEnv.txt
#Docs: http://elinux.org/Beagleboard:U-boot_partitioning_layout_2.0

uname_r
=4.4.14-ti-r34
#uuid=
#dtb=

##BeagleBone Black/Green dtb's for v4.1.x (BeagleBone White just works..)

##BeagleBone Black: HDMI (Audio/Video) disabled:
dtb
=am335x-boneblack-emmc-overlay.dtb

##BeagleBone Black: eMMC disabled:
#dtb=am335x-boneblack-hdmi-overlay.dtb

##BeagleBone Black: HDMI Audio/eMMC disabled:
#dtb=am335x-boneblack-nhdmi-overlay.dtb

##BeagleBone Black: HDMI (Audio/Video)/eMMC disabled:
#dtb=am335x-boneblack-overlay.dtb

##BeagleBone Black: wl1835
#dtb=am335x-boneblack-wl1835mod.dtb

##BeagleBone Green: eMMC disabled
#dtb=am335x-bonegreen-overlay.dtb

cmdline
=coherent_pool=1M quiet cape_universal=enable ipv6.disable=1
#cmdline=ipv6.disable=1 quiet

#In the event of edid real failures, uncomment this next line:
#cmdline=coherent_pool=1M quiet cape_universal=enable video=HDMI-A-1:1024x768@60e

##Example v3.8.x
#cape_disable=capemgr.disable_partno=
#cape_enable=capemgr.enable_partno=

##Example v4.1.x
#cape_disable=bone_capemgr.disable_partno=
cape_enable
=bone_capemgr.enable_partno=controller

##enable Generic eMMC Flasher:
##make sure, these tools are installed: dosfstools rsync
#cmdline=init=/opt/scripts/tools/eMMC/init-eMMC-flasher-v3.sh


william@beaglebone:~$ cat /sys/devices/platform/bone_capemgr/slots
 
0: PF----  -1
 
1: PF----  -1
 
2: PF----  -1
 
3: PF----  -1
 
5: P-O-L-   0 Override Board Name,00A0,Override Manuf,controller



The overlay source file does have some aspects similar to the universal IO overlays. dir-changable, init-hi/lo etc.



William Hermans

unread,
Oct 12, 2016, 9:37:51 PM10/12/16
to beagl...@googlegroups.com
By the way, this has been tested consistently on one BBB RevC, and several( tens ) of BBG's. By me personally, and another person, elsewhere.

--
For more options, visit http://beagleboard.org/discuss
---
You received this message because you are subscribed to the Google Groups "BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email to beagleboard+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/beagleboard/408d8389-6999-4d06-8b60-21795c240e92%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

William Hermans

unread,
Oct 12, 2016, 9:50:37 PM10/12/16
to beagl...@googlegroups.com
Additional information if this helps. P9.42 if I recall is one of the pins that are tied together for mmc_cmd ? So, kind of has my attention.

/* state the resources this cape uses */
    exclusive-use =
        /* the pin header uses */
        "P8.8",
        "P8.9",
        "P8.10",
        "P8.11",
        "P8.12",
        "P8.13",    /* EHRPWM2B */
        "P8.13",
        "P8.14",
        "P8.15",
        "P8.16",
        "P8.17",
        "P8.18",
        "P8.19",    /* EHRPWM2A */
        "P8.26",
        "P8.27",
        "P9.11",    /* UART4_RX */
        "P9.12",
        "P9.13",    /* UART4_TX */
        "P9.14",    /* EHRPWM1A  */
        "P9.15",
        "P9.16",    /* EHRPWM1B  */
        "P9.21",    /* EHRPWM0A  */
        "P9.22",    /* EHRPWM0B  */
        "P9.23",
        "P9.25",
        "P9.27",
        "P9.28",    
        "P9.29",      
        "P9.30",
        "P9.31",
        "P9.42",      
        /* the hardware ip uses */
        "uart4",
        "ehrpwm0A",
        "ehrpwm0B",
        "ehrpwm1A",
        "ehrpwm1B",
        "ehrpwm2A",
        "ehrpwm2B";

William Hermans

unread,
Oct 15, 2016, 2:24:29 PM10/15/16
to beagl...@googlegroups.com

So, it turns out you *do* have to modify the initramfs image, in order to load a custom overlay file at boot. The hook for /etc/default/capemgr does not seem to be in place for the image I'm using. Which is fine since this is just an init script anyhow, which I feel is the wrong way to do this. Call it personal preference.

work log:
william@beaglebone:~$ uname -r
4.4.14-ti-r34

william@beaglebone:~$ file /boot/initrd.img-4.4.14-ti-r34
/boot/initrd.img-4.4.14-ti-r34: gzip compressed data, last modified: Sat Jul 16 16:51:58 2016, from Unix

william@beaglebone:~$ ls /boot |grep 4.4.14-ti-r34
System.map-4.4.14-ti-r34
config-4.4.14-ti-r34
initrd.img-4.4.14-ti-r34
vmlinuz-4.4.14-ti-r34

william@beaglebone:~$ cp /boot/initrd.img-4.4.14-ti-r34 .

explore:
william@beaglebone:~$ sudo mount -t sysfs initrd.img-4.4.14-ti-r34 /home/william/temp/
william@beaglebone:~$ cd temp/
william@beaglebone:~/temp$ cd ..
william@beaglebone:~$ sudo umount temp/

william@beaglebone:~$ cd dev
william@beaglebone:~/dev$ mkdir initrd
william@beaglebone:~/dev/initrd$ cp ../../initrd.img-4.4.14-ti-r34 .

william@beaglebone:~/dev/initrd$ gunzip -c initrd.img-4.4.14-ti-r34 | file -
/dev/stdin: ASCII cpio archive (SVR4 with no CRC)

william@beaglebone:~/dev/initrd$ gunzip -c initrd.img-4.4.14-ti-r34 | cpio -i
21618 blocks

william@beaglebone:~/dev/initrd$ ls -l
total 4728
drwxr-xr-x 2 william nogroup    4096 Oct 15 08:01 bin
drwxr-xr-x 3 william nogroup    4096 Oct 15 08:01 conf
drwxr-xr-x 5 william nogroup    4096 Oct 15 08:01 etc
-rwxr-xr-x 1 william nogroup    7137 Oct 15 08:01 init
-rw-r--r-- 1 william nogroup 4801412 Oct 15 07:55 initrd.img-4.4.14-ti-r34
drwxr-xr-x 8 william nogroup    4096 Oct 15 08:01 lib
drwxr-xr-x 2 william nogroup    4096 Oct 15 08:01 run
drwxr-xr-x 2 william nogroup    4096 Oct 15 08:01 sbin
drwxr-xr-x 5 william nogroup    4096 Oct 15 08:01 scripts

william@beaglebone:~/dev/initrd$ ls lib/firmware/
william@beaglebone:~/dev/initrd$ rm lib/firmware/*.dtbo
william@beaglebone:~/dev/initrd$ cp ../controller-00A0.dtbo ./lib/firmware/
william@beaglebone:~/dev/initrd$ ls lib/firmware/
controller-00A0.dtbo

william@beaglebone:~/dev/initrd$ rm initrd.img-4.4.14-ti-r34

william@beaglebone:~/dev/initrd$ sudo find . | cpio -H newc -o | gzip -9 > ../../initrd.img-4.4.14-ti-r34
20126 blocks

william@beaglebone:~/dev/initrd$ du ../../initrd.img-4.4.14-ti-r34
4552    ../../initrd.img-4.4.14-ti-r34
william@beaglebone:~/dev/initrd$ du /boot/initrd.img-4.4.14-ti-r34
4692    /boot/initrd.img-4.4.14-ti-r34

william@beaglebone:~/dev/initrd$ cd ..
william@beaglebone:~/dev$ sudo cp /boot/initrd.img-4.4.14-ti-r34 .
william@beaglebone:~/dev$ ls |grep initrd
initrd
initrd.img-4.4.14-ti-r34
william@beaglebone:~/dev$ cd ..
william@beaglebone:~$ sudo rm /boot/initrd.img-4.4.14-ti-r34
william@beaglebone:~$ sudo cp initrd.img-4.4.14-ti-r34 /boot/
william@beaglebone:~$ ls -l /boot/
total 62368
-rw-r--r-- 1 root root     492 May  1 13:17 SOC.sh
-rw-r--r-- 1 root root 3300781 Jul  5 22:44 System.map-4.4.14-ti-r34
-rw-r--r-- 1 root root 3313309 Jul  5 22:49 System.map-4.4.14-ti-rt-r34
-rw-r--r-- 1 root root 3308481 Apr 27 15:33 System.map-4.4.8-ti-r22
-rw-r--r-- 1 root root 3217126 May  5 08:49 System.map-4.4.9-bone-rt-r10
-rw-r--r-- 1 root root  147440 Jul  5 22:44 config-4.4.14-ti-r34
-rw-r--r-- 1 root root  147105 Jul  5 22:49 config-4.4.14-ti-rt-r34
-rw-r--r-- 1 root root  143808 Apr 27 15:33 config-4.4.8-ti-r22
-rw-r--r-- 1 root root  141837 May  5 08:49 config-4.4.9-bone-rt-r10
drwxr-xr-x 6 root root    4096 Jul 16 16:51 dtbs
-rw-r--r-- 1 root root 4653669 Oct 15 10:03 initrd.img-4.4.14-ti-r34
-rw-r--r-- 1 root root 4820956 Jul 18 14:08 initrd.img-4.4.14-ti-rt-r34
-rw-r--r-- 1 root root 4770865 Jun  2 12:01 initrd.img-4.4.8-ti-r22
-rw-r--r-- 1 root root 4770871 Jun  2 12:15 initrd.img-4.4.9-bone-rt-r10
-rw-r--r-- 1 root root    1256 Oct 13 22:15 uEnv.txt
drwxr-xr-x 2 root root    4096 May  1 10:25 uboot
-rwxr-xr-x 1 root root 7779712 Jul  5 22:44 vmlinuz-4.4.14-ti-r34
-rwxr-xr-x 1 root root 7875600 Jul  5 22:49 vmlinuz-4.4.14-ti-rt-r34
-rwxr-xr-x 1 root root 7824792 Apr 27 15:33 vmlinuz-4.4.8-ti-r22
-rwxr-xr-x 1 root root 7608888 May  5 08:49 vmlinuz-4.4.9-bone-rt-r10

william@beaglebone:~$ sudo nano /boot/uEnv.txt
. . .

##Example v4.1.x
#cape_disable=bone_capemgr.disable_partno=
cape_enable=bone_capemgr.enable_partno=controller

. . .


william@beaglebone:~$ sudo reboot

william@beaglebone:~$ dmesg |grep controller
[    0.000000] Kernel command line: console=tty0 console=ttyO0,115200n8 bone_capemgr.enable_partno=controller root=/dev/mmcblk0p1 rootfstype=ext4 rootwait coherent_pool=1M quiet cape_universal=enable ipv6.disable=1
[    2.406540] bone_capemgr bone_capemgr: enabled_partno PARTNO 'controller' VER 'N/A' PR '0'
[    2.406580] bone_capemgr bone_capemgr: slot #4: 'Override Board Name,00A0,Override Manuf,controller'
[    2.493083] bone_capemgr bone_capemgr: slot #4 dtbo controller-00A0.dtbo' loaded; overlay id #0


Since I enable all three dual channel PWM's I figure checking the sysfs structure would also be a good indication:

william@beaglebone:~$ ls /sys/class/pwm/
pwmchip0  pwmchip2  pwmchip4


Strictly speaking:
explore:
william@beaglebone:~$ sudo mount -t sysfs initrd.img-4.4.14-ti-r34 /home/william/temp/
william@beaglebone:~$ cd temp/
william@beaglebone:~/temp$ cd ..
william@beaglebone:~$ sudo umount temp/

and . . .


william@beaglebone:~/dev/initrd$ rm lib/firmware/*.dtbo

are not required steps. Just me exploring, and the last bit here I do not require the stock overlay files for this system image . . .


William Hermans

unread,
Oct 15, 2016, 2:27:34 PM10/15/16
to beagl...@googlegroups.com
I really dislike gmail / google groups sometimes . . . but I corrected the problem and showed my worklog in the above mail for those of you using gmail, it may 'hide' this information under the '...' are the top of the post.

I've also been informed that Robert has a customization repo, for which one of the scripts can also deal with this. Here:

https://github.com/rcn-ee/repos/blob/master/bb-bb-customizations/suite/jessie/debian/dtbo

bb-customizations deb package


Super Twang

unread,
Nov 23, 2018, 7:17:56 PM11/23/18
to BeagleBoard
William,

THANK YOU for doing this! :)  I am finding this in Nov 2018 and your solution is exactly what I'm looking for.  I really appreciate you documenting this.  But yeah, Google Groups... lol.  TBH I'm really surprised I was able to find this!

Thanks again.
ST
Reply all
Reply to author
Forward
0 new messages