Jump to content

x96max : from balbes images to linux-image-current-meson64


Recommended Posts

Posted

Hi,

 

I would like to maintain the kernel version updated on the box (for video reading performance because I still got some stearing when the camera moves horizontaly).
Now that there is no more support for amlogic (I can understand why reading the forum), can I use the available bullseye/linux-image-current-meson64 package from the armbian repo (which is now 5.9.6 not 5.9.0)?

 

As I understand is it not that easy to compile a kernel by myself because there is so much patches applied.

 

Best regards,

Laurent.

Posted

The short answer is maybe.  Your question got me to experimenting a bit this morning and I was successful in getting a box (TX3 mini in my case) to boot from a current armbian meson64 kernel (5.9.14).  My box is amlogic s905w, where yours I believe is s905x2.  I had been wanting to try this for a while, but hadn't had time/reason to do it, but your question led me to give it a try. 

 

If you are running from an SD card there is no reason not to experiment as you can always easily start over if you can't boot.

 

Here are the steps I did:

1) backup old kernel files in case things go wrong:

cd /boot

sudo cp uInitird uInitrd-5.9.0

sudo cp zImage zImage-5.9.0

sudo cp -r dtb dtb-5.9.0

# if things fail you can pop the sd card into another box and revert these

 

2) edit extlinux.conf

change the "LINUX /zImage" line to "LINUX /Image"

#there is different kernel file naming between balbes images and armbian kernels, Image is what I found in the kernel I installed, but different packages may have different names so adjust accordingly.  If you need to revert to the old kernel you will need to undo this change as well.

 

3) Install the new kernel package, I used:

sudo apt install linux-image-current-meson64

#the installation errored at the end and I didn't bother to figure out why (although from past experience it is likely to have to do with the fact that balbes uses fat partitions for boot, whereas standard armbian uses ext4 partitions).  But at the point it errors everything is installed in /boot that is needed which is why I didn't investigate further at the current time.

 

4) reboot and cross your fingers

 

 

On 11/14/2020 at 6:06 AM, lgranie said:

As I understand is it not that easy to compile a kernel by myself because there is so much patches applied.

This is both true and untrue.  The standard armbian kernels are heavily patched as they are trying to incorporate a lot of fixes and drivers to get a wide range of SBC boards working as completely as possible.  But if all you need is a basic environment that boots with hdmi and ethernet you can use a mainline kernel with hardly any patches on a lot of TV boxes (which is what I normally do).

 

 

I also want to mention something that I was working on over the weekend that you should be aware of.  As it relates to s905x2 and/or s905x3 support and 5.10 kernels.  I haven't been able to boot my TV boxes running these cpus on 5.10 kernels.  I can boot my s905w boxes on 5.10 however.  I think there is an issue with the u-boots that balbes included for the x2/x3 cpus that are having issues with the changes in the 5.10 kernel.  Someday I hope to dig into this further, but for now I am running those boxes on the 5.4 mainline LTS kernels as it will give me bug/security fixes for a few more years which will give me or someone else time to investigate the issue in the future.

 

Posted
On 1/5/2021 at 4:28 PM, SteeMan said:

The short answer is maybe...

 

I tried today.

To test I use an sd card with last aml/balbes images, chroot to it and

apt update

apt install linux-image-current-meson64

edit /boot/extlinux/extlinux.conf

I manage to boot on it. \o/

 

So I reboot on emmc, backup some original /boot files and install the package.

I set manually the package to "install ok installed" in /var/lib/dpkg/status to avoid futur error when updating.

Now running on a 5.9.14 kernel. Will see if it is as stable than with 5.9.0

 

/boot partition (u-boot) can be ext3/4 on x96max?

Posted
1 hour ago, lgranie said:

/boot partition (u-boot) can be ext3/4 on x96max?

Yes you can use ext3/4 filesystems if you want.  The reason the balbes images use fat partitions for /boot is because of the necessity to edit the config files for the dtb.  Many users only have windows/mac os systems and therefore it was decided that the ease of being able to pop in the SD card into any machine regardless of OS and edit the config file (due to the universal support of the fat filesystem) to set the appropriate dtb was desirable.

Posted
On 1/5/2021 at 5:28 PM, SteeMan said:

Someday I hope to dig into this further, but for now I am running those boxes on the 5.4 mainline LTS kernels as it will give me bug/security fixes for a few more years which will give me or someone else time to investigate the issue in the future.


Hi SteeMan,

where one can find the 5.4 mainline images for amlogic? The balbes' resources hold only latest 5.10 builds
 

Posted

I build my own from mainline kernel sources.  Since I only am using this for server tasks, I can use pure mainline kernel without the need for any additional patches for my needs.

Posted
11 hours ago, SteeMan said:

I build my own from mainline kernel sources.  Since I only am using this for server tasks, I can use pure mainline kernel without the need for any additional patches for my needs.


Sorry for a stupid question, but are those mainline builds able to detect the integrated wifi chip?
 

Posted
2 hours ago, thanxx said:

are those mainline builds able to detect the integrated wifi chip?

As is stated here: https://forum.armbian.com/topic/16407-please-read-first

it shouldn't be an expectation that wifi is going to work with armbian on TV boxes.  I have about 8 boxes now and wifi doesn't work on any of them.  While there are exceptions, in general if you limit your expectations to using wired ethernet you can do some amazing things with these boxes.  Since you didn't even mention which box you are interested in, I can't guess if wifi has a remote possibility of working for you, but my guess is not.

 

There are only a couple of people currently engaged in volunteering their time to respond to users in the TV box forums.  So I choose to focus my limited resources on helping users who have a reasonable chance of success (i.e. their expectations are appropriate).  Otherwise I could spend all my time trying to help one user try to get wifi working on one poorly supported TV box type and likely be unsuccessful in the end.

 

Posted
On 1/20/2021 at 3:49 AM, lgranie said:

- format /boot in ext4

A couple of thoughts/questions on this.  First why do you want to do this?  I understand some of the limitations of having /boot be on a fat filesystem, but is there some specific thing you need this for? 

Second, this is likely not going to be easy as the amlogic TV box booting process is tied to the fact that /boot is on a fat partition.  If you look at aml_autoscript, s905_autoscript, emmc_autoscript they are coded with /boot being on a fat filesystem (i.e. using 'fatload').  If your goal is to get the standard armbian kernels to install cleanly on a /boot fat filesystem, then it may be easier to get armbian fixed.  Theoretically armbian supports /boot on a fat file system (there is code in the scripts to allow that), but it likely isn't tested much.

Posted
On 1/8/2021 at 12:43 PM, lgranie said:

I tried today.

To test I use an sd card with last aml/balbes images, chroot to it and

apt update

apt install linux-image-current-meson64

edit /boot/extlinux/extlinux.conf

I manage to boot on it. \o/

 

So I reboot on emmc, backup some original /boot files and install the package.

I set manually the package to "install ok installed" in /var/lib/dpkg/status to avoid futur error when updating.

Now running on a 5.9.14 kernel. Will see if it is as stable than with 5.9.0

 

/boot partition (u-boot) can be ext3/4 on x96max?

Hello, could you please detail step by step how to do this and finally have armbian with linux kernel 5.10 on my Tanix TX3 tv box. Another thing that I wonder is if I achieve this by running armbian only on the Sdcard or I also install it on the emmc, which is my goal. I am very aware of your guidance ... thank you for what you can help me.

Posted

Hi,

 

I tried but did not manage to boot on the last linux-image-current-meson64 (5.10 kernel) from armbian.

I will try soon with the debian linux-image-arm64 and let you know.

 

Regard,

Laurent.

Posted
On 1/21/2021 at 4:16 PM, SteeMan said:

A couple of thoughts/questions on this.  First why do you want to do this?  I understand some of the limitations of having /boot be on a fat filesystem, but is there some specific thing you need this for?

I want to do this so when I install linux-image-current-meson64 or other kernel package I do not have error because it looks like the package's script is expecting a ext3/4 partition.

Posted
3 hours ago, lgranie said:

I want to do this so when I install linux-image-current-meson64 or other kernel package I do not have error because it looks like the package's script is expecting a ext3/4 partition.

The fix for this would be on the armbian side (for the linux-image-current-meson64 package).  It is a one line fix in the postinst script.  I plat to submit a PR for this fix when I get a chance.

Posted

Few days ago linux-image-current.meson64 package from armbian was updated.

But I can not manage to boot on it : my screen stay black that's all.

 

I have to come back to the previous version that you can find here :

https://us.mirrors.fossho.st/armbian/apt/pool/main/l/linux-5.9.14-meson64/

To avoid future update, I use the following command :

sudo apt-mark hold linux-dtb-current-meson64 linux-image-current-meson64

 

I also try with linux-image-arm64 from debian (bulleyes) which is also a 5.10 kernel.
I've got the same results : no boot, black screen.

 

On 2/5/2021 at 5:53 PM, jbolanosg said:

Hello, could you please detail step by step how to do this and finally have armbian with linux kernel 5.10 on my Tanix TX3 tv box.

I did not manage to run a 5.10 packaged kernel on my x96max.

Posted
8 hours ago, lgranie said:

I did not manage to run a 5.10 packaged kernel on my x96max.

The chain loaded u-boots for s905x2/x3 in the balbes 10/14/2020 build do not support kernels greater than 5.9, due to the changes in the 5.10 kernel.  Also there is a change in 5.10 that breaks ethernet on these cpus as well in some cases.

 

To fix the u-boot problem you should use the following u-boots from hexdump: g12a-u-boot.bin (s905x2) and sm1-u-boot.bin (s905x3) from https://github.com/hexdump0815/u-boot-misc/releases/tag/200926-01 (renamed to u-boot-ext).

 

If you run into the ethernet issue, that should be solved by reverting with this patch: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/arch/arm64/boot/dts/amlogic?h=v5.11-rc7&id=19f6fe976a61f9afc289b062b7ef67f99b72e7b9  (This fix was just rolled into 5.11.0-rc7 this past week, it hasn't made it into 5.10.y yet)

 

I am in the process of testing all of the above to verify that I can get 5.10 and higher kernels working on my own s905x2 and s905x3 boxes.  So the above may or may not be correct until it is verified.

 

Posted
4 hours ago, lgranie said:

If I want to boot from emmc, I have to rename it to u-boot.emmc?

No you don't need to do that, the script will do whats necessary to take the working SD environment and copy it to internal emmc.  And that involves among other things creating a file called u-boot.emmc

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

Important Information

Terms of Use - Privacy Policy - Guidelines