2
votes

I am trying to compile a dtb for the beagle bone black (BBB) that I can pass from uboot and have all the peripherals configured as I want them. I need to do it this way rather than applying overlays as we are designing a board based on the BBB and we want to have the peripherals configured at boot.

The command I have used to try to compile the dtb is below. dtc -I dts -@ -O dtb -o am335x-boneblack.dtb am335x-boneblack.dts

To get the -@ option to work I followed the instructions here: http://eewiki.net/display/linuxonarm/BeagleBone#BeagleBone-Upgradedistro%22device-tree-compiler%22package

I have tried pulling the device tree source from multiple places and compiling it.

When pulling from http://git.ti.com/ti-linux-kernel/ti-linux-3-8-y-kernel/trees/master/arch/arm/boot/dts I can compile it but once uboot says "Starting kernel ..." there is no further response

When pulling from githubdotcom/beagleboard/devicetree-source I'm unable to compile. It is returning a syntax error on the "#include" statements. I have tried to change these to /include/ but there are includes in a "" that fail. If I fix those to absolute things inside the include break.

I believe that the build from the TI repo is the correct path to pursue but I have been unable to get the kernel to boot. I have tried adding a "-b 0" option (no binary difference in dtb) and removing the -@ but the file is significantly smaller (11k to -@ 15k to default that works 29k) and doesn't boot.

Any suggestions?

ps sorry for the github link mangling, I'm only allowed to post 2 links

1

1 Answers

2
votes

It turns out the yocto kernel I was using wasn't happy with the dtb files that I compiled.

Replacing am335x-boneblack.dtb in the dtbs folder in the latest BBB debian image from http://beagleboard.org/latest-images resulted in the Kernel trying to boot and then panicing! Much better.

I found the source tree here https://github.com/dominicgs/BeagleDancer/tree/master/devicetree and compiled it using the compile method mentioned in my question and the command dtc -O dtb -o am335x-boneblack.dtb -b 0 -@ am335x-boneblack.dts. This successfully booted the BBB so that I could login.