I have just upgraded to a 4.5.0-rc4+ kernel that I built, and I’m having trouble getting SPI0 and UARTs 1 & 4 working again. I built the kernel with CONFIG_BONE_CAPEMGR=y
cat /sys/devices/platform/bone_capemgr/slots
0: PF---- -1
1: PF---- -1
2: PF---- -1
3: PF---- -1
Here is my problem:
echo ‘BB-SPIDEV0’ > /sys/devices/platform/bone_capemgr/slots
-bash: echo: write error: Invalid argument
What am I missing? Is there perhaps some kernel build option that I’ve missed?
This was an upgrade from 3.8.13-bone47, so I’m somewhat out of date…
Thanks!
Thomas
DLF
February 25, 2016, 9:11am
2
Hi
follow William’s blog it provides some insights for the 4.x kernels … very useful
http://www.embeddedhobbyist.com/2015/09/beaglebone-black-updating-device-tree-files/
however…
there are some points I could not figure out with SPIDEV0
https://groups.google.com/forum/#!category-topic/beagleboard/gOynYr8fgns
good luck
Some extra info - I get the messages below in dmesg after executing this -
echo ‘BB-SPIDEV0’ > /sys/devices/platform/bone_capemgr/slots
[ 9170.846742] bone_capemgr bone_capemgr: part_number ‘BB-SPIDEV0’, version ‘N/A’
[ 9170.846781] bone_capemgr bone_capemgr: slot #15: override
[ 9170.846797] bone_capemgr bone_capemgr: Using override eeprom data at slot 15
[ 9170.846814] bone_capemgr bone_capemgr: slot #15: ‘Override Board Name,00A0,Override Manuf,BB-SPIDEV0’
[ 9170.847345] __of_adjust_tree_phandle_references: Could not find target property ‘fixup’ @/local_fixups
[ 9170.857775] bone_capemgr bone_capemgr: slot #15: Failed to resolve tree
DLF
February 25, 2016, 9:50am
4
I think you have the wrong (old) DTC version. It has changed and should be something like Version: DTC 1.4.1xxx
In /usr/src/kernel/linux-dev-master/KERNEL/scripts/dtc/ I have However in /usr/bin/ I have So, … I need to understand when dtc is actually called. When does (did?) it actually compile the dts files? All of the dtbo files in /lib/firmware are over 2 years old. Is this where the problem is? Many thanks! Thomas
DLF
February 25, 2016, 10:40am
6
yes - it sounds like the problem…
from William’s blog, I’d look at this part
$ sudo apt-get install git
$ git clone https://github.com/beagleboard/bb.org-overlays
$ cd bb.org-overlays/
$ ./dtc-overlay.sh
$ sudo ./install.sh
and then check that the overlays in /lib/firmware are current.
BTW, backup any data before following my comments…
cheers
All of the dtbo files in /lib/firmware are over 2 years old. Is this where the problem is?
Very likely yes, that is where the problem is. The old binary files have been compiled with the old device tree compiler, and will not work. However, if you have old source files those stand a very good chance to be compiled successfully with the new compiler. There are a few exceptions, but very few from what I understand. I’ve actually yet to find a source file that hadn’t compiled properly yet.
Thanks DLF and William, I followed this procedure (with some minor modifications to use my (already existing) dtc that came with the kernel), and it is working now. Thanks again, Thomas
Thomas,
I’m seeing same issue on my beaglebone black.
i.e.
[ 2.247383] bone_capemgr bone_capemgr: Baseboard: 'A335BNLT,����,������������O�@@@@d \djhnff� bone_cap4
[ 2.300255] bone_capemgr bone_capemgr: slot #0: No cape found
[ 2.344247] bone_capemgr bone_capemgr: slot #1: No cape found
[ 2.388246] bone_capemgr bone_capemgr: slot #2: No cape found
[ 2.432246] bone_capemgr bone_capemgr: slot #3: No cape found
[ 2.438073] bone_capemgr bone_capemgr: enabled_partno PARTNO ‘BB-SPI0-01’ VER ‘N/A’ PR ‘0’
[ 2.446394] bone_capemgr bone_capemgr: slot #4: override
[ 2.451750] bone_capemgr bone_capemgr: Using override eeprom data at slot 4
[ 2.458764] bone_capemgr bone_capemgr: slot #4: ‘Override Board Name,00A0,Override Manuf,BB-SPI0-01’
[ 2.468045] bone_capemgr bone_capemgr: enabled_partno PARTNO ‘BB-SPI1-01’ VER ‘N/A’ PR ‘0’
[ 2.476375] bone_capemgr bone_capemgr: slot #5: override
[ 2.481728] bone_capemgr bone_capemgr: Using override eeprom data at slot 5
[ 2.488741] bone_capemgr bone_capemgr: slot #5: ‘Override Board Name,00A0,Override Manuf,BB-SPI1-01’
[ 2.498376] bone_capemgr bone_capemgr: initialized OK.
.
.
.
[ 3.514779] __of_adjust_tree_phandle_references: Could not find target property ‘fixup’ @/_local_fixu
[ 3.524628] bone_capemgr bone_capemgr: slot #5: Failed to resolve tree
[ 3.532412] bone_capemgr bone_capemgr: loader: failed to load slot-5 BB-SPI1-01:00A0 (prio 0)
[ 3.541557] __of_adjust_tree_phandle_references: Could not find target property ‘fixup’ @/_local_fixu
[ 3.551362] bone_capemgr bone_capemgr: slot #4: Failed to resolve tree
Can you help me how did you fix this issue?
Thanks,
Raju
Please add more information about your system:
sudo /opt/scripts/tools/version.sh
Regards,