Author Topic: Linux kernel version 6 support  (Read 1282 times)

lfdebrux

  • Newbie
  • *
  • Posts: 7
    • View Profile
Linux kernel version 6 support
« on: July 05, 2022, 06:14:25 am »
Hi,

While submitting a patch to the kernel to improve the Zaurus support, it was mentioned that the maintainers for the PXA port are looking to rewrite the code to use the Devicetree format:

https://lore.kernel.org/linux-arm-kernel/CAK8P3a0HBvhe0MHjjO+WyEp669qd2NEC5RC7_jcvnEJM6X0Fug@mail.gmail.com/

They asked if I would like to help, which I said yes to, although I'm a bit new to kernel development.

Is there anyone else who'd like to get involved with this?
« Last Edit: July 05, 2022, 06:15:58 am by lfdebrux »

Varti

  • Administrator
  • Hero Member
  • *****
  • Posts: 1244
    • View Profile
Re: Linux kernel version 6 support
« Reply #1 on: July 05, 2022, 07:00:49 am »
Thanks a lot for taking care of this, I really hope that Zaurus' support will be kept in the future 6.x kernel. I also hope that sa1100 support for the 5500 will be kept too, I have read that qemu already supports it and Linus Walleij seems to be interested to port it to DT:

https://lore.kernel.org/linux-arm-kernel/CACRpkdY2_ZbmcSuuMB9t5bB-tGE0iAc-nE26JwxidRFocRahSw@mail.gmail.com/

I'm not a developer, and unfortunately in general I don't have much free time, but I can help with testing the kernel builds on real hardware, as I have a collection of working Zauruses: I have all the models starting from the 5500 to the SL-C3200.

Varti
Planet Gemini PDA WiFi/LTE with Mediatek x27
SL-C1000 running Arch Linux ARM May2017, K30225 Wi-Fi CF Card, 64GB SDXC card
and many other Zauruses!

greguu

  • Global Moderator
  • Sr. Member
  • *****
  • Posts: 425
    • View Profile
    • http://github.com/greguu
Re: Linux kernel version 6 support
« Reply #2 on: July 13, 2022, 12:42:33 am »
Hi,

I had actually planned to work on migrating spitz.c to DT this year, but to be fair I have not had the time and focus to work on it so far.

As pointed out in the mailing list, while moving PXA270 targets to DT should be relatively straight forward, there are some exotic boards and I think some Sharp devices fall in that category. But with some support from the kernel dev team we should be able to get this moving before spitz.c is dropped.

I got a Borzoi, but I also some ZipIt2 devices that are PXA270 based. For those the move to DT was partially done, but not submitted upstream.

What kernel version did you work with so far and do you have any patches apart from the one you send through to the mailing list ?
What bootloader and rootfs do you use on your Zaurus ?

Also I have not tested kexecboot alongside a DT file yet and do not know if kexecboot supports it, but we can always append the compiled DT to the kernel image.

While maintaining the kernel is a priority, we lost Arch Linux ARM armv5tel support earlier this year and the custom Void Linux build (voidz) is due for a new build as well, or any other distribution that still supports armv5tel.. as not all users want to spin up their own rootfs using buildroot or the like.

Happy to get involved, but a bit cautious about on how much I can commit myself to this activity over the next months as I started this year to port an Intel based ARM board IXP43x based to DT and wanted to progress with this one first before picking up the Zaurus again, but perhaps this can go hand in hand.

Cheers,
Greg

Hi,

While submitting a patch to the kernel to improve the Zaurus support, it was mentioned that the maintainers for the PXA port are looking to rewrite the code to use the Devicetree format:

https://lore.kernel.org/linux-arm-kernel/CAK8P3a0HBvhe0MHjjO+WyEp669qd2NEC5RC7_jcvnEJM6X0Fug@mail.gmail.com/

They asked if I would like to help, which I said yes to, although I'm a bit new to kernel development.

Is there anyone else who'd like to get involved with this?
Gemini-PDA (Sailfish X and Android) / LG Nexus 5 (Android 11) / Nokia N9 (MeeGo/Harmattan)
Sharp Zaurus C3100 (Borzoi) - Void Linux (voidz) Kernel 5.0.0 - Hardware (Buffalo CF LAN, DLink 660 CF WiFi, ASIX AX88772 USB Ethernet)

lfdebrux

  • Newbie
  • *
  • Posts: 7
    • View Profile
Re: Linux kernel version 6 support
« Reply #3 on: July 13, 2022, 05:40:44 pm »
Hi Greg!

Your work on Void Linux has been a massive help and inspiration, so you've already done loads for me!

I got a Borzoi, but I also some ZipIt2 devices that are PXA270 based. For those the move to DT was partially done, but not submitted upstream.

That's interesting, are those patches available anywhere to look at?

What kernel version did you work with so far and do you have any patches apart from the one you send through to the mailing list ?

I'm currently running kernel 5.16.41 and a fork of your 'Voidz' Linux repo. The main difference to your repo is it follows upstream a bit more closely. You can see the interesting changes by going to

http://github.com/void-linux/void-packages/compare/master...lfdebrux:voidz-packages:voidz

Edited to add: Oh, and I'm also working on getting the 5.19 release candidate working, I have some other patches that are work in progress, my code is at https://github.com/lfdebrux/linux/tree/zaurus/fix-corgi-backlight-v3.

What bootloader and rootfs do you use on your Zaurus ?

Also I have not tested kexecboot alongside a DT file yet and do not know if kexecboot supports it, but we can always append the compiled DT to the kernel image.

For bootloader I'm relying on your 'frankenstein' linux 2.6 kexecboot, which works great on my devices (I have a Spitz and an Akita). On my todo list is getting the OpenEmbedded machinery back up and running so I can build a new kexecboot. I know that the latest versions of kexecboot do have support for devicetree, although I don't fully understand how botting with device tree blobs works yet.
« Last Edit: July 13, 2022, 07:54:19 pm by lfdebrux »

lfdebrux

  • Newbie
  • *
  • Posts: 7
    • View Profile
Re: Linux kernel version 6 support
« Reply #4 on: July 13, 2022, 05:45:07 pm »
Thanks a lot for taking care of this, I really hope that Zaurus' support will be kept in the future 6.x kernel. I also hope that sa1100 support for the 5500 will be kept too, I have read that qemu already supports it and Linus Walleij seems to be interested to port it to DT:

https://lore.kernel.org/linux-arm-kernel/CACRpkdY2_ZbmcSuuMB9t5bB-tGE0iAc-nE26JwxidRFocRahSw@mail.gmail.com/

I will try, no promises though!

I'm not a developer, and unfortunately in general I don't have much free time, but I can help with testing the kernel builds on real hardware, as I have a collection of working Zauruses: I have all the models starting from the 5500 to the SL-C3200.

That's very cool! I may ask for testing things in future, I currently have an Akita and a Spitz, but I sometimes have issues that I'm not sure whether they are specific to my hardware or not.

greguu

  • Global Moderator
  • Sr. Member
  • *****
  • Posts: 425
    • View Profile
    • http://github.com/greguu
Re: Linux kernel version 6 support
« Reply #5 on: July 14, 2022, 01:40:55 am »

Good stuff, great to see someone picking up the void build.
It's a bit work to keep following upstream, but if regularly build, it's manageable.
I dropped the ball on it as there was not really much of a user-base, at least not known to me via this forum.

In regards to the DT patched for the ZipIt, these can be found here: https://github.com/openwrt-zipit/openwrt-pxa-target/tree/master/pxa/patches-4.4
The ZipIt is quite different in some aspects to the Zaurus, but the CPU is the same.
The patches may give some insight on how to move from platform file to DT though.

..

Yes, need to try the latest kernels. How does the 5.16 work for you vanilla ?
I would think it will just boot, but did mmc and pcmcia/cf work out of the box ?
Does the screen fade white if not used for a while ?
Yatli did some fixes for 5.4 here recently as well : https://github.com/yatli/linux-zaurus-5.4

..

I build kexecboot natively on Arch Linux ARM the last time as always keen to avoid setting up OE build chain for some reason.
There should be support for DT in kexecboot, but I never used it. 

For a new kexecboot kernel that eventually will use DT, we will need to append the .dtb to the zImage as the Zaurus bootloader will not understand DT.
I hope we can actually trim a newer 5.x or even 6.x to fit into the kernel Zaurus kernel partition! It was getting pretty tight with 4.x even.

Gemini-PDA (Sailfish X and Android) / LG Nexus 5 (Android 11) / Nokia N9 (MeeGo/Harmattan)
Sharp Zaurus C3100 (Borzoi) - Void Linux (voidz) Kernel 5.0.0 - Hardware (Buffalo CF LAN, DLink 660 CF WiFi, ASIX AX88772 USB Ethernet)

lfdebrux

  • Newbie
  • *
  • Posts: 7
    • View Profile
Re: Linux kernel version 6 support
« Reply #6 on: July 23, 2022, 05:22:29 pm »

Good stuff, great to see someone picking up the void build.
It's a bit work to keep following upstream, but if regularly build, it's manageable.


Yes, it's not too bad! Unfortunately I don't have somewhere to host so am unable to share the binaries.


Yes, need to try the latest kernels. How does the 5.16 work for you vanilla ?
I would think it will just boot, but did mmc and pcmcia/cf work out of the box ?
Does the screen fade white if not used for a while ?
Yatli did some fixes for 5.4 here recently as well : https://github.com/yatli/linux-zaurus-5.4


SD Card and CF work no issues with vanilla 5,16 kernel! The fade to white issue is interesting, I had an issue with my SL-C1000 where the screen would turn white when suspending, and then coming out of suspend would be very difficult, but with the SL-C3000 it suspends just fine. I thought it might be something broken with my device, having other people test would be helpful. I do have some other issues though, including offline charging not working.


I build kexecboot natively on Arch Linux ARM the last time as always keen to avoid setting up OE build chain for some reason.
There should be support for DT in kexecboot, but I never used it.


Ah, interesting, I must try that sometime.

lfdebrux

  • Newbie
  • *
  • Posts: 7
    • View Profile
Re: Linux kernel version 6 support
« Reply #7 on: July 23, 2022, 05:36:22 pm »
So a proposal to start removing board files supporting older ARM devices has been made:

https://lore.kernel.org/linux-arm-kernel/20220721141722.2414719-4-arnd@kernel.org/

The SL-C3000 machines have been spared because I volunteered to convert it to devicetree, but lots of other Zaurus models have been marked as unused, including the SL-5500 type.

greguu

  • Global Moderator
  • Sr. Member
  • *****
  • Posts: 425
    • View Profile
    • http://github.com/greguu
Re: Linux kernel version 6 support
« Reply #8 on: August 11, 2022, 10:39:13 pm »
Great initiative.. perhaps some are interested to join the IRC channel for collaboration on this effort... ?
Gemini-PDA (Sailfish X and Android) / LG Nexus 5 (Android 11) / Nokia N9 (MeeGo/Harmattan)
Sharp Zaurus C3100 (Borzoi) - Void Linux (voidz) Kernel 5.0.0 - Hardware (Buffalo CF LAN, DLink 660 CF WiFi, ASIX AX88772 USB Ethernet)

yatli

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: Linux kernel version 6 support
« Reply #9 on: August 12, 2022, 03:35:01 am »
Where's the party :D :D

greguu

  • Global Moderator
  • Sr. Member
  • *****
  • Posts: 425
    • View Profile
    • http://github.com/greguu
Re: Linux kernel version 6 support
« Reply #10 on: November 03, 2022, 11:33:32 pm »
Everyone is waiting for @yatli to join the party 8)
Gemini-PDA (Sailfish X and Android) / LG Nexus 5 (Android 11) / Nokia N9 (MeeGo/Harmattan)
Sharp Zaurus C3100 (Borzoi) - Void Linux (voidz) Kernel 5.0.0 - Hardware (Buffalo CF LAN, DLink 660 CF WiFi, ASIX AX88772 USB Ethernet)

greguu

  • Global Moderator
  • Sr. Member
  • *****
  • Posts: 425
    • View Profile
    • http://github.com/greguu
Re: Linux kernel version 6 support
« Reply #11 on: January 16, 2023, 01:13:12 am »
Just back out of the holidays and I stumbled across this commit (2023 Spring Cleaning). https://git.kernel.org/pub/scm/linux/kernel/git/soc/soc.git/commit/?h=for-next&id=94ac29dc59d029c6ff61509e3b58fa0beb1f2966

While not unexpected, it is still sad to see such a large amount of unmaintained ARM SoC's getting purged.

The good news is the Cxx00 series (Akita/Spitz/Borzoi) is to remain within linux 6.2 and this gives again some time to move them to device tree, or at least assist in the process of it and do some testing.

Unfortunately, the bad news is that Corgi, Tosa and Poodle are marked as to be removed. I just got a Corgi donated :\

It would be a good idea to move the discussion into the #oesf IRC channel on oftc.net to work out some plan / project / work load sharing for those with some experience in kernel development and device tree. Leave a post below if you like to join the effort. :o
« Last Edit: January 16, 2023, 01:15:09 am by greguu »
Gemini-PDA (Sailfish X and Android) / LG Nexus 5 (Android 11) / Nokia N9 (MeeGo/Harmattan)
Sharp Zaurus C3100 (Borzoi) - Void Linux (voidz) Kernel 5.0.0 - Hardware (Buffalo CF LAN, DLink 660 CF WiFi, ASIX AX88772 USB Ethernet)

Varti

  • Administrator
  • Hero Member
  • *****
  • Posts: 1244
    • View Profile
Re: Linux kernel version 6 support
« Reply #12 on: January 16, 2023, 03:45:37 am »
Hi greguu, nice to hear you back, I hope you had a good holiday. Yes, the removal of Corgi/Tosa/Poodle support is heartbreaking, although as you said not unexpected. I still hope for someone to step in and do the necessary changes to devicetree for these devices. Nice to hear also that your Zaurus collection is being expanded.
This reminds me that I still need to do the testing you asked a while ago, ouch  :( I'll see if I can find some free time in the next days.

Varti
Planet Gemini PDA WiFi/LTE with Mediatek x27
SL-C1000 running Arch Linux ARM May2017, K30225 Wi-Fi CF Card, 64GB SDXC card
and many other Zauruses!

lfdebrux

  • Newbie
  • *
  • Posts: 7
    • View Profile
Re: Linux kernel version 6 support
« Reply #13 on: January 16, 2023, 04:22:38 pm »
It would be a good idea to move the discussion into the #oesf IRC channel on oftc.net to work out some plan / project / work load sharing for those with some experience in kernel development and device tree. Leave a post below if you like to join the effort. :o

I'll admit that I haven't got as far as I hoped in the time since I last posted, but I would still like to be involved. I will join the IRC channel.