Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post Reply
User avatar
tobetter
Posts: 9777
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 624 times
Been thanked: 1641 times
Contact:

Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by tobetter »

I've recently worked to bring up upstream kernel with many patches from Rockchip upstream kernel developers, greatly appreciate to them, finally I can build up a branch on top of upstream kernel v5.18-rc3 and next version v5.18-rc4 is being built now as of 2022/04/25.
https://github.com/tobetter/linux/tree/odroid-5.18.y

What are working:
  • Can boot up from SD/eMMC/SATA/NVMe with Petitboot
  • Can boot up from SD/eMMC without Petitboot
  • On-board 1Gbps ethernet
  • HDMI display output
  • USB 2.0 host ports
  • Panfrost works
What are not working:
  • HDMI audio outputs
  • USB 3.0 host ports
  • And more and many
Download links:
The default acount and its password is odroid as usual. The images with upstream kernel would not be stable enough and features are not fully supported, so please do not use this image for your important project or to store important data. Welecome your feedback and your patches or instructions to improve the experience with the images.
Attachments
Screenshot from 2022-04-25 08-47-56.png
Screenshot from 2022-04-25 08-47-56.png (1.09 MiB) Viewed 1536 times
These users thanked the author tobetter for the post (total 6):
istanbulls (Mon Apr 25, 2022 7:52 pm) • superpowter77 (Mon Apr 25, 2022 8:23 pm) • odroid (Mon Apr 25, 2022 9:48 pm) • mctom (Wed Apr 27, 2022 2:57 pm) • masesisaac (Thu Apr 28, 2022 10:45 pm) • arm_addict (Tue May 03, 2022 3:50 am)

User avatar
tobetter
Posts: 9777
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 624 times
Been thanked: 1641 times
Contact:

Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by tobetter »

Reserved...

User avatar
istanbulls
Posts: 717
Joined: Tue May 14, 2019 10:18 pm
languages_spoken: Turkish
ODROIDs: ODROID; N2, C4, XU4, N2+, CH4
Location: Istanbul-Turkey
Has thanked: 428 times
Been thanked: 125 times
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by istanbulls »

Don't forget your keyboard in the usb3 port like I did, you'll waste an hour. :D

nexusxe
Posts: 1
Joined: Sun Apr 17, 2022 1:55 am
languages_spoken: english
ODROIDs: ODROID M1
Has thanked: 0
Been thanked: 0
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by nexusxe »

Consider taking a look at some of the Armbian patches for the Rock-3a. These, if configured correctly, will work with this board. Specifically, this USB 3.0 patch

zupet
Posts: 173
Joined: Tue Dec 26, 2017 11:13 pm
languages_spoken: korean,english
ODROIDs: HC1
Has thanked: 5 times
Been thanked: 28 times
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by zupet »

I'm waiting for USB 3.0 !!

brad
Posts: 1595
Joined: Tue Mar 29, 2016 1:22 pm
languages_spoken: english
ODROIDs: C2 C4 HC4 N1 N2 N2+ H2 H2+ M1 (64 bit ftw)
Location: Australia
Has thanked: 178 times
Been thanked: 251 times
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by brad »

PCIE patches were submitted - https://lwn.net/Articles/892691/

User avatar
tobetter
Posts: 9777
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 624 times
Been thanked: 1641 times
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by tobetter »

Please welcome USB 3.0 with Linux kernel 5.18-rc5.

Code: Select all

tobetter@localhost:~$ uname -a
Linux localhost 5.18.0-odroid-arm64 #1 SMP PREEMPT Ubuntu 5.18.0-202205022244~jammy (2022-05-02) aarch64 aarch64 aarch64 GNU/Linux
tobetter@localhost:~$ lsusb -t
/:  Bus 06.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 5000M
    |__ Port 1: Dev 2, If 0, Class=Mass Storage, Driver=usb-storage, 5000M
/:  Bus 05.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 480M
/:  Bus 04.Port 1: Dev 1, Class=root_hub, Driver=ohci-platform/1p, 12M
/:  Bus 03.Port 1: Dev 1, Class=root_hub, Driver=ohci-platform/1p, 12M
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=ehci-platform/1p, 480M
    |__ Port 1: Dev 2, If 0, Class=Hub, Driver=hub/4p, 480M
        |__ Port 2: Dev 3, If 0, Class=Human Interface Device, Driver=usbhid, 12M
        |__ Port 2: Dev 3, If 1, Class=Human Interface Device, Driver=usbhid, 12M
        |__ Port 3: Dev 4, If 0, Class=Human Interface Device, Driver=usbhid, 1.5M
        |__ Port 3: Dev 4, If 1, Class=Human Interface Device, Driver=usbhid, 1.5M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=ehci-platform/1p, 480M
These users thanked the author tobetter for the post (total 7):
arm_addict (Tue May 03, 2022 3:50 am) • odroid (Tue May 03, 2022 9:23 am) • superpowter77 (Tue May 03, 2022 4:37 pm) • zupet (Tue May 03, 2022 5:13 pm) • istanbulls (Wed May 04, 2022 10:11 pm) • aodv (Thu May 05, 2022 12:12 am) • drolid (Mon May 09, 2022 7:58 am)

boschtracer
Posts: 10
Joined: Wed Jan 05, 2022 3:17 am
languages_spoken: english
ODROIDs: n2plus
Has thanked: 4 times
Been thanked: 0
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by boschtracer »

FWIW: Under 22.04 and Kernel 5.18 - the CPU appears to be missing(?) support in the kernel:

Odroid M1:

Linux 5.18.0-odroid-arm64 #1 SMP PREEMPT Ubuntu 5.18.0-202205022244~jammy (2022-05-02) aarch64 aarch64 aarch64 GNU/Linux

sbc-bench.sh:

##########################################################################

Testing clockspeeds again. System health now:

Time CPU n/a load %cpu %sys %usr %nice %io %irq Temp
08:50:02: --- 3.37 86% 1% 84% 0% 0% 0% 38.9°C

Checking cpufreq OPP (Cortex-A55):

No cpufreq support available. Measured on cpu1: 935 Mhz (933.708/812.311/760.893)

##########################################################################

Executing benchmark twice on cluster 0 (Cortex-A55)

OpenSSL 3.0.2, built on 15 Mar 2022 (Library: OpenSSL 3.0.2 15 Mar 2022)
type 16 bytes 64 bytes 256 bytes 1024 bytes 8192 bytes 16384 bytes
aes-128-cbc 72236.70k 213880.26k 419012.78k 553102.34k 609454.76k 614165.16k
aes-128-cbc 72315.82k 213883.05k 419096.15k 553115.99k 609793.37k 614536.53k
aes-192-cbc 68858.98k 190555.20k 340798.63k 426080.94k 459145.22k 459603.97k
aes-192-cbc 68871.84k 190072.62k 340006.49k 425955.33k 459380.05k 459909.80k
aes-256-cbc 66659.17k 174845.23k 294171.82k 355886.08k 379073.88k 380611.24k
aes-256-cbc 66725.15k 175158.21k 293956.78k 356014.42k 378844.50k 379245.91k

##########################################################################

An Odroid C4 running 22.04 - numbers are over twice those of the M1 under 22.04:

Executing benchmark twice on cluster 0 (Cortex-A55)

OpenSSL 3.0.2, built on 15 Mar 2022 (Library: OpenSSL 3.0.2 15 Mar 2022)
type 16 bytes 64 bytes 256 bytes 1024 bytes 8192 bytes 16384 bytes
aes-128-cbc 186322.15k 549737.79k 1075143.85k 1426285.23k 1572375.21k 1576681.47k
aes-128-cbc 186421.69k 551662.51k 1077931.09k 1426470.23k 1572904.96k 1585037.31k
aes-192-cbc 177548.05k 491240.00k 878258.09k 1098241.02k 1184145.41k 1190942.04k
aes-192-cbc 177540.23k 491167.23k 880059.56k 1098149.21k 1184230.06k 1186501.97k
aes-256-cbc 172085.49k 451624.28k 759133.35k 917881.86k 971235.33k 976890.54k
aes-256-cbc 172078.47k 451561.05k 759067.65k 917442.90k 977223.68k 981827.58k

Related: when trying to look at various M1 CPU information:

cat /sys/devices/system/cpu/cpufreq/policy0/related_cpus
cat: /sys/devices/system/cpu/cpufreq/policy0/related_cpus: No such file or directory

cat /sys/devices/system/cpu/cpufreq/policy0/scaling_available_frequencies
cat: /sys/devices/system/cpu/cpufreq/policy0/scaling_available_frequencies: No such file or directory

FYI: I didn't attempt sbc-bench.sh under 20.04. I installed 20.04 via petitboot and upgraded to 22.04 straight away knowing it wasn't fully supported yet.

tenkawa
Posts: 2
Joined: Sat Apr 30, 2022 12:10 am
languages_spoken: english
ODROIDs: N2+ N2 M1
Has thanked: 1 time
Been thanked: 1 time
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by tenkawa »

Is there a source deb that can be pulled and be rebuilt and packaged with this kernel to make adjustments and tune? I am current doing this with the 4.19 kernel with no problems however when I retrieve the apt-source for the kernel I still only retrieve the 5.15 source package. This also would allow address being able to fix issues like the above where cpu governors where not set in the config as well. If you need any information from me let me know.

User avatar
tobetter
Posts: 9777
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 624 times
Been thanked: 1641 times
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by tobetter »

tenkawa wrote:
Fri May 06, 2022 9:40 pm
Is there a source deb that can be pulled and be rebuilt and packaged with this kernel to make adjustments and tune? I am current doing this with the 4.19 kernel with no problems however when I retrieve the apt-source for the kernel I still only retrieve the 5.15 source package. This also would allow address being able to fix issues like the above where cpu governors where not set in the config as well. If you need any information from me let me know.
No source package, but can try with this branch.
https://github.com/tobetter/linux/commits/odroid-5.18.y
These users thanked the author tobetter for the post:
tenkawa (Fri May 06, 2022 9:50 pm)

specs
Posts: 121
Joined: Sun Nov 24, 2019 12:14 pm
languages_spoken: english
ODROIDs: Odroid N2/N2+/C4/M1
Has thanked: 30 times
Been thanked: 15 times
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by specs »

I just got the M1 and the SSD so I started testing.

The first image to install was the oiginal Hardkernel version of 20.04 with 4.19-kernel.
I was planning on making a second partition (actually 2 extra partitions) to test with 22.04 and the 5.18-kernel.

What would be the easiest method?
Install 22.04 on a SD-card and copy both partitions to the SSD?
I
Edit: it seems like the image is fit only for MMC, since I am not able to start form an SD-card.
Also copying it to the SSD does allow the system to start but it fails the same way as the SD-card when it is present.
Without SD-card it fails on a UUID problem, therefore it seems to be hardcoded to only one system. (eMMC?)

specs
Posts: 121
Joined: Sun Nov 24, 2019 12:14 pm
languages_spoken: english
ODROIDs: Odroid N2/N2+/C4/M1
Has thanked: 30 times
Been thanked: 15 times
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by specs »

A little followup for others who might try it:
Don't forget to plugin the network cable, it will save you hours.

After install remove cloud-init and reconfigure blocks the system from booting (I don't have time to look it up, but the missing network can be configured non-blocking, I believe with netplan).

I finally have the Hardkernel 20.04 and the tobetter 22.04 next to each other on the SSD.
Right now my 22.04-system is very slow and lacking in almost everything, but still the 5.18-kernel should be worth it eventually.

Neo2SHYAlien
Posts: 5
Joined: Wed May 11, 2022 3:23 am
languages_spoken: english
ODROIDs: M1
Has thanked: 2 times
Been thanked: 0
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by Neo2SHYAlien »

specs wrote:
Mon May 09, 2022 1:44 am
Right now my 22.04-system is very slow and lacking in almost everything, but still the 5.18-kernel should be worth it eventually.
I had the very same experience compared to Debian 10

vebryn
Posts: 1
Joined: Thu May 12, 2022 6:50 pm
languages_spoken: english
ODROIDs: odroid-m1
Has thanked: 0
Been thanked: 0
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by vebryn »

specs wrote:
Sun May 08, 2022 2:18 am
I just got the M1 and the SSD so I started testing.

The first image to install was the oiginal Hardkernel version of 20.04 with 4.19-kernel.
I was planning on making a second partition (actually 2 extra partitions) to test with 22.04 and the 5.18-kernel.

What would be the easiest method?
Install 22.04 on a SD-card and copy both partitions to the SSD?
I
Edit: it seems like the image is fit only for MMC, since I am not able to start form an SD-card.
Also copying it to the SSD does allow the system to start but it fails the same way as the SD-card when it is present.
Without SD-card it fails on a UUID problem, therefore it seems to be hardcoded to only one system. (eMMC?)
specs wrote:
Mon May 09, 2022 1:44 am
A little followup for others who might try it:
Don't forget to plugin the network cable, it will save you hours.

After install remove cloud-init and reconfigure blocks the system from booting (I don't have time to look it up, but the missing network can be configured non-blocking, I believe with netplan).

I finally have the Hardkernel 20.04 and the tobetter 22.04 next to each other on the SSD.
Right now my 22.04-system is very slow and lacking in almost everything, but still the 5.18-kernel should be worth it eventually.
Hi specs,

Thank you for your feedback,

I just purchased an odroid-m1. Like you, I would copy 20.04 version onto my ssd. According your boot error with sdcard image onto ssd. How did you finally manage to boot ?

Did you adjust sectors according Ubuntu partition table ?

User avatar
tobetter
Posts: 9777
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 624 times
Been thanked: 1641 times
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by tobetter »

New kernel package is uploaded with CPUFREQ fixes.

Code: Select all

$ dpkg -l | grep linux-image
ii  linux-image-5.18.0-odroid-arm64            5.18.0-202205132045~jammy               arm64        Linux 5.18 for 64-bit ARMv8 machines

Code: Select all

$ cat /sys/devices/system/cpu/cpufreq/policy0/scaling_governor 
performance
$ cat /sys/devices/system/cpu/cpufreq/policy0/cpuinfo_max_freq 
1992000
$ cat /sys/devices/system/cpu/cpufreq/policy0/cpuinfo_min_freq 
408000
These users thanked the author tobetter for the post:
boschtracer (Mon May 16, 2022 2:21 am)

specs
Posts: 121
Joined: Sun Nov 24, 2019 12:14 pm
languages_spoken: english
ODROIDs: Odroid N2/N2+/C4/M1
Has thanked: 30 times
Been thanked: 15 times
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by specs »

vebryn wrote:
Thu May 12, 2022 11:18 pm
Hi specs,

Thank you for your feedback,

I just purchased an odroid-m1. Like you, I would copy 20.04 version onto my ssd. According your boot error with sdcard image onto ssd. How did you finally manage to boot ?

Did you adjust sectors according Ubuntu partition table ?
The way I installed:
First install the 22.04 image file to /dev/nvme0n1 (see viewtopic.php?f=212&t=44477)
Then install gparted and reduce the size of the data partition.

Finally use petitboot to install the 20.04 image in the remaining space.

This way I only reduced partitions to create space for the image. The 20.04 image can automagically use the free space for installation. Unfortunately the 22.04 image can't do that yet.

As mentioned before the M1 does not start with the 22.04 image unless the ethernet is connected.
First it does not preceed beyond the first call of cloud-init. Than it stops at the DNS application. with ethernet (and a DHCP router) it starts.
After the start you can remove cloud-init and you can configure netplan so the M1 starts without ethernet connection.
My 20.04 image uses the Wifi Modules 5B. The 22.04 image does not yet work with the wifi dongle.

specs
Posts: 121
Joined: Sun Nov 24, 2019 12:14 pm
languages_spoken: english
ODROIDs: Odroid N2/N2+/C4/M1
Has thanked: 30 times
Been thanked: 15 times
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by specs »

tobetter wrote:
Fri May 13, 2022 10:24 pm
New kernel package is uploaded with CPUFREQ fixes.
Nice, but unfortunately I could not update the image and reboot.

After the update the 22.04 image fails with "rk_gmac-dwmac fe2a0000.ethernet: no regulator found".
I need a backup image I can easily recover.

User avatar
spikerguy
Posts: 58
Joined: Thu Apr 30, 2020 12:35 am
languages_spoken: english
ODROIDs: HC4
Has thanked: 20 times
Been thanked: 20 times
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by spikerguy »

Hey Tobetter,

HDMI Audio does work on RK356x already.

I will plan to look into M1 DTS soon and get HDMI audio added.

Thanks.
Manjaro ARM Team

User avatar
tobetter
Posts: 9777
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 624 times
Been thanked: 1641 times
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by tobetter »

HDMI audio output works with new kernel update with v5.18-rc7 and glmark2-es2-wayland score reaches about 557.

Code: Select all

$ dpkg -l | grep linux-image
ii  linux-image-5.18.0-odroid-arm64            5.18.0-202205162058~jammy               arm64        Linux 5.18 for 64-bit ARMv8 machines
Attachments
Screenshot from 2022-05-17 13-24-47.png
Screenshot from 2022-05-17 13-24-47.png (1019.08 KiB) Viewed 258 times
These users thanked the author tobetter for the post (total 3):
odroid (Tue May 17, 2022 2:39 pm) • brad (Tue May 17, 2022 5:01 pm) • spikerguy (Thu May 19, 2022 7:09 am)

User avatar
tobetter
Posts: 9777
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 624 times
Been thanked: 1641 times
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by tobetter »

Please note that Ubuntu 22.04 (Jammy Jellyfish) and Debian 11 (Bullseye) can be installed through Netboot Installer in the Petitboot.
viewtopic.php?p=349719#p349719
These users thanked the author tobetter for the post (total 2):
drolid (Wed May 18, 2022 2:13 am) • spikerguy (Thu May 19, 2022 7:09 am)

Neo2SHYAlien
Posts: 5
Joined: Wed May 11, 2022 3:23 am
languages_spoken: english
ODROIDs: M1
Has thanked: 2 times
Been thanked: 0
Contact:

Re: Mainline kernel for ODROID-M1 (Feat. Ubuntu 22.04)

Post by Neo2SHYAlien »

tobetter wrote:
Wed May 18, 2022 1:52 am
Please note that Ubuntu 22.04 (Jammy Jellyfish) and Debian 11 (Bullseye) can be installed through Netboot Installer in the Petitboot.
viewtopic.php?p=349719#p349719
Great news! Later I will test Debian 11 on my spare SD card

Post Reply

Return to “Projects”

Who is online

Users browsing this forum: No registered users and 1 guest