Jump to content

Boot hang for LibreELEC 5.5.6 Kernel


delius

Recommended Posts

Hi, Armbian gurus,

 

I'm trying to make the build system to build image with LibreELEC kernel tree for PineH64

I heard the kernel is patched for being better at hardware decoding

Here are what I have done in order:

1. Retrieve patched kernel tree from LibreELEC build system. Upload the patched kernel tree to my gitlab account.

2. Modify config/sources/families/include/sunxi64_common.inc to make KERNEL_SOURCE = my previous repo; KERNELBRACH = master. To make it fetchable during bilding.

3. Modify lib/compilation-prepare.sh: skip aufs patch.

4. Modify lib/compilation.sh: skip advanced_patch in compile_kernel()

 

After all these hassle, I can use compile.sh to build an Armbian 64 bit image with the 5.5.6 patched.

BUT unfortunately, I flash the image and found it cannot boot properly.

 

So here are my question:

1. How do you typically debug boot problem for PineH64.

2. Do you think anything could go wrong in those procedure?

3. Do I need to upgrade u-boot as well? It's using v2019.10 as far as I can tell.

 

Thank you.

 

 

Link to comment
Share on other sites

Hi, Werner

 

Thank you for the tip. You are certainly appreciated.

I will try to find whatever went wrong.

 

If anyone discover something wrong with those steps, please do not hesitate to share here.

Thank you.

Link to comment
Share on other sites

Hi, Armbian gurus,

 

These are the 2 copies of log I captured by USB-TTL.

Armbian + LibreELEC 5.5.6 kernel

Normal Bootable Armbian

 

The most critical difference I guess is this:

## Executing script at 4fc00000
U-boot loaded from SD
Boot script loaded from mmc
116 bytes read in 2 ms (56.6 KiB/s)
libfdt fdt_check_header(): FDT_ERR_BADMAGIC
No FDT memory address configured. Please configure
the FDT address via "fdt addr <address>" command.
Aborting!
9791617 bytes read in 983 ms (9.5 MiB/s)
15812616 bytes read in 1585 ms (9.5 MiB/s)

May someone share more insight about what could be wrong with this header checking stuff?

For example: which part of building might trigger this misbehavior?

Thank you.

Link to comment
Share on other sites

Hi, Armbian gurus,

 

I discover that the boot.cmd contains many statements about this FDT, including

"fdt addr ${fdt_addr_r}" and "fdt resize 65536."

 

May I ask about what is the proper size for these value? How to calculate these value?

With DTB/DTS replacement happened along the replaced kernel tree, could that trigger this problem?

 

I have to confess that I have very limited knowledge about u-boot, please drop me some tip or recommended reading if you think it's going to help, while I'm doing my own reading document from u-boot at the same time.

Thank you.

Link to comment
Share on other sites

Hi, Armbian gurus,

 

I'm replying to end multiple weeks of how did I manage to successfully replace default armbian kernel with LibreELEC one.

  1. Upload patched kernel tree to an git repo.
  2. Modify armbian build system config to redirect KERNELSOURCE to your repo. 
    For example: I modified config/sources/families/include/sunxi64_common.inc
  3. Fire up compile.sh as usual, but selecting "Show a kernel configuration menu before compilation."
  4. When kernel menuconfig show up, load your modified kernel config

 

Now you might need optionally disable some patches if the building went wrong. Check your build/userpatches/kernel/<family>/ 

After these, I can produce Armbian image with patched LibreELEC kernel.

 

I hope it might help someone and also close this this discussion.

Thank you.

 

Link to comment
Share on other sites

On 3/24/2020 at 10:01 AM, delius said:

I heard the kernel is patched for being better at hardware decoding

 

Not sure if there is any crucial difference in kernel side - hw acceleration . What we miss here are userland librarires / players to play the content accelerated. If you don't build KODI that way, its pointless, while general purpose Linux distro does not need to sort that out first. Only when someone finds time ...

This https://github.com/armbian/build/blob/master/config/kernel/linux-sunxi-current.config#L5600-L5602 has to be enabled in the DEV config https://github.com/armbian/build/blob/master/config/kernel/linux-sunxi64-dev.config#L5422

 

3 hours ago, delius said:

After these, I can produce Armbian image with patched LibreELEC kernel.


The main idea is to bring the perhaps some multimedia fixes, that are in that kernel but not in the Armbian, which already migrated DEV branch to 5.6.y - we have test images out for most of the boards and with armbian-configfu you can switch to that kernel and see how it works.

 

 

Link to comment
Share on other sites

7 hours ago, Igor said:

Merged.

 

 dmesg |grep -i cedr
[    5.459706] sunxi_cedrus: module is from the staging directory, the quality is unknown, you have been warned.
[    5.461530] cedrus 1c0e000.video-codec: Device registered as /dev/video0

It is there. No idea how to use it though.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines