Skip to content

[rocky9_8] History Rebuild through kernel-5.14.0-687.13.1.el9_8#1310

Open
PlaidCat wants to merge 18 commits into
rocky9_8from
rocky9_8_rebuild
Open

[rocky9_8] History Rebuild through kernel-5.14.0-687.13.1.el9_8#1310
PlaidCat wants to merge 18 commits into
rocky9_8from
rocky9_8_rebuild

Conversation

@PlaidCat

@PlaidCat PlaidCat commented Jun 10, 2026

Copy link
Copy Markdown
Collaborator

This is an automated kernel history rebuild using cron and internal tooling. It follows the same process used for previous history rebuilds:

  • Download all unprocessed src.rpm packages
  • For each src.rpm:
    • Identify all commits in the changelog up to the last known tag (5.14.0-687)
    • Replay commits in chronological order (oldest to newest in the changelog) using git cherry-pick
    • Replace the code in the branch with the output of rpmbuild -bp for the corresponding src.rpm
    • Tag the rebuild branch

JIRA Tickets

Rebuild Splat Inspection

kernel-5.14.0-687.13.1.el9_8

$ cat ciq/ciq_backports/kernel-5.14.0-687.13.1.el9_8/rebuild.details.txt
Rebuild_History BUILDABLE
Rebuilding Kernel from rpm changelog with Fuzz Limit: 87.50%
Number of commits in upstream range v5.14~1..kernel-mainline: 382157
Number of commits in rpm: 21
Number of commits matched with upstream: 17 (80.95%)
Number of commits in upstream but not in rpm: 382140
Number of commits NOT found in upstream: 4 (19.05%)

Rebuilding Kernel on Branch rocky9_8_rebuild_kernel-5.14.0-687.13.1.el9_8 for kernel-5.14.0-687.13.1.el9_8
Clean Cherry Picks: 15 (88.24%)
Empty Cherry Picks: 2 (11.76%)
_______________________________

__EMPTY COMMITS__________________________
17d75422604f0b92869aa17cb44f60958212f033 mm: document __GFP_NOFAIL must be blockable
96feb73def02d175850daa0e7c2c90c876681b5c crypto: authenc - Correctly pass EINPROGRESS back up to the caller

__CHANGES NOT IN UPSTREAM________________
Replace sbat with Rocky Linux sbat
Change bug tracker URL
Ensure appended release in sbat is removed'
mm/page_alloc: add vm.thp_thisnode_reclaim sysctl to allow THP reclaim on local node

BUILD

$ grep -E -B 5 -A 5 "\[TIMER\]|^Starting Build" $(ls -t kbuild* | head -n1)
/mnt/code/kernel-src-tree-build
Running make mrproper...
  CLEAN   scripts/basic
  CLEAN   scripts/kconfig
  CLEAN   include/config include/generated
[TIMER]{MRPROPER}: 6s
x86_64 architecture detected, copying config
'configs/kernel-x86_64-rhel.config' -> '.config'
Setting Local Version for build
CONFIG_LOCALVERSION="-rocky9_8_rebuild-f89ef56bfe6d"
Making olddefconfig
--
  HOSTCC  scripts/kconfig/util.o
  HOSTLD  scripts/kconfig/conf
#
# configuration written to .config
#
Starting Build
  SYSHDR  arch/x86/include/generated/uapi/asm/unistd_32.h
  SYSHDR  arch/x86/include/generated/uapi/asm/unistd_64.h
  SYSHDR  arch/x86/include/generated/uapi/asm/unistd_x32.h
  SYSTBL  arch/x86/include/generated/asm/syscalls_32.h
  SYSHDR  arch/x86/include/generated/asm/unistd_32_ia32.h
--
  BTF [M] sound/usb/usx2y/snd-usb-us144mkii.ko
  BTF [M] sound/usb/usx2y/snd-usb-usx2y.ko
  BTF [M] sound/virtio/virtio_snd.ko
  BTF [M] sound/x86/snd-hdmi-lpe-audio.ko
  BTF [M] sound/xen/snd_xen_front.ko
[TIMER]{BUILD}: 1669s
Making Modules
  INSTALL /lib/modules/5.14.0-rocky9_8_rebuild-f89ef56bfe6d/kernel/arch/x86/crypto/blake2s-x86_64.ko
  INSTALL /lib/modules/5.14.0-rocky9_8_rebuild-f89ef56bfe6d/kernel/arch/x86/crypto/blowfish-x86_64.ko
  INSTALL /lib/modules/5.14.0-rocky9_8_rebuild-f89ef56bfe6d/kernel/arch/x86/crypto/camellia-aesni-avx-x86_64.ko
  INSTALL /lib/modules/5.14.0-rocky9_8_rebuild-f89ef56bfe6d/kernel/arch/x86/crypto/camellia-aesni-avx2.ko
--
  SIGN    /lib/modules/5.14.0-rocky9_8_rebuild-f89ef56bfe6d/kernel/sound/usb/snd-usb-audio.ko
  SIGN    /lib/modules/5.14.0-rocky9_8_rebuild-f89ef56bfe6d/kernel/sound/xen/snd_xen_front.ko
  SIGN    /lib/modules/5.14.0-rocky9_8_rebuild-f89ef56bfe6d/kernel/sound/x86/snd-hdmi-lpe-audio.ko
  SIGN    /lib/modules/5.14.0-rocky9_8_rebuild-f89ef56bfe6d/kernel/sound/virtio/virtio_snd.ko
  DEPMOD  /lib/modules/5.14.0-rocky9_8_rebuild-f89ef56bfe6d
[TIMER]{MODULES}: 10s
Making Install
sh ./arch/x86/boot/install.sh 5.14.0-rocky9_8_rebuild-f89ef56bfe6d \
	arch/x86/boot/bzImage System.map "/boot"
[TIMER]{INSTALL}: 28s
Checking kABI
kABI check passed
Setting Default Kernel to /boot/vmlinuz-5.14.0-rocky9_8_rebuild-f89ef56bfe6d and Index to 0
Hopefully Grub2.0 took everything ... rebooting after time metrices
[TIMER]{MRPROPER}: 6s
[TIMER]{BUILD}: 1669s
[TIMER]{MODULES}: 10s
[TIMER]{INSTALL}: 28s
[TIMER]{TOTAL} 1718s
Rebooting in 10 seconds

KSelfTests

$ get_kselftest_diff.sh
kselftest.5.14.0-rocky9_8_rebuild-6206e514e8a1.log
311
kselftest.5.14.0-rocky9_8_rebuild-cc42a7a03317.log
311
kselftest.5.14.0-rocky9_8_rebuild-46083212952c.log
311
kselftest.5.14.0-rocky9_8_rebuild-f89ef56bfe6d.log
311
Before: kselftest.5.14.0-rocky9_8_rebuild-46083212952c.log
After: kselftest.5.14.0-rocky9_8_rebuild-f89ef56bfe6d.log
Diff:
No differences found.

PlaidCat added 18 commits June 10, 2026 00:02
jira KERNEL-1116
Rebuild_History Non-Buildable kernel-5.14.0-687.13.1.el9_8
commit-author Barry Song <v-songbaohua@oppo.com>
commit 17d7542
Empty-Commit: Cherry-Pick Conflicts during history rebuild.
Will be included in final tarball splat. Ref for failed cherry-pick at:
ciq/ciq_backports/kernel-5.14.0-687.13.1.el9_8/17d75422.failed

Non-blocking allocation with __GFP_NOFAIL is not supported and may still
result in NULL pointers (if we don't return NULL, we result in busy-loop
within non-sleepable contexts):

static inline struct page *
__alloc_pages_slowpath(gfp_t gfp_mask, unsigned int order,
						struct alloc_context *ac)
{
	...
	/*
	 * Make sure that __GFP_NOFAIL request doesn't leak out and make sure
	 * we always retry
	 */
	if (gfp_mask & __GFP_NOFAIL) {
		/*
		 * All existing users of the __GFP_NOFAIL are blockable, so warn
		 * of any new users that actually require GFP_NOWAIT
		 */
		if (WARN_ON_ONCE_GFP(!can_direct_reclaim, gfp_mask))
			goto fail;
		...
	}
	...
fail:
	warn_alloc(gfp_mask, ac->nodemask,
			"page allocation failure: order:%u", order);
got_pg:
	return page;
}

Highlight this in the documentation of __GFP_NOFAIL so that non-mm
subsystems can reject any illegal usage of __GFP_NOFAIL with GFP_ATOMIC,
GFP_NOWAIT, etc.

Link: https://lkml.kernel.org/r/20240830202823.21478-3-21cnbao@gmail.com
	Signed-off-by: Barry Song <v-songbaohua@oppo.com>
	Acked-by: Michal Hocko <mhocko@suse.com>
	Reviewed-by: Christoph Hellwig <hch@lst.de>
	Acked-by: Vlastimil Babka <vbabka@suse.cz>
	Acked-by: Davidlohr Bueso <dave@stgolabs.net>
	Acked-by: David Hildenbrand <david@redhat.com>
	Cc: Christoph Lameter <cl@linux.com>
	Cc: David Rientjes <rientjes@google.com>
	Cc: "Eugenio Pérez" <eperezma@redhat.com>
	Cc: Hailong.Liu <hailong.liu@oppo.com>
	Cc: Hyeonggon Yoo <42.hyeyoo@gmail.com>
	Cc: Jason Wang <jasowang@redhat.com>
	Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com>
	Cc: Kees Cook <kees@kernel.org>
	Cc: Linus Torvalds <torvalds@linux-foundation.org>
	Cc: Lorenzo Stoakes <lorenzo.stoakes@oracle.com>
	Cc: Maxime Coquelin <maxime.coquelin@redhat.com>
	Cc: "Michael S. Tsirkin" <mst@redhat.com>
	Cc: Pekka Enberg <penberg@kernel.org>
	Cc: Roman Gushchin <roman.gushchin@linux.dev>
	Cc: Uladzislau Rezki (Sony) <urezki@gmail.com>
	Cc: Xuan Zhuo <xuanzhuo@linux.alibaba.com>
	Cc: Christoph Hellwig <hch@infradead.org>
	Cc: Xie Yongji <xieyongji@bytedance.com>
	Cc: Yafang Shao <laoar.shao@gmail.com>
	Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
(cherry picked from commit 17d7542)
	Signed-off-by: Jonathan Maple <jmaple@ciq.com>

# Conflicts:
#	include/linux/gfp_types.h
…ion and manner

jira KERNEL-1116
Rebuild_History Non-Buildable kernel-5.14.0-687.13.1.el9_8
commit-author Barry Song <v-songbaohua@oppo.com>
commit 903edea

Three points for this change:

1. We should consolidate all warnings in one place. Currently, the
   order > 1 warning is in the hotpath, while others are in less
   likely scenarios. Moving all warnings to the slowpath will reduce
   the overhead for order > 1 and increase the visibility of other
   warnings.

2. We currently have two warnings for order: one for order > 1 in
   the hotpath and another for order > costly_order in the laziest
   path. I suggest standardizing on order > 1 since it's been in
   use for a long time.

3. We don't need to check for __GFP_NOWARN in this case. __GFP_NOWARN
   is meant to suppress allocation failure reports, but here we're
   dealing with bug detection, not allocation failures. So replace
   WARN_ON_ONCE_GFP by WARN_ON_ONCE.

[v-songbaohua@oppo.com: also update the doc for __GFP_NOFAIL with order > 1]
  Link: https://lkml.kernel.org/r/20240903223935.1697-1-21cnbao@gmail.com
Link: https://lkml.kernel.org/r/20240830202823.21478-4-21cnbao@gmail.com
	Signed-off-by: Barry Song <v-songbaohua@oppo.com>
	Suggested-by: Vlastimil Babka <vbabka@suse.cz>
	Reviewed-by: Vlastimil Babka <vbabka@suse.cz>
	Acked-by: David Hildenbrand <david@redhat.com>
	Acked-by: Michal Hocko <mhocko@suse.com>
	Cc: Christoph Hellwig <hch@lst.de>
	Cc: Christoph Lameter <cl@linux.com>
	Cc: Davidlohr Bueso <dave@stgolabs.net>
	Cc: David Rientjes <rientjes@google.com>
	Cc: "Eugenio Pérez" <eperezma@redhat.com>
	Cc: Hailong.Liu <hailong.liu@oppo.com>
	Cc: Hyeonggon Yoo <42.hyeyoo@gmail.com>
	Cc: Jason Wang <jasowang@redhat.com>
	Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com>
	Cc: Kees Cook <kees@kernel.org>
	Cc: Linus Torvalds <torvalds@linux-foundation.org>
	Cc: Lorenzo Stoakes <lorenzo.stoakes@oracle.com>
	Cc: Maxime Coquelin <maxime.coquelin@redhat.com>
	Cc: "Michael S. Tsirkin" <mst@redhat.com>
	Cc: Pekka Enberg <penberg@kernel.org>
	Cc: Roman Gushchin <roman.gushchin@linux.dev>
	Cc: Uladzislau Rezki (Sony) <urezki@gmail.com>
	Cc: Xie Yongji <xieyongji@bytedance.com>
	Cc: Xuan Zhuo <xuanzhuo@linux.alibaba.com>
	Cc: Yafang Shao <laoar.shao@gmail.com>
	Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
(cherry picked from commit 903edea)
	Signed-off-by: Jonathan Maple <jmaple@ciq.com>
jira KERNEL-1116
Rebuild_History Non-Buildable kernel-5.14.0-687.13.1.el9_8
commit-author Tianyang Zhang <zhangtianyang@loongson.cn>
commit e05741f

__alloc_pages_slowpath has no change detection for ac->nodemask in the
part of retry path, while cpuset can modify it in parallel.  For some
processes that set mempolicy as MPOL_BIND, this results ac->nodemask
changes, and then the should_reclaim_retry will judge based on the latest
nodemask and jump to retry, while the get_page_from_freelist only
traverses the zonelist from ac->preferred_zoneref, which selected by a
expired nodemask and may cause infinite retries in some cases

cpu 64:
__alloc_pages_slowpath {
        /* ..... */
retry:
        /* ac->nodemask = 0x1, ac->preferred->zone->nid = 1 */
        if (alloc_flags & ALLOC_KSWAPD)
                wake_all_kswapds(order, gfp_mask, ac);
        /* cpu 1:
        cpuset_write_resmask
            update_nodemask
                update_nodemasks_hier
                    update_tasks_nodemask
                        mpol_rebind_task
                         mpol_rebind_policy
                          mpol_rebind_nodemask
		// mempolicy->nodes has been modified,
		// which ac->nodemask point to

        */
        /* ac->nodemask = 0x3, ac->preferred->zone->nid = 1 */
        if (should_reclaim_retry(gfp_mask, order, ac, alloc_flags,
                                 did_some_progress > 0, &no_progress_loops))
                goto retry;
}

Simultaneously starting multiple cpuset01 from LTP can quickly reproduce
this issue on a multi node server when the maximum memory pressure is
reached and the swap is enabled

Link: https://lkml.kernel.org/r/20250416082405.20988-1-zhangtianyang@loongson.cn
Fixes: c33d6c0 ("mm, page_alloc: avoid looking up the first zone in a zonelist twice")
	Signed-off-by: Tianyang Zhang <zhangtianyang@loongson.cn>
	Reviewed-by: Suren Baghdasaryan <surenb@google.com>
	Reviewed-by: Vlastimil Babka <vbabka@suse.cz>
	Cc: Michal Hocko <mhocko@suse.com>
	Cc: Brendan Jackman <jackmanb@google.com>
	Cc: Johannes Weiner <hannes@cmpxchg.org>
	Cc: Zi Yan <ziy@nvidia.com>
	Cc: <stable@vger.kernel.org>
	Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
(cherry picked from commit e05741f)
	Signed-off-by: Jonathan Maple <jmaple@ciq.com>
jira KERNEL-1116
Rebuild_History Non-Buildable kernel-5.14.0-687.13.1.el9_8
commit-author Vlastimil Babka <vbabka@suse.cz>
commit 9c9828d

Since commit cc638f3 ("mm, thp: tweak reclaim/compaction effort of
local-only and all-node allocations"), THP page fault allocations have
settled on the following scheme (from the commit log):

1. local node only THP allocation with no reclaim, just compaction.
2. for madvised VMA's or when synchronous compaction is enabled always - THP
   allocation from any node with effort determined by global defrag setting
   and VMA madvise
3. fallback to base pages on any node

Recent customer reports however revealed we have a gap in step 1 above.
What we have seen is excessive reclaim due to THP page faults on a NUMA
node that's close to its high watermark, while other nodes have plenty of
free memory.

The problem with step 1 is that it promises no reclaim after the
compaction attempt, however reclaim is only avoided for certain compaction
outcomes (deferred, or skipped due to insufficient free base pages), and
not e.g.  when compaction is actually performed but fails (we did see
compact_fail vmstat counter increasing).

THP page faults can therefore exhibit a zone_reclaim_mode-like behavior,
which is not the intention.

Thus add a check for __GFP_THISNODE that corresponds to this exact
situation and prevents continuing with reclaim/compaction once the initial
compaction attempt isn't successful in allocating the page.

Note that commit cc638f3 has not introduced this over-reclaim
possibility; it appears to exist in some form since commit 2f0799a
("mm, thp: restore node-local hugepage allocations").  Followup commits
b39d0ee ("mm, page_alloc: avoid expensive reclaim when compaction may
not succeed") and cc638f3 have moved in the right direction, but left
the abovementioned gap.

Link: https://lkml.kernel.org/r/20251219-costly-noretry-thisnode-fix-v1-1-e1085a4a0c34@suse.cz
Fixes: 2f0799a ("mm, thp: restore node-local hugepage allocations")
	Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
	Acked-by: Michal Hocko <mhocko@suse.com>
	Acked-by: Johannes Weiner <hannes@cmpxchg.org>
	Acked-by: Pedro Falcato <pfalcato@suse.de>
	Acked-by: Zi Yan <ziy@nvidia.com>
	Cc: Brendan Jackman <jackmanb@google.com>
	Cc: "David Hildenbrand (Red Hat)" <david@kernel.org>
	Cc: David Rientjes <rientjes@google.com>
	Cc: Joshua Hahn <joshua.hahnjy@gmail.com>
	Cc: Liam Howlett <liam.howlett@oracle.com>
	Cc: Lorenzo Stoakes <lorenzo.stoakes@oracle.com>
	Cc: Mike Rapoport <rppt@kernel.org>
	Cc: Suren Baghdasaryan <surenb@google.com>
	Cc: <stable@vger.kernel.org>
	Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
(cherry picked from commit 9c9828d)
	Signed-off-by: Jonathan Maple <jmaple@ciq.com>
jira KERNEL-1116
Rebuild_History Non-Buildable kernel-5.14.0-687.13.1.el9_8
commit-author Vlastimil Babka <vbabka@suse.cz>
commit 6698721

Patch series "tweaks for __alloc_pages_slowpath()", v3.

This patch (of 3):

For allocations that are of costly order and __GFP_NORETRY (and can
perform compaction) we attempt direct compaction first.  If that fails, we
continue with a single round of direct reclaim+compaction (as for other
__GFP_NORETRY allocations, except the compaction is of lower priority),
with two exceptions that fail immediately:

- __GFP_THISNODE is specified, to prevent zone_reclaim_mode-like
  behavior for e.g. THP page faults

- compaction failed because it was deferred (i.e. has been failing
  recently so further attempts are not done for a while) or skipped,
  which means there are insufficient free base pages to defragment to
  begin with

Upon closer inspection, the second condition has a somewhat flawed
reasoning.  If there are not enough base pages and reclaim could create
them, we instead fail.  When there are enough base pages and compaction
has already ran and failed, we proceed and hope that reclaim and the
subsequent compaction attempt will succeed.  But it's unclear why they
should and whether it will be as inexpensive as intended.

It might make therefore more sense to just fail unconditionally after the
initial compaction attempt.  However that would change the semantics of
__GFP_NORETRY to attempt reclaim at least once.

Alternatively we can remove the compaction result checks and proceed with
the single reclaim and (lower priority) compaction attempt, leaving only
the __GFP_THISNODE exception for failing immediately.

Link: https://lkml.kernel.org/r/20260106-thp-thisnode-tweak-v3-0-f5d67c21a193@suse.cz
Link: https://lkml.kernel.org/r/20260106-thp-thisnode-tweak-v3-1-f5d67c21a193@suse.cz
	Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
	Acked-by: Michal Hocko <mhocko@suse.com>
	Cc: Brendan Jackman <jackmanb@google.com>
	Cc: David Hildenbrand (Red Hat) <david@kernel.org>
	Cc: David Rientjes <rientjes@google.com>
	Cc: Johannes Weiner <hannes@cmpxchg.org>
	Cc: Joshua Hahn <joshua.hahnjy@gmail.com>
	Cc: Liam Howlett <liam.howlett@oracle.com>
	Cc: Lorenzo Stoakes <lorenzo.stoakes@oracle.com>
	Cc: Mike Rapoport <rppt@kernel.org>
	Cc: Pedro Falcato <pfalcato@suse.de>
	Cc: Suren Baghdasaryan <surenb@google.com>
	Cc: Zi Yan <ziy@nvidia.com>
	Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
(cherry picked from commit 6698721)
	Signed-off-by: Jonathan Maple <jmaple@ciq.com>
jira KERNEL-1116
Rebuild_History Non-Buildable kernel-5.14.0-687.13.1.el9_8
commit-author Vlastimil Babka <vbabka@suse.cz>
commit 53a9b46

The initial direct compaction done in some cases in
__alloc_pages_slowpath() stands out from the main retry loop of reclaim +
compaction.

We can simplify this by instead skipping the initial reclaim attempt via a
new local variable compact_first, and handle the compact_prority as
necessary to match the original behavior.  No functional change intended.

Link: https://lkml.kernel.org/r/20260106-thp-thisnode-tweak-v3-2-f5d67c21a193@suse.cz
	Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
	Suggested-by: Johannes Weiner <hannes@cmpxchg.org>
	Reviewed-by: Joshua Hahn <joshua.hahnjy@gmail.com>
	Acked-by: Michal Hocko <mhocko@suse.com>
	Cc: Brendan Jackman <jackmanb@google.com>
	Cc: David Hildenbrand (Red Hat) <david@kernel.org>
	Cc: David Rientjes <rientjes@google.com>
	Cc: Liam Howlett <liam.howlett@oracle.com>
	Cc: Lorenzo Stoakes <lorenzo.stoakes@oracle.com>
	Cc: Mike Rapoport <rppt@kernel.org>
	Cc: Pedro Falcato <pfalcato@suse.de>
	Cc: Suren Baghdasaryan <surenb@google.com>
	Cc: Zi Yan <ziy@nvidia.com>
	Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
(cherry picked from commit 53a9b46)
	Signed-off-by: Jonathan Maple <jmaple@ciq.com>
jira KERNEL-1116
Rebuild_History Non-Buildable kernel-5.14.0-687.13.1.el9_8
commit-author Vlastimil Babka <vbabka@suse.cz>
commit 2c4c3e2

The actions done before entering the main retry loop include waking up
kswapds and an allocation attempt with the precise alloc_flags.  Then in
the loop we keep waking up kswapds, and we retry the allocation with flags
potentially further adjusted by being allowed to use reserves (due to e.g.
becoming an OOM killer victim).

We can adjust the retry loop to keep only one instance of waking up
kswapds and allocation attempt.  Introduce the can_retry_reserves variable
for retrying once when we become eligible for reserves.  It is still
useful not to evaluate reserve_flags immediately for the first allocation
attempt, because it's better to first try succeed in a non-preferred zone
above the min watermark before allocating immediately from the preferred
zone below min watermark.

Additionally move the cpuset update checks introduced by e05741f
("mm/page_alloc.c: avoid infinite retries caused by cpuset race") further
down the retry loop.  It's enough to do the checks only before reaching
any potentially infinite 'goto retry;' loop.

There should be no meaningful functional changes.  The change of exact
moments the retry for reserves and cpuset updates are checked should not
result in different outomes modulo races with concurrent allocator
activity.

Link: https://lkml.kernel.org/r/20260106-thp-thisnode-tweak-v3-3-f5d67c21a193@suse.cz
	Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
	Acked-by: Michal Hocko <mhocko@suse.com>
	Cc: Johannes Weiner <hannes@cmpxchg.org>
	Cc: Joshua Hahn <joshua.hahnjy@gmail.com>
	Cc: Brendan Jackman <jackmanb@google.com>
	Cc: David Hildenbrand (Red Hat) <david@kernel.org>
	Cc: David Rientjes <rientjes@google.com>
	Cc: Liam Howlett <liam.howlett@oracle.com>
	Cc: Lorenzo Stoakes <lorenzo.stoakes@oracle.com>
	Cc: Mike Rapoport <rppt@kernel.org>
	Cc: Pedro Falcato <pfalcato@suse.de>
	Cc: Suren Baghdasaryan <surenb@google.com>
	Cc: Zi Yan <ziy@nvidia.com>
	Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
(cherry picked from commit 2c4c3e2)
	Signed-off-by: Jonathan Maple <jmaple@ciq.com>
jira KERNEL-1116
cve CVE-2026-31613
Rebuild_History Non-Buildable kernel-5.14.0-687.13.1.el9_8
commit-author Greg Kroah-Hartman <gregkh@linuxfoundation.org>
commit 3df690b

When a CREATE returns STATUS_STOPPED_ON_SYMLINK, smb2_check_message()
returns success without any length validation, leaving the symlink
parsers as the only defense against an untrusted server.

symlink_data() walks SMB 3.1.1 error contexts with the loop test "p <
end", but reads p->ErrorId at offset 4 and p->ErrorDataLength at offset
0.  When the server-controlled ErrorDataLength advances p to within 1-7
bytes of end, the next iteration will read past it.  When the matching
context is found, sym->SymLinkErrorTag is read at offset 4 from
p->ErrorContextData with no check that the symlink header itself fits.

smb2_parse_symlink_response() then bounds-checks the substitute name
using SMB2_SYMLINK_STRUCT_SIZE as the offset of PathBuffer from
iov_base.  That value is computed as sizeof(smb2_err_rsp) +
sizeof(smb2_symlink_err_rsp), which is correct only when
ErrorContextCount == 0.

With at least one error context the symlink data sits 8 bytes deeper,
and each skipped non-matching context shifts it further by 8 +
ALIGN(ErrorDataLength, 8).  The check is too short, allowing the
substitute name read to run past iov_len.  The out-of-bound heap bytes
are UTF-16-decoded into the symlink target and returned to userspace via
readlink(2).

Fix this all up by making the loops test require the full context header
to fit, rejecting sym if its header runs past end, and bound the
substitute name against the actual position of sym->PathBuffer rather
than a fixed offset.

Because sub_offs and sub_len are 16bits, the pointer math will not
overflow here with the new greater-than.

	Cc: Ronnie Sahlberg <ronniesahlberg@gmail.com>
	Cc: Shyam Prasad N <sprasad@microsoft.com>
	Cc: Tom Talpey <tom@talpey.com>
	Cc: Bharath SM <bharathsm@microsoft.com>
	Cc: linux-cifs@vger.kernel.org
	Cc: samba-technical@lists.samba.org
	Cc: stable <stable@kernel.org>
	Reviewed-by: Paulo Alcantara (Red Hat) <pc@manguebit.org>
Assisted-by: gregkh_clanker_t1000
	Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
	Signed-off-by: Steve French <stfrench@microsoft.com>
(cherry picked from commit 3df690b)
	Signed-off-by: Jonathan Maple <jmaple@ciq.com>
jira KERNEL-1116
Rebuild_History Non-Buildable kernel-5.14.0-687.13.1.el9_8
commit-author Herbert Xu <herbert@gondor.apana.org.au>
commit 66eae85

The function crypto_authenc_decrypt_tail discards its flags
argument and always relies on the flags from the original request
when starting its sub-request.

This is clearly wrong as it may cause the SLEEPABLE flag to be
set when it shouldn't.

Fixes: 92d95ba ("crypto: authenc - Convert to new AEAD interface")
	Reported-by: Corentin Labbe <clabbe.montjoie@gmail.com>
	Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
	Tested-by: Corentin Labbe <clabbe.montjoie@gmail.com>
	Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
(cherry picked from commit 66eae85)
	Signed-off-by: Jonathan Maple <jmaple@ciq.com>
jira KERNEL-1116
Rebuild_History Non-Buildable kernel-5.14.0-687.13.1.el9_8
commit-author Herbert Xu <herbert@gondor.apana.org.au>
commit 96feb73
Empty-Commit: Cherry-Pick Conflicts during history rebuild.
Will be included in final tarball splat. Ref for failed cherry-pick at:
ciq/ciq_backports/kernel-5.14.0-687.13.1.el9_8/96feb73d.failed

When authenc is invoked with MAY_BACKLOG, it needs to pass EINPROGRESS
notifications back up to the caller when the underlying algorithm
returns EBUSY synchronously.

However, if the EBUSY comes from the second part of an authenc call,
i.e., it is asynchronous, both the EBUSY and the subsequent EINPROGRESS
notification must not be passed to the caller.

Implement this by passing a mask to the function that starts the
second half of authenc and using it to determine whether EBUSY
and EINPROGRESS should be passed to the caller.

This was a deficiency in the original implementation of authenc
because it was not expected to be used with MAY_BACKLOG.

	Reported-by: Ingo Franzki <ifranzki@linux.ibm.com>
	Reported-by: Mikulas Patocka <mpatocka@redhat.com>
Fixes: 180ce7e ("crypto: authenc - Add EINPROGRESS check")
	Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
(cherry picked from commit 96feb73)
	Signed-off-by: Jonathan Maple <jmaple@ciq.com>

# Conflicts:
#	crypto/authenc.c
jira KERNEL-1116
cve CVE-2026-31786
Rebuild_History Non-Buildable kernel-5.14.0-687.13.1.el9_8
commit-author Juergen Gross <jgross@suse.com>
commit 27fdbab

The build id returned by HYPERVISOR_xen_version(XENVER_build_id) is
neither NUL terminated nor a string.

The first causes a buffer overflow as sprintf in buildid_show will
read and copy till it finds a NUL.

00000000  f4 91 51 f4 dd 38 9e 9d  65 47 52 eb 10 71 db 50  |..Q..8..eGR..q.P|
00000010  b9 a8 01 42 6f 2e 32                              |...Bo.2|
0000001

So use a memcpy instead of sprintf to have the correct value:

00000000  f4 91 51 f4 dd 00 9e 9d  65 47 52 eb 10 71 db 50  |..Q.....eGR..q.P|
00000010  b9 a8 01 42                                       |...B|
00000014

(the above have a hack to embed a zero inside and check it's
returned correctly).

This is XSA-485 / CVE-2026-31786

Fixes: 84b7625 ("xen: add sysfs node for hypervisor build id")
	Signed-off-by: Frediano Ziglio <frediano.ziglio@citrix.com>
	Reviewed-by: Juergen Gross <jgross@suse.com>
	Signed-off-by: Juergen Gross <jgross@suse.com>
(cherry picked from commit 27fdbab)
	Signed-off-by: Jonathan Maple <jmaple@ciq.com>
jira KERNEL-1116
Rebuild_History Non-Buildable kernel-5.14.0-687.13.1.el9_8
commit-author Ewan D. Milne <emilne@redhat.com>
commit ea3442e

Now target is removed from nvme_fc_ctrl_free() which is the ctrl->ref
release handler. And even admin queue is unquiesced there, this way
is definitely wrong because the ctr->ref is grabbed when submitting
command.

And Marco observed that nvme_fc_ctrl_free() can be called from request
completion code path, and trigger kernel warning since request completes
from softirq context.

Fix the issue by moveing target removal into nvme_fc_delete_ctrl(),
which is also aligned with nvme-tcp and nvme-rdma.

Patch originally proposed by Ming Lei, then modified to move the tagset
removal down to after nvme_fc_delete_association() after further testing.

	Cc: Marco Patalano <mpatalan@redhat.com>
	Cc: Ewan Milne <emilne@redhat.com>
	Cc: James Smart <james.smart@broadcom.com>
	Cc: Sagi Grimberg <sagi@grimberg.me>
	Signed-off-by: Ming Lei <ming.lei@redhat.com>
	Cc: stable@vger.kernel.org
	Tested-by: Marco Patalano <mpatalan@redhat.com>
	Reviewed-by: Justin Tee <justin.tee@broadcom.com>
	Signed-off-by: Ewan D. Milne <emilne@redhat.com>
	Signed-off-by: Keith Busch <kbusch@kernel.org>
(cherry picked from commit ea3442e)
	Signed-off-by: Jonathan Maple <jmaple@ciq.com>
jira KERNEL-1116
Rebuild_History Non-Buildable kernel-5.14.0-687.13.1.el9_8
commit-author Ewan D. Milne <emilne@redhat.com>
commit 0a2c549

nvme_fc_delete_assocation() waits for pending I/O to complete before
returning, and an error can cause ->ioerr_work to be queued after
cancel_work_sync() had been called.  Move the call to cancel_work_sync() to
be after nvme_fc_delete_association() to ensure ->ioerr_work is not running
when the nvme_fc_ctrl object is freed.  Otherwise the following can occur:

[ 1135.911754] list_del corruption, ff2d24c8093f31f8->next is NULL
[ 1135.917705] ------------[ cut here ]------------
[ 1135.922336] kernel BUG at lib/list_debug.c:52!
[ 1135.926784] Oops: invalid opcode: 0000 [#1] SMP NOPTI
[ 1135.931851] CPU: 48 UID: 0 PID: 726 Comm: kworker/u449:23 Kdump: loaded Not tainted 6.12.0 #1 PREEMPT(voluntary)
[ 1135.943490] Hardware name: Dell Inc. PowerEdge R660/0HGTK9, BIOS 2.5.4 01/16/2025
[ 1135.950969] Workqueue:  0x0 (nvme-wq)
[ 1135.954673] RIP: 0010:__list_del_entry_valid_or_report.cold+0xf/0x6f
[ 1135.961041] Code: c7 c7 98 68 72 94 e8 26 45 fe ff 0f 0b 48 c7 c7 70 68 72 94 e8 18 45 fe ff 0f 0b 48 89 fe 48 c7 c7 80 69 72 94 e8 07 45 fe ff <0f> 0b 48 89 d1 48 c7 c7 a0 6a 72 94 48 89 c2 e8 f3 44 fe ff 0f 0b
[ 1135.979788] RSP: 0018:ff579b19482d3e50 EFLAGS: 00010046
[ 1135.985015] RAX: 0000000000000033 RBX: ff2d24c8093f31f0 RCX: 0000000000000000
[ 1135.992148] RDX: 0000000000000000 RSI: ff2d24d6bfa1d0c0 RDI: ff2d24d6bfa1d0c0
[ 1135.999278] RBP: ff2d24c8093f31f8 R08: 0000000000000000 R09: ffffffff951e2b08
[ 1136.006413] R10: ffffffff95122ac8 R11: 0000000000000003 R12: ff2d24c78697c100
[ 1136.013546] R13: fffffffffffffff8 R14: 0000000000000000 R15: ff2d24c78697c0c0
[ 1136.020677] FS:  0000000000000000(0000) GS:ff2d24d6bfa00000(0000) knlGS:0000000000000000
[ 1136.028765] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[ 1136.034510] CR2: 00007fd207f90b80 CR3: 000000163ea22003 CR4: 0000000000f73ef0
[ 1136.041641] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
[ 1136.048776] DR3: 0000000000000000 DR6: 00000000fffe07f0 DR7: 0000000000000400
[ 1136.055910] PKRU: 55555554
[ 1136.058623] Call Trace:
[ 1136.061074]  <TASK>
[ 1136.063179]  ? show_trace_log_lvl+0x1b0/0x2f0
[ 1136.067540]  ? show_trace_log_lvl+0x1b0/0x2f0
[ 1136.071898]  ? move_linked_works+0x4a/0xa0
[ 1136.075998]  ? __list_del_entry_valid_or_report.cold+0xf/0x6f
[ 1136.081744]  ? __die_body.cold+0x8/0x12
[ 1136.085584]  ? die+0x2e/0x50
[ 1136.088469]  ? do_trap+0xca/0x110
[ 1136.091789]  ? do_error_trap+0x65/0x80
[ 1136.095543]  ? __list_del_entry_valid_or_report.cold+0xf/0x6f
[ 1136.101289]  ? exc_invalid_op+0x50/0x70
[ 1136.105127]  ? __list_del_entry_valid_or_report.cold+0xf/0x6f
[ 1136.110874]  ? asm_exc_invalid_op+0x1a/0x20
[ 1136.115059]  ? __list_del_entry_valid_or_report.cold+0xf/0x6f
[ 1136.120806]  move_linked_works+0x4a/0xa0
[ 1136.124733]  worker_thread+0x216/0x3a0
[ 1136.128485]  ? __pfx_worker_thread+0x10/0x10
[ 1136.132758]  kthread+0xfa/0x240
[ 1136.135904]  ? __pfx_kthread+0x10/0x10
[ 1136.139657]  ret_from_fork+0x31/0x50
[ 1136.143236]  ? __pfx_kthread+0x10/0x10
[ 1136.146988]  ret_from_fork_asm+0x1a/0x30
[ 1136.150915]  </TASK>

Fixes: 19fce04 ("nvme-fc: avoid calling _nvme_fc_abort_outstanding_ios from interrupt context")
	Cc: stable@vger.kernel.org
	Tested-by: Marco Patalano <mpatalan@redhat.com>
	Reviewed-by: Justin Tee <justin.tee@broadcom.com>
	Signed-off-by: Ewan D. Milne <emilne@redhat.com>
	Signed-off-by: Keith Busch <kbusch@kernel.org>
(cherry picked from commit 0a2c549)
	Signed-off-by: Jonathan Maple <jmaple@ciq.com>
jira KERNEL-1116
Rebuild_History Non-Buildable kernel-5.14.0-687.13.1.el9_8
commit-author Stefan Haberland <sth@linux.ibm.com>
commit c943bfc

After a copy pair swap the block device's "device" symlink points to
the secondary CCW device, but the gendisk's parent remained the
primary, leaving /sys/block/<dasdx> under the wrong parent.

Move the gendisk to the secondary's device with device_move(), keeping
the sysfs topology consistent after the swap.

Fixes: 413862c ("s390/dasd: add copy pair swap capability")
	Cc: stable@vger.kernel.org #6.1
	Reviewed-by: Jan Hoeppner <hoeppner@linux.ibm.com>
	Signed-off-by: Stefan Haberland <sth@linux.ibm.com>
	Signed-off-by: Jens Axboe <axboe@kernel.dk>
(cherry picked from commit c943bfc)
	Signed-off-by: Jonathan Maple <jmaple@ciq.com>
jira KERNEL-1116
Rebuild_History Non-Buildable kernel-5.14.0-687.13.1.el9_8
commit-author Stefan Haberland <sth@linux.ibm.com>
commit 40e9cd4

Quiesce and resume is a mechanism to suspend operations on DASD devices.
In the context of a controlled copy pair swap operation, the quiesce
operation is usually issued before the actual swap and a resume
afterwards.

During the swap operation, the underlying device is exchanged. Therefore,
the quiesce flag must be moved to the secondary device to ensure a
consistent quiesce state after the swap.

The secondary device itself cannot be suspended separately because there
is no separate block device representation for it.

Fixes: 413862c ("s390/dasd: add copy pair swap capability")
	Cc: stable@vger.kernel.org #6.1
	Reviewed-by: Jan Hoeppner <hoeppner@linux.ibm.com>
	Signed-off-by: Stefan Haberland <sth@linux.ibm.com>
Link: https://patch.msgid.link/20260310142330.4080106-2-sth@linux.ibm.com
	Signed-off-by: Jens Axboe <axboe@kernel.dk>
(cherry picked from commit 40e9cd4)
	Signed-off-by: Jonathan Maple <jmaple@ciq.com>
jira KERNEL-1116
Rebuild_History Non-Buildable kernel-5.14.0-687.13.1.el9_8
commit-author Stefan Haberland <sth@linux.ibm.com>
commit 4c527c7

During online processing for a DASD device an IO operation is started to
determine the format of the device. CDL format contains specifically
sized blocks at the beginning of the disk.

For a PPRC secondary device no real IO operation is possible therefore
this IO request can not be started and this step is skipped for online
processing of secondary devices. This is generally fine since the
secondary is a copy of the primary device.

In case of an additional partition detection that is run after a swap
operation the format information is needed to properly drive partition
detection IO.

Currently the information is not passed leading to IO errors during
partition detection and a wrongly detected partition table which in turn
might lead to data corruption on the disk with the wrong partition table.

Fix by passing the format information from primary to secondary device.

Fixes: 413862c ("s390/dasd: add copy pair swap capability")
	Cc: stable@vger.kernel.org #6.1
	Reviewed-by: Jan Hoeppner <hoeppner@linux.ibm.com>
	Acked-by: Eduard Shishkin <edward6@linux.ibm.com>
	Signed-off-by: Stefan Haberland <sth@linux.ibm.com>
Link: https://patch.msgid.link/20260310142330.4080106-3-sth@linux.ibm.com
	Signed-off-by: Jens Axboe <axboe@kernel.dk>
(cherry picked from commit 4c527c7)
	Signed-off-by: Jonathan Maple <jmaple@ciq.com>
jira KERNEL-1116
cve CVE-2026-46243
Rebuild_History Non-Buildable kernel-5.14.0-687.13.1.el9_8
commit-author Asim Viladi Oglu Manizada <manizada@pm.me>
commit 3da1fdf

cifs.spnego key descriptions contain authority-bearing fields such as
pid, uid, creduid, and upcall_target that cifs.upcall treats as
kernel-originating inputs. However, userspace can also create keys of
this type through request_key(2) or add_key(2), allowing those fields to
be supplied without CIFS origin.

Only accept cifs.spnego descriptions while CIFS is using its private
spnego_cred to request the key.

Fixes: f1d662a ("[CIFS] Add upcall files for cifs to use spnego/kerberos")
Assisted-by: avom-custom-harness:gpt-5.5-qwen3.6-mod-mix
	Reviewed-by: David Howells <dhowells@redhat.com>
	Signed-off-by: Asim Viladi Oglu Manizada <manizada@pm.me>
	Signed-off-by: Steve French <stfrench@microsoft.com>
(cherry picked from commit 3da1fdf)
	Signed-off-by: Jonathan Maple <jmaple@ciq.com>
Rebuild_History BUILDABLE
Rebuilding Kernel from rpm changelog with Fuzz Limit: 87.50%
Number of commits in upstream range v5.14~1..kernel-mainline: 382157
Number of commits in rpm: 21
Number of commits matched with upstream: 17 (80.95%)
Number of commits in upstream but not in rpm: 382140
Number of commits NOT found in upstream: 4 (19.05%)

Rebuilding Kernel on Branch rocky9_8_rebuild_kernel-5.14.0-687.13.1.el9_8 for kernel-5.14.0-687.13.1.el9_8
Clean Cherry Picks: 15 (88.24%)
Empty Cherry Picks: 2 (11.76%)
_______________________________

Full Details Located here:
ciq/ciq_backports/kernel-5.14.0-687.13.1.el9_8/rebuild.details.txt

Includes:
* git commit header above
* Empty Commits with upstream SHA
* RPM ChangeLog Entries that could not be matched

Individual Empty Commit failures contained in the same containing directory.
The git message for empty commits will have the path for the failed commit.
File names are the first 8 characters of the upstream SHA
@PlaidCat PlaidCat self-assigned this Jun 10, 2026
@PlaidCat PlaidCat requested review from a team June 10, 2026 04:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants