RBPI2 ds1307 rtc kernel panic

Jukka Ukkonen jau789 at gmail.com
Sun Sep 27 17:02:46 UTC 2015



Sent from my iPad

> On 27 Sep 2015, at 18:57, Stefan Parvu <sparvu at kronometrix.org> wrote:
> 
> 
>> device        ds1307
>> 
>> In the DTS file (sys/boot/fdt/dts/arm/rpi.dts) I added
> 
> Thanks a lot for comments. Couple of questions:
> 
> 1. It seems I need to modify and add the rtc section under rpi2.dts not
> the bcm2836.dtsi. Do I need still to build the dtb file:
> 
> root at rpi2:/usr/src/sys/tools/fdt # setenv MACHINE arm
> root at rpi2:/usr/src/sys/tools/fdt # ./make_dtb.sh /usr/src/sys
> /usr/src/sys/boot/fdt/dts/arm/rpi2.dts .
> converting /usr/src/sys/boot/fdt/dts/arm/rpi2.dts -> ./rpi2.dtb
> Warning (reg_format): "reg" property in /axi/gpio/rtc has invalid length
> (4 bytes) (#address-cells == 2, #size-cells == 1)
> Warning (avoid_default_addr_size): Relying on default #address-cells
> value for /axi/gpio/rtc
> Warning (avoid_default_addr_size): Relying on default #size-cells value
> for /axi/gpio/rtc

Are there still your previous lines in the dtsi file?
I don't remember having seen those complaints in a while.
During my first attempts when I did not have the size-cells
and address-cells in the dts I certainly saw the exact same
warnings, though.

> 2. After modifying the rpi2.dts and the RPI2 kernel config file I just
> rebuild, right ? Nothing else ?

Actually, if I remember correctly buildkernel might run dtc
automatically when building for arm. It's been a while since
I setup my own rpi2 build scripts. So, I don't remember this
detail and at the moment I cannot go to check it on my
build system. If for some reason the dtb is not automatically
built, you certainly have to run dtc manually to get the dtb.

When I get my hands on my build system I will try to check
what it does with the dts and dtb files.
At one moment I actually used a prebuilt content for the fat16
boot partition and manually modified an older dtb file converting
it back to a dts with dtb, editing it converting again with dtc from
dts to dtb when the ds3231 info was added. So, in the worst
case I might have two distinct dtb files, one manually prebuilt
one which definitely works and another automatically built one,
which for all I know at the moment, could be faulty but also unused.

--jau



More information about the freebsd-arm mailing list