TOOL-30798 track resolute's GA kernel for the generic flavor - #413
Open
prakashsurya wants to merge 1 commit into
Open
TOOL-30798 track resolute's GA kernel for the generic flavor#413prakashsurya wants to merge 1 commit into
prakashsurya wants to merge 1 commit into
Conversation
The generic flavor asked apt for 'linux-image-generic-hwe-26.04' and then looked for an 'Ubuntu-hwe-*' upstream tag. The apt half resolves on resolute, but an 'Ubuntu-hwe-*' tag only exists in the tree of the release receiving a backport, and never for that release's own GA kernel, so the lookup found nothing and died before pushing anything. That is why generic is the one flavor whose upstreams/os-upgrade was never refreshed. Every flavor now tracks the GA kernel of the suite being built. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
linux-kernel-genericis the one kernel flavor whoseupstreams/os-upgradehas never been refreshed for resolute. It still sits onUbuntu-6.8.0-59.61from 2025-04-11, i.e. noble's GA kernel from the 24.04 cycle, whileupdate-packagerefreshed the other four this week:kernel_update_upstream()treatsgenericas an HWE flavor (tag_prefix_flavour="Ubuntu-hwe"), paired withget_kernel_version_for_platform_from_apt()asking apt forlinux-image-generic-hwe-26.04. The apt half resolves, so the version and ABI it computes are correct; #411 confirmed7.0.0-14.14inresoluteand7.0.0-29.29inresolute-updates. The tag name built from them is not: it searches the resolute tree forUbuntu-hwe-7.0-7.0.0-29, falls back toUbuntu-hwe-7.0.0-29, matches neither, and dies before reaching the point where anything would be pushed. That is why the branch is untouched rather than half-advanced the waymakedumpfileandnfs-utilswere.The resolute tree carries no
Ubuntu-hwetag at all, and that is expected rather than a Canonical policy change. AnUbuntu-hwe-X.Ytag only exists in the tree of the release receiving a backport, and never for that release's own GA kernel:noble's own 6.8 appears one release down, in jammy, as
Ubuntu-hwe-6.8-6.8.0-100.100_22.04.1. resolute has nothing newer than 7.0 to backport into it yet; per Canonical, new installs only default to the HWE kernel from 26.04.2.This is the second cycle it has bitten. The 24.04 cutover collapsed the same case to an unconditional
Ubuntuprefix (7e2bf0c, DLPX-94086, 2025-05-12), which is why generic'supstreams/os-upgradesits on a GA tag rather than an HWE one, and DLPX-95001 / #364 restoredUbuntu-hwethree months later (98e143d, 2025-08-04) once noble's HWE track had rolled to 6.11.Solution
The solution taken in this PR is to track the GA kernel of the suite being built for
generic, the same way the other four flavors track theirs:tag_prefix_flavour="Ubuntu"inkernel_update_upstream(). The lookup lands via the existing fallback prefix, since Canonical tags a release's own kernel asUbuntu-<version>-<abi>.<upload>with no series segment.linux-image-genericrather thanlinux-image-generic-hwe-26.04inget_kernel_version_for_platform_from_apt(), which removes the lastgenericspecial case there.This is deliberately the 24.04 shape rather than a general fix. Once resolute's HWE track starts rolling at 26.04.2,
linux-image-generic-hwe-26.04moves off the GA kernel and its backport does get taggedUbuntu-hwe-*in the resolute tree, at which point this wants to go back the way DLPX-95001 took it. Arguably the better solution is to derive the prefix from the resolved version rather than hardcoding it (useUbuntuwhen apt hands back the target suite's own GA kernel,Ubuntu-hweotherwise), so that a third cycle does not repeat this. That is a larger change than the branch needs today, so I've opted for the narrow one for now; the follow-up that restores HWE after 26.04.2 can pick up the adaptive version.The apt lookup has one other caller,
fetch_kernel_from_apt_for_platform(), reached only by thearchivekernel package source.DEFAULT_LINUX_KERNEL_PACKAGE_SOURCEisdelphix, so that path is off by default, and on resolute both metapackages depend on the same kernel today, so what it would download is unchanged.os-upgradeonly.developcorrectly uses the HWE kernel for generic, since noble's HWE track is live.Testing Done
make check(shellcheck + shfmt) passes.Replicated the prefix construction from
kernel_update_upstream()and resolved it against the real resolute tree (246 tags), for both ABIs apt can hand back (7.0.0-14fromresolute,7.0.0-29fromresolute-updates):No
update-packagerun yet.linux-pkg/os-upgrade/update-package/linux-kernel-genericis where this gets exercised for real, and the merge stage after it is expected to need hand conflict resolution the waymakedumpfileandnfs-utilsdid.🤖 Generated with Claude Code