Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1793187457; b=PRWZ2W76mk9JI3U/zUaiu72/K1E6M6uriSSx49unq+/JjRLTXjlOEuWCc2mxAMEOf92k lNXnnzQZR2ZilZuxfeZnsUWubLplHw3nqtXGCWbaAFT2Gmie9Fc3lnclvhZD9p1WOZBvI ZtDq7HtRxgb1JqZrdIeJhtpoJkycO2667aP1H8G+tX0sD6n9sgwpQ9HJCAkXNWvuhp2r9 4lLVLn9lA7kurgDTdSzdlk9w9C4Z+tLYaCMbvWWzW4mos5AcQx3eGxnMsXjeov8cIZZ0k kjhLguLziy6+sDlfXYmpKK1ZISYmH8Tz0PX3McQ7KCynUrYknhsRjnbJlVm+ciDH79Q== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1793187457; h=Received:DKIM-Signature:From:To:Cc:Subject:Date:Message-ID:X-Mailer: Reply-To:MIME-Version:Lines:X-Developer-Signature:X-Developer-Key: Content-Transfer-Encoding; bh=EePI3+o4d53nrhlVqmN5KGCXaV9rzKCQQIFB6DPPOJE=; b=bH3UkhDz2v6a5HlOIr5ubBZHRoc7JD/BhK3nngwxE9QR0HkndqwBAihTVlEbGap/eAFL BLGvt98mSsM3EpC9HyGamGhtUMrikmDHjh9EvZiHQ9OWuWPXTT08iBPuCX5WYygqJ7tDC qq886iwq8uuxoBqbxW8rItnoHIOVIRh2X6b/jKKkLMhDZrmuVyubK0/dbYTK8PGnXYbYC 9QkxWXE+qpWcEovmN+gWXb8kxpqjDf01TZKfydBr2aBJS2uk/j3SWKuKRLDn3ZXIEUOFx oGCqoQZKaR4NpAc1rlpzgrQaeK8h80rPwimScxGvDpJZILcwHOJZmkvFgLqwOCej3FA== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=CGpGFyOh; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9ECC8606A31E for ; Wed, 28 Oct 2026 11:37:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key, unprotected) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=CGpGFyOh Received: by smtp.kernel.org (Postfix) with ESMTPSA id A764D1F01825; Wed, 28 Oct 2026 11:37:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1793187456; bh=EePI3+o4d53nrhlVqmN5KGCXaV9rzKCQQIFB6DPPOJE=; h=From:To:Cc:Subject:Date:Reply-To; b=CGpGFyOhWF12YSAE62z+qLofFsuLhUiejSqoWDhX+fP1l63AHMASMEJ8pVmSojMEq eqQVgjhWCqyLGdIZUvbKucZ19DtdKm5oc6FGc08hYDQzxqmCPSpbkhoz4ybDpE6w36 R6iT/UmdV3NEKy0dfBNmJXIny6Yjm8swvF6nZsEA= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-99127: page_pool: keep frag_offset aligned for odd-sized requests Date: Wed, 28 Oct 2026 11:35:14 +0100 Message-ID: <2026102858-CVE-2026-99127-642a@gregkh> X-Mailer: git-send-email 2.56.0 Reply-To: , X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=6032; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=CvT62ADOWr4nIveDd2sxfo43QyYUeSX3vIrqYewMbaI=; b=owGbwMvMwCRo6H6F97bub03G02pJDFkPz19q3bTC4aP0sQ/Hs2O2iu7jWbakOlZCI0jw2/vtH 8Of79uxviOWhUGQiUFWTJHlyzaeo/srDil6GdqehpnDygQyhIGLUwAm4r6KYcGWJq5lGts7097w Z8TLilkJNusYNzDMT5xvu0c7sFkvZknNooOu6289vjlrHQA= X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: page_pool: keep frag_offset aligned for odd-sized requests page_pool_alloc_frag_netmem() rounds the requested fragment size with size = ALIGN(size, dma_get_cache_alignment()); dma_get_cache_alignment() returns 1 unless the architecture defines ARCH_DMA_MINALIGN, which DMA-coherent architectures such as x86 do not. There the ALIGN() is a no-op and pool->frag_offset advances by the raw, unrounded size. A single caller asking for an odd size then leaves frag_offset misaligned for every fragment carved out of that page afterwards. The pool is shared, so the damage is not confined to the caller that caused it. The per-cpu system_page_pool used by generic XDP hits this. skb_pp_cow_data() allocates its fragments with the raw packet length: size = min_t(u32, len, PAGE_SIZE); truesize = size; page = page_pool_dev_alloc(pool, &page_off, &truesize); leaving frag_offset odd for whatever is carved out of that page next. Its own head allocation is already aligned -- SKB_HEAD_ALIGN(size) plus the XDP_PACKET_HEADROOM its callers pass -- so it is a later user of the shared pool that pays: page_pool_dev_alloc_va() returns a misaligned buffer, napi_build_skb() installs it as skb->head, and skb_shinfo(skb) == skb->head + skb->end is misaligned with it. skb_shinfo()->dataref is a 4-byte atomic_t at offset 0x20, so the atomic_inc() in __skb_clone() straddles a cache line. On x86 with split lock detection -- fatal for kernel split locks by default -- this panics the machine: Oops: Split lock detected RIP: 0010:skb_clone+0x154/0x1e0 Call Trace: raw_local_deliver+0x1ed/0x2c0 ip_protocol_deliver_rcu+0x54/0x1c0 ip_local_deliver_finish+0x85/0x100 ip_local_deliver+0x67/0x100 __netif_receive_skb_one_core+0x85/0xa0 process_backlog+0x87/0x130 Reproduced by attaching any generic-mode XDP program to loopback and opening a RAW IPPROTO_UDP socket, which makes raw_local_deliver() clone every locally delivered UDP packet; ordinary DNS traffic then triggers it, roughly once per 2500 clones. Observed on 6.12.101 and 7.1.8. Tracing page_pool_alloc_frag_netmem() over one such run shows the amplification -- two odd-sized requests, nine misaligned offsets: requested size & 7: 0: 17035 5: 1 7: 1 frag_offset & 7: 0: 17028 3: 1 4: 1 5: 1 6: 1 7: 5 and skb_pp_cow_data() returning heads that were aligned on entry: head 0xffff8f4c86aeac00 -> 0xffff8f4c53a9a9c4 (&7=4) head 0xffff8f4d6a8a42c0 -> 0xffff8f4c4f7b7a45 (&7=5) Round the fragment size up to at least the alignment struct skb_shared_info requires, so fragments are always suitably aligned for the objects callers build on them. Architectures needing a larger DMA alignment keep it. This also makes the remainder computed in page_pool_alloc_netmem(), *size = max_size - *offset; aligned, since max_size is a power of two -- which fixes the matching misalignment of skb->end. Verified with a controlled A/B under QEMU/KVM: same tree, same config, same compiler, same rootfs and identical traffic, differing only by this patch. A SEC("xdp.frags") XDP_PASS program on lo plus UDP datagrams larger than max_head_size drives skb_pp_cow_data()'s fragment loop, which passes raw packet lengths to the pool. Measured at the return of skb_pp_cow_data(): unpatched patched skb_pp_cow_data calls 40800 40800 misaligned skb->head 1120 0 dataref at line offset >60 80 0 The last row counts the accesses that actually fault: skb_shinfo()->dataref sits at head+end+0x20 and is a 4-byte atomic, so `lock incl` splits a 64-byte cache line only when that address lands at offset 61..63. All 80 occurrences were at offset 61; the panic reported above was at offset 62. Eliminating the misalignment removes every one of them. Same class of bug as commit 3bed3cc4156e ("net: Do not allocate page fragments that are not skb aligned"), which fixed the older netdev_alloc_frag()/napi_alloc_frag() allocators. The Linux kernel CVE team has assigned CVE-2026-99127 to this issue. Affected and fixed versions =========================== Issue introduced in 5.15 with commit 53e0961da1c7bbdabd1abebb20de403ec237ec09 and fixed in 6.18.59 with commit 813a72beaa5d3f4bb135e0def9b3f07a3511ca0e Issue introduced in 5.15 with commit 53e0961da1c7bbdabd1abebb20de403ec237ec09 and fixed in 7.2.13 with commit dca1b51693c81eaf77e50980be373e01ae857394 Issue introduced in 5.15 with commit 53e0961da1c7bbdabd1abebb20de403ec237ec09 and fixed in 7.3 with commit dc0df5a0c62ccea1d0e08d39a4dc9064de81d411 Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community. Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at https://cve.org/CVERecord/?id=CVE-2026-99127 will be updated if fixes are backported, please check that for the most up to date information about this issue. Affected files ============== The file(s) affected by this issue are: net/core/page_pool.c Mitigation ========== The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits: https://git.kernel.org/stable/c/813a72beaa5d3f4bb135e0def9b3f07a3511ca0e https://git.kernel.org/stable/c/dca1b51693c81eaf77e50980be373e01ae857394 https://git.kernel.org/stable/c/dc0df5a0c62ccea1d0e08d39a4dc9064de81d411