Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Where did mkknlimg go?
View unanswered posts
View posts from last 24 hours

Goto page Previous  1, 2  
Reply to topic    Gentoo Forums Forum Index Gentoo on ARM
View previous topic :: View next topic  
Author Message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54317
Location: 56N 3W

PostPosted: Tue Jan 14, 2020 6:57 pm    Post subject: Reply with quote

pa4wdh,

The bcm2708 files ar for the armv6j based Pis. You don't have one of those, so they don't matter.
Code:
-rwxr-xr-x 1 root root   23481 Jan 14 18:58 bcm2708-rpi-b-plus.dtb
-rwxr-xr-x 1 root root   23222 Jan 14 18:58 bcm2708-rpi-b.dtb
-rwxr-xr-x 1 root root   22999 Jan 14 18:58 bcm2708-rpi-cm.dtb
-rwxr-xr-x 1 root root   23683 Jan 14 18:58 bcm2708-rpi-zero-w.dtb
-rwxr-xr-x 1 root root   22947 Jan 14 18:58 bcm2708-rpi-zero.dtb


Code:
-rw-r--r-- 1 root root    25265 Dec  3 12:41 bcm2709-rpi-2-b.dtb
is for the 32 bit only Pi2.

The bcm2710 files are for the Pis that have a 64 bit CPU
Code:
-rw-r--r-- 1 root root    25394 Dec  3 12:41 bcm2710-rpi-2-b.dtb
-rw-r--r-- 1 root root    26435 Dec  3 12:41 bcm2710-rpi-3-b.dtb
-rw-r--r-- 1 root root    27054 Dec  3 12:41 bcm2710-rpi-3-b-plus.dtb
-rw-r--r-- 1 root root    25249 Dec  3 12:41 bcm2710-rpi-cm3.dtb


You need one of those -rpi-2-b.dtb device trees.
Code:
-rw-r--r-- 1 root root    25265 Dec  3 12:41 bcm2709-rpi-2-b.dtb
-rw-r--r-- 1 root root    25394 Dec  3 12:41 bcm2710-rpi-2-b.dtb


You have bcm2709-rpi-2-b.dtb but are missing bcm2710-rpi-2-b.dtb. I don't know which one you need but its one of those with the Pi foundation kernel.
Not having a dtb loaded is fatal to the boot process. It describes to the kernel how to drive the hardware.
Code:
-rwxr-xr-x 1 root root   18084 Jan 14 18:58 bcm2835-rpi-b-rev2.dtb
-rwxr-xr-x 1 root root   17951 Jan 14 18:58 bcm2835-rpi-b.dtb
-rwxr-xr-x 1 root root   17999 Jan 14 18:58 bcm2835-rpi-cm1-io1.dtb
-rwxr-xr-x 1 root root   18347 Jan 14 18:58 bcm2835-rpi-zero-w.dtb
-rwxr-xr-x 1 root root   17873 Jan 14 18:58 bcm2835-rpi-zero.dtb
-rwxr-xr-x 1 root root   18764 Jan 14 18:58 bcm2836-rpi-2-b.dtb
-rwxr-xr-x 1 root root   20181 Jan 14 18:58 bcm2837-rpi-3-b-plus.dtb
-rwxr-xr-x 1 root root   19392 Jan 14 18:58 bcm2837-rpi-3-b.dtb

are provided by the mainline kernel.
bootcode.bin will not auto load those and a lot of functionality is missing on the Pi with the mainline kernel. Loot at the dtb filesize differences.

You may not mix and match the main kernel with the foundation device tree and vice versa.

You can name a device tree to use with
Code:
device_tree= ...
in config.txt.git

Comment out the
Code:
gpu_mem=16
in config.txt. Just in case that's too low for the GPU to draw a console. Put it back later.

What does
Code:
less /sys/firmware/devicetree/base/compatible
yay about your PI?
Code:
less /sys/firmware/devicetree/base/model
may be easier to understand.

Edit to fix code tags and a copy/paste error.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
pa4wdh
l33t
l33t


Joined: 16 Dec 2005
Posts: 815

PostPosted: Wed Jan 15, 2020 6:41 pm    Post subject: Reply with quote

All dtb files in the listing are provided by the mainline kernel, in this case the 4.19 one. The kernels install their files in /boot/dtbs/<version> and i copy them from there to the root of the sdcard depending on the kernel i'm using. I didn't find a setting for the dtb path before, so i'll check that out, that's a lot easier :)

Removing the gpu_mem=16 from config.txt did not make any difference.

I haven't tried sys-kernel/raspberrypi-image since that only provides 4.x kernels, and my problem is booting the 5.x kernel.

The requested outputs:
Code:

ntp-server /sys/firmware/devicetree/base # cat compatible
raspberrypi,2-model-bbrcm,bcm2836
ntp-server /sys/firmware/devicetree/base # cat model
Raspberry Pi 2 Model B Rev 1.1
ntp-server /sys/firmware/devicetree/base #

I added a newline after the outputs to make it more readable, the original output has the prompt right after the last character of the file's content.
_________________
The gentoo way of bringing peace to the world:
USE="-war" emerge --newuse @world

My shared code repository: https://code.pa4wdh.nl.eu.org
Music, Free as in Freedom: https://www.jamendo.com
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54317
Location: 56N 3W

PostPosted: Wed Jan 15, 2020 8:31 pm    Post subject: Reply with quote

pa4wdh,

That's a Raspberry Pi 2 Model B Rev 1.1, which is 32 bit only, fitted with the bcm2836 SoC.
That's the same as the one I tested on.

Try the Pi git 5.4.y kernel with the bcm2709_defconfig, which is what the Foundation use for the Pi2
Use it as it. I can build it if you like but not tonight.
You will need to install the modules to get an HDMI console as console support depends on module loading.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
pa4wdh
l33t
l33t


Joined: 16 Dec 2005
Posts: 815

PostPosted: Thu Jan 16, 2020 1:47 pm    Post subject: Reply with quote

I just build a 5.4 kernel with just the default config ... so that took a while :roll:

This kernel booted fine and is now running. This means there is something in my kernel config that causes the problem. So from now i'll slowly make changes to see where things go wrogn. Since the problem is so early in the boot process i think it's safe to rule out anything loaded as a module.
_________________
The gentoo way of bringing peace to the world:
USE="-war" emerge --newuse @world

My shared code repository: https://code.pa4wdh.nl.eu.org
Music, Free as in Freedom: https://www.jamendo.com
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54317
Location: 56N 3W

PostPosted: Thu Jan 16, 2020 5:49 pm    Post subject: Reply with quote

pa4wdh,

That's encouraging. That suggests that the hardware, including the PSU is good.
We still can't explain why the the kernel I built from your pastebin .config, that ran on my PI won't work on yours.

Did you try my entire /boot?
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
pa4wdh
l33t
l33t


Joined: 16 Dec 2005
Posts: 815

PostPosted: Thu Jan 16, 2020 6:26 pm    Post subject: Reply with quote

I'm curious which kernel setting I'll find to be the offending one :roll:

Yes, I did try your complete boot with the same results.
_________________
The gentoo way of bringing peace to the world:
USE="-war" emerge --newuse @world

My shared code repository: https://code.pa4wdh.nl.eu.org
Music, Free as in Freedom: https://www.jamendo.com
Back to top
View user's profile Send private message
pa4wdh
l33t
l33t


Joined: 16 Dec 2005
Posts: 815

PostPosted: Fri Jan 17, 2020 12:22 pm    Post subject: Reply with quote

With the new kernel running i found this in dmesg:
Code:
[   20.151311] Under-voltage detected! (0x00050000)
[   22.231252] Voltage normalised (0x00000000)

So it seems i might need a new PSU anyway, although it happened only once. It might be detected later now because it's loaded as a module and runs later in the boot process.

Besides the "official" RPi PSU, do you have any suggestions on what type of PSU i should buy?
_________________
The gentoo way of bringing peace to the world:
USE="-war" emerge --newuse @world

My shared code repository: https://code.pa4wdh.nl.eu.org
Music, Free as in Freedom: https://www.jamendo.com
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54317
Location: 56N 3W

PostPosted: Fri Jan 17, 2020 6:59 pm    Post subject: Reply with quote

pa4wdh,

You need a PSU that is 5v under load, measured at the Pi.
Undervoltage that never recovered would stop booting.

Is the undervoltage warning repeatable on every boot?
Does it go away if you try to reduce the power load?
e.g. remove the HAT.

Once you can get the Foundation kernel to boot with no undervoltage warnings, does your own kernel work too?

The undervolt detection is performed by the GPU it takes all the evasive action too and draws a lightning symbol in the graphics output.
Its all done by the files loaded to run on the GPU before the kernel is loaded.

Different SD cards can help. Newer ones use less power than older ones.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
pa4wdh
l33t
l33t


Joined: 16 Dec 2005
Posts: 815

PostPosted: Fri Jan 17, 2020 10:17 pm    Post subject: Reply with quote

I'm quite sure there is something with the 5.4 kernel that makes it consume more power.

I'm in the process of making small config changes to the kernel, recompile, reboot to is if it works, and continue until i find what makes it fail. Every reboot, at about 20 seconds of uptime, i get the undervoltage warning. My GPS even lost it's fix a few time during compiling, something that has never happened before, not even with an emerge -e @world, so that may be power-related.

My best guess now is that my PSU is somewhere on the limit and the 5.4 kernel somehow pulls it over the limit.

As far as reducing power consumption, I can't do any more than i did before (remove all connections, remove hat), and that didn't work.
_________________
The gentoo way of bringing peace to the world:
USE="-war" emerge --newuse @world

My shared code repository: https://code.pa4wdh.nl.eu.org
Music, Free as in Freedom: https://www.jamendo.com
Back to top
View user's profile Send private message
pa4wdh
l33t
l33t


Joined: 16 Dec 2005
Posts: 815

PostPosted: Mon Jan 20, 2020 10:40 pm    Post subject: Reply with quote

Well ... it took me a few days and 23 kernels, but the mystery is solved ... at least, partly.

I started off with the default config which worked and from there i started changing the config to what i actually want. In the end there is one option that makes all the difference between it booting and not booting at all, and it is: CONFIG_CLK_BCM2835 which was unset in my configuration and when i set it it boots.

The mystery that's now left is: Why did it boot on your Pi? Considering this driver was missing, it doesn't make sense that your Pi does something different to mine.

Also, something else happened: It was a bit more difficult than i expected to find a decent power supply, so it's still running with the old one, and the under-voltage warning has disappeared. The driver is still there, it just doesn't report the under-voltage anymore. I guess the power consumption has gone down with all the hardware i don't use (and don't load drivers for).
_________________
The gentoo way of bringing peace to the world:
USE="-war" emerge --newuse @world

My shared code repository: https://code.pa4wdh.nl.eu.org
Music, Free as in Freedom: https://www.jamendo.com
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on ARM All times are GMT
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum