Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump linux-odroid-xu3 to current 6.6.y branch #2027

Merged
merged 1 commit into from
Jul 5, 2024

Conversation

polyzen
Copy link
Contributor

@polyzen polyzen commented Mar 27, 2024

No description provided.

@polyzen polyzen force-pushed the bump-linux-odroid-xu3 branch 2 times, most recently from ecd0d69 to 49fc7bc Compare March 27, 2024 01:51
@polyzen
Copy link
Contributor Author

polyzen commented May 31, 2024

@graysky2, any chance this could get a review?

@graysky2
Copy link
Member

graysky2 commented Jun 1, 2024

For one, your PR violates the rules for PR. Why are you touching multiple packages? For two, I don't know why upstream hasn't modified their fork of the kernel. If it like's their support for the C2, there is not an upgrade path. Further, I don't have this hardware for testing and if you do, you haven't indicated any functional status of the kernel package on the hardware.

@polyzen
Copy link
Contributor Author

polyzen commented Jul 4, 2024

For one, your PR violates the rules for PR.

TIL. Might be good to setup https://docs.github.com/en/communities/setting-up-your-project-for-healthy-contributions/setting-guidelines-for-repository-contributors

Why are you touching multiple packages?

Figured linux-armv7 and linux-odroid-xu3 are similar enough that I could help shake the cobwebs off that as well.

Rebasing in preparation of building 6.6.36, and I see you've bumped linux-armv7. Great! Shame you didn't build off the consistency fixes that were in this MR. Can drop the minor consistency fixes for linux-aarch64 as well.

For two, I don't know why upstream hasn't modified their fork of the kernel. If it like's their support for the C2, there is not an upgrade path.

I don't follow.

Further, I don't have this hardware for testing and if you do, you haven't indicated any functional status of the kernel package on the hardware.

Ah yes, of course I've been using this for some time now 😄. Output over HDMI seems to work fine still. Anything in particular I should test?

@polyzen
Copy link
Contributor Author

polyzen commented Jul 4, 2024

@graysky2 ^

@polyzen
Copy link
Contributor Author

polyzen commented Jul 4, 2024

Worth noting that prior to a recent change steming from mkinitcpio, one could get on with the currently packaged linux-odroid-xu3 4.14.180 if you had pinned systemd (and NFS and perhaps others) to older versions. Now you would need to add quite a few more packages to IgnorePkg.

@graysky2
Copy link
Member

graysky2 commented Jul 4, 2024

Please scope the PR to just one PKGBUILD, as your title indicates, core/linux-odriod-xu3.

For two, I don't know why upstream hasn't modified their fork of the kernel. If it like's their support for the C2, there is not an upgrade path.

I don't follow.

I mean that upstream's (hardkernel) fork of the linux kernel has not been updated since 4.14.180. They pulled this shit with the ODROID-C2 as well. I want to make sure whatever changes are needed to modernize the kernel are vetted/tested by someone who owns the hardware.

Which branch are thinking is tracking 6.6.y that is specific to this hardware? Just browsing, I see: https://github.com/hardkernel/linux/tree/odroid-6.6.y but I haven't dug into it looking for specific changes for the XU3. Have all been mainlined? Is there a reason to carry a separate kernel for this hardware any more?

@polyzen
Copy link
Contributor Author

polyzen commented Jul 4, 2024

Please scope the PR to just one PKGBUILD, as your title indicates, core/linux-odriod-xu3.

Will do, after I try 6.6.36 shortly. Finally setup distcc (thanks for your AUR package btw). I was building under QEMU which takes like a day 😅.

For two, I don't know why upstream hasn't modified their fork of the kernel. If it like's their support for the C2, there is not an upgrade path.

I don't follow.

I mean that upstream's (hardkernel) fork of the linux kernel has not been updated since 4.14.180. They pulled this shit with the ODROID-C2 as well. I want to make sure whatever changes are needed to modernize the kernel are vetted/tested by someone who owns the hardware.

Which branch are thinking is tracking 6.6.y that is specific to this hardware? Just browsing, I see: https://github.com/hardkernel/linux/tree/odroid-6.6.y but I haven't dug into it looking for specific changes for the XU3. Have all been mainlined? Is there a reason to carry a separate kernel for this hardware any more?

You can see some of the changes specific to the hardware here (fairly certain there are more, but it only gives you the page):
https://github.com/hardkernel/linux/commits/odroid-6.6.y?author=mdrjr

The only thing I specifically know is needed is a change to the thermal throttling code, as the sensors on the XU3 tend to be faulty.

Learned of this branch after noticing this comment:
hardkernel/linux#435 (comment)

@graysky2
Copy link
Member

graysky2 commented Jul 4, 2024

Good that they are keeping their fork active.

Yes, distcc is a good option but a better one particularly for the kernel as it is self-contained is cross compiling on x86_64 assuming you have a powerful box running Arch. I just updated the AUR packages for the cross compiler. If you'd rather not build them, I can provide you with the versions I built. Once installed, building is as simple as:

% CARCH=armv7h ARCH=arm CROSS_COMPILE=armv7l-unknown-linux-gnueabihf- nice -19 makepkg -sCAfd

@polyzen
Copy link
Contributor Author

polyzen commented Jul 4, 2024 via email

@polyzen
Copy link
Contributor Author

polyzen commented Jul 5, 2024

cpio also seems to be a makedep, as the build fails without it, at least with plain makepkg. Have not built in a clean chroot yet.

This MR only touches the linux-odroid-xu3 package now.

@graysky2
Copy link
Member

graysky2 commented Jul 5, 2024 via email

@polyzen polyzen force-pushed the bump-linux-odroid-xu3 branch 2 times, most recently from 3449a7a to edb79c3 Compare July 5, 2024 07:07
@polyzen
Copy link
Contributor Author

polyzen commented Jul 5, 2024

Please squash into a single commit.

Done

@graysky2
Copy link
Member

graysky2 commented Jul 5, 2024

Thank you, and you can confirm that the latest commit:

  • Runs on your hardware with no dmesg regressions or functionality breakage
  • Triggers the creation of the mkinitcpio image

- Config copied directly from https://github.com/hardkernel/linux/blob/23a9f755640b418d446ba6c4ad9c281f9cf65eeb/arch/arm/configs/odroidxu4_defconfig

  - Update config resulting from build

    Based on options used elsewhere in this repo.

- Remove unneeded 60-linux.hook and 90-linux.hook

  - 60-linux.hook is redundant as 60-depmod.hook provided by kmod handles it
  - 90-linux.hook is redundant and causes mkinitcpio to run twice under certain
   circumstances so instead, simply write a 0-byte file to trigger
   90-mkinitcpio-install.hook from mkinitcpio.

  Reflects change from 0f2bbe5

- Consistency fixes

  Bring linux-odroid-xu3 more in line with the linux-aarch64 package.
@graysky2
Copy link
Member

graysky2 commented Jul 5, 2024

I think you made a misake ... your recent commit is hitting another package

@polyzen
Copy link
Contributor Author

polyzen commented Jul 5, 2024

Thank you, and you can confirm that the latest commit:

* Runs on your hardware with no dmesg regressions or functionality breakage

What stands out so far:

New kernel:
kernel: samsung-pinctrl 13400000.pinctrl: Failed to create device link (0x180) with soc

kernel: mali 11800000.gpu: Couldn't find power_model DT node matching 'arm,mali-simple-power-model'
kernel: mali 11800000.gpu: Error -22, no DT entry: mali-simple-power-model.static-coefficient = 1*[0]
kernel: mali 11800000.gpu: Error -22, no DT entry: mali-simple-power-model.dynamic-coefficient = 1*[0]
kernel: mali 11800000.gpu: Error -22, no DT entry: mali-simple-power-model.ts = 4*[0]
kernel: mali 11800000.gpu: Error -22, no DT entry: mali-simple-power-model.thermal-zone = ''
kernel: mali 11800000.gpu: Using configured power model mali-simple-power-model, and fallback mali-simple-power-model

Also there are less video devices registered:

New kernel:

kernel: s5p-mfc 11000000.codec: preallocated 8 MiB buffer for the firmware and context buffers
kernel: s5p-mfc 11000000.codec: decoder registered as /dev/video0
kernel: s5p-mfc 11000000.codec: encoder registered as /dev/video1

Old kernel:

kernel: s5p-jpeg 11f50000.jpeg: Linked as a consumer to 11f10000.sysmmu
kernel: iommu: Adding device 11f50000.jpeg to group 3
kernel: s5p-jpeg 11f50000.jpeg: encoder device registered as /dev/video30
kernel: s5p-jpeg 11f50000.jpeg: decoder device registered as /dev/video31
kernel: s5p-jpeg 11f50000.jpeg: Samsung S5P JPEG codec
kernel: s5p-jpeg 11f60000.jpeg: Linked as a consumer to 11f20000.sysmmu
kernel: iommu: Adding device 11f60000.jpeg to group 4
kernel: s5p-jpeg 11f60000.jpeg: encoder device registered as /dev/video32
kernel: s5p-jpeg 11f60000.jpeg: decoder device registered as /dev/video33
kernel: s5p-jpeg 11f60000.jpeg: Samsung S5P JPEG codec
kernel: s5p-mfc 11000000.codec: Linked as a consumer to 11200000.sysmmu
kernel: s5p-mfc 11000000.codec: Linked as a consumer to 11210000.sysmmu
kernel: iommu: Adding device 11000000.codec to group 5
kernel: s5p-mfc 11000000.codec: preallocated 16 MiB buffer for the firmware and context buffers
kernel: (NULL device *): Direct firmware load for s5p-mfc-v8.fw failed with error -2
kernel: s5p_mfc_load_firmware:73: Firmware is not present in the /lib/firmware directory nor compiled in kernel
kernel: s5p-mfc 11000000.codec: decoder registered as /dev/video10
kernel: s5p-mfc 11000000.codec: encoder registered as /dev/video11
kernel: exynos-gsc 13e00000.video-scaler: Linked as a consumer to 13e80000.sysmmu
kernel: iommu: Adding device 13e00000.video-scaler to group 6
kernel: exynos-gsc 13e10000.video-scaler: Linked as a consumer to 13e90000.sysmmu
kernel: iommu: Adding device 13e10000.video-scaler to group 7
* Triggers the creation of the mkinitcpio image
:: Running post-transaction hooks...
(1/3) Arming ConditionNeedsUpdate...
(2/3) Updating module dependencies...
(3/3) Updating linux initcpios...
==> Building image from preset: /etc/mkinitcpio.d/linux-odroid-xu3.preset: 'default'
==> Using configuration file: '/etc/mkinitcpio.conf'
  -> -k 6.6.36-1-odroid-xu3-ARCH -c /etc/mkinitcpio.conf -g /boot/initramfs-linux.img
==> Starting build: '6.6.36-1-odroid-xu3-ARCH'
  -> Running build hook: [base]
  -> Running build hook: [udev]
  -> Running build hook: [autodetect]
  -> Running build hook: [modconf]
  -> Running build hook: [keyboard]
  -> Running build hook: [block]
  -> Running build hook: [filesystems]
  -> Running build hook: [fsck]
==> Generating module dependencies
==> Creating gzip-compressed initcpio image: '/boot/initramfs-linux.img'
  -> Early uncompressed CPIO image generation successful
==> Initcpio image generation successful

I think you made a misake ... your recent commit is hitting another package

The actual commit is just touching the one package. The compare button is just showing the gnutls changes after I rebased on master again.

@polyzen
Copy link
Contributor Author

polyzen commented Jul 5, 2024

cc @mdrjr in case you have any interest/input :D

@graysky2
Copy link
Member

graysky2 commented Jul 5, 2024

Not sure, but if this is functional now with a few minor flaws which could be corrected in future releases, I think putting it on a support LTS kernel from a deprecated is more important.

Good job with this.

@graysky2 graysky2 merged commit cec6c20 into archlinuxarm:master Jul 5, 2024
@polyzen polyzen deleted the bump-linux-odroid-xu3 branch July 5, 2024 18:57
@bwcknr
Copy link

bwcknr commented Jul 7, 2024

@graysky2 @polyzen With this package my HC1 refuses to start up, please see attached
exception.txt

@graysky2
Copy link
Member

graysky2 commented Jul 7, 2024

@polyzen - any thoughts? missing some HC1 specific commits?

@polyzen
Copy link
Contributor Author

polyzen commented Jul 9, 2024

No idea. Sorry to bug you @mdrjr, but you'd know best :p

Seems this guy built 6.1.90 for his HC1, but did not mention if it worked. Could try modifying the pkgbuild to build against 6.1.90, and see if that works.. It's a different branch.

Edit: TIL "Any OS for XU4 is fully compatible with the HC1", weird..

@kyak
Copy link

kyak commented Jul 10, 2024

@graysky2 @polyzen With this package my HC1 refuses to start up, please see attached exception.txt

I have the same problem.

Sorry I didn't mention it in ffaille/alarm-linux-odroid-xu3#1. I wanted to have a closer look, but then got swiped away by something else.

@polyzen
Copy link
Contributor Author

polyzen commented Jul 10, 2024

Opened an issue upstream hardkernel/linux#437

@graysky2
Copy link
Member

@kyak - can you install the mainline linux package and see if that boots?

pacman -S linux-armv7

@kyak
Copy link

kyak commented Jul 10, 2024

@kyak - can you install the mainline linux package and see if that boots?

pacman -S linux-armv7

I could, and I will, but not earlier than next week..

@graysky2
Copy link
Member

@wickner-consid - which hardware please? XU3?

@bwcknr
Copy link

bwcknr commented Jul 19, 2024

Updated to linux-odroid-xu3:6.6.40, didn't come up aswell.

Switched to linux-armv7 and it's up and running. Feels a little laggier on the ssh term, but so far all seems to be working over here.

@graysky2 Sorry, been signed in into the wrong account, hardware is hc1. Can you please keep the other account out of this conversation?

@kyak
Copy link

kyak commented Jul 27, 2024

It's a pity this got merged so quick even when users report that this kernel refuses to boot.

@kyak
Copy link

kyak commented Jul 27, 2024

@kyak - can you install the mainline linux package and see if that boots?

pacman -S linux-armv7

I've installed linux-armv7 and it boots. Well, I mean that it doesn't crash right away like linux-odroid-xu3.

It drops me to emergency mode because it can't find /dev/mmcblk0p1, but it's not that important. It boots.

P.S. It detects sd card as /dev/mmcblk2 instead of /dev/mmcblk0. After fixing that, it really boots fine.

@polyzen
Copy link
Contributor Author

polyzen commented Jul 27, 2024

It's a pity this got merged so quick even when users report that this kernel refuses to boot.

This PR was open for months before it was merged. The reports came after.

Please help with hardkernel/linux#437 as opposed to being snarky here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants