<feed xmlns='http://www.w3.org/2005/Atom'>
<title>g/linux.git/include, branch master</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.</subtitle>
<id>https://bastion.nosebs.vip/g/linux.git/atom/include?h=master</id>
<link rel='self' href='https://bastion.nosebs.vip/g/linux.git/atom/include?h=master'/>
<link rel='alternate' type='text/html' href='https://bastion.nosebs.vip/g/linux.git/'/>
<updated>2026-11-17T19:51:40Z</updated>
<entry>
<title>Merge tag 'mm-core-7.4-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/mm/core</title>
<updated>2026-11-17T19:51:40Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2026-11-17T19:51:40Z</published>
<link rel='alternate' type='text/html' href='https://bastion.nosebs.vip/g/linux.git/commit/?id=63fdb511c27afcebce797e3db580b3534ddfa639'/>
<id>urn:sha1:63fdb511c27afcebce797e3db580b3534ddfa639</id>
<content type='text'>
Pull core memory management fixes from David Hildenbrand:
 "The main changes are:

   - Prevent folio refcount overflows with pagecache folios, mostly
     relevant for large folios today. The networking changes for this
     will go through the net tree.

   - Fix out-of-bounds page table accesses with folded PMDs in 3
     scenarios.

   - Fix write-sealing of memfd to detect GUP pins with concurrent
     (un)mapping more reliably, preventing writes through GUP pins after
     write-sealing.

   - Fix lost wakeups when splitting large folios.

   - Fix exposing uninitialized data through MADV_COLLAPSE to user
     space.

  The refcount changes also include a related iommufd fix for properly
  cleaning up when pinning memfd folios fails, which is now easier to
  trigger"

* tag 'mm-core-7.4-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/mm/core:
  mm/gup: limit pagecache folio refcount when grabbing references
  iommufd: fix cleanup when adding memfd folio pins fails
  mm/mmu_gather: flush pending references early before the folio limit
  mm: limit pagecache folio refcount when splicing into pipes
  mm: limit pagecache folio refcount when mapping pages
  mm/huge_memory: prevent losing PG_waiters in __split_folio_to_order()
  mm/rmap: fix PTE table overruns during batched reference checks
  mm/rmap: fix PTE table overruns during batched unmap
  mm/userfaultfd: fix PTE table overruns in UFFDIO_MOVE
  mm/memfd: handle GUP pins more reliably when write-sealing
  mm/khugepaged: don't map folios that are not uptodate in MADV_COLLAPSE
</content>
</entry>
<entry>
<title>Merge tag 'assoc-array-fixes-v2'</title>
<updated>2026-11-16T17:35:38Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2026-11-16T17:35:38Z</published>
<link rel='alternate' type='text/html' href='https://bastion.nosebs.vip/g/linux.git/commit/?id=666539eecdf4db623f5e3c3e55cf9f2dfad24aa4'/>
<id>urn:sha1:666539eecdf4db623f5e3c3e55cf9f2dfad24aa4</id>
<content type='text'>
Clean up assoc_array library code

I had already gotten rid of this tag locally, because we then decided
to just remove the assoc_array library entirely since it has only one
single user - the key handling code - and that user is getting rewritten
to use rhashtable instead.

But that removal is scheduled for 7.5, and this fixes real bugs and does
clean up some of the code.  So while it's all slated for removal, some
of the fixes need back-porting and we might as well remove the
cleaned-up version.  Maybe somebody decides they want to resurrect it
for another project - it really is fairly generic library code - they
shouldn't get the messy end state that we decided to jettison.

Background: Nils Ollrogge reported a bug in the assoc_array library and
had a patch to fix it too, but that code was too obscure for me to
follow, so I used some LLM tools to help make sense of it all and found
more issues in the process.

* tag 'assoc-array-fixes-v2':
  assoc_array: use assoc_array_parent_link() when splitting a shortcut
  assoc_array: find and collapse in deletion without gotos
  assoc_array: move deletion's collapse into a function of its own
  assoc_array: replace the labels in gc's tree walk with a loop
  assoc_array: move gc's folding into a function of its own
  assoc_array: keep gc's cleanup out of the live tree on allocation failure
  assoc_array: don't chain a new shortcut onto an existing one
  assoc_array: choose between splitting a node and a shortcut without gotos
  assoc_array: move shortcut creation into a function of its own
  assoc_array: move node splitting into a function of its own
  assoc_array: fill the segment cache in one place
  assoc_array: move in-place insertion into a function of its own
  assoc_array: don't lose objects when a root shortcut is split at level 4
  assoc_array: don't lose objects when a shortcut is split on a word boundary
  assoc_array: correct the documentation of get_key_chunk()'s level argument
</content>
</entry>
<entry>
<title>Merge tag 'char-misc-7.4-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc</title>
<updated>2026-11-16T16:02:58Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2026-11-16T16:02:58Z</published>
<link rel='alternate' type='text/html' href='https://bastion.nosebs.vip/g/linux.git/commit/?id=141b164bbe186423e295b139e40e8e2d11cf1341'/>
<id>urn:sha1:141b164bbe186423e295b139e40e8e2d11cf1341</id>
<content type='text'>
Pull char/misc/iio driver fixes from Greg KH:
 "Here are a bunch of char, misc, and iio driver fixes for reported
  problems for 7.4-rc4. Included in here are:

   - usual collection of lots of IIO driver fixes for issues

   - binder driver fix

   - iio, w1, and comedi driver fixes found and fixed by Josef

   - comedi driver fix for a reported problem

   - other misc driver fixes

  All of these have been in linux-next for a while with no reported
  issues"

* tag 'char-misc-7.4-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc: (68 commits)
  iio: hid-sensors: fix fractional part for unit exponents -7 and -8
  iio: trigger: free the trigger ID after device_del()
  iio: hid-sensors: fix a division by zero
  iio: humidity: hid-sensor-humidity: Use per-instance callbacks
  iio: temperature: hid-sensor-temperature: Use per-instance callbacks
  comedi: comedi_bond: Fix leak of opened device references
  mei: me: add ice lake point LP iTouch DID
  mei: lb: read the MTU once
  rust_binder: push BR_TRANSACTION_COMPLETE before BR_FAILED_REPLY
  misc: ibmvmc: initialize HMC state before device registration
  w1: w1_therm: leave the slaves of other families alone
  w1: w1_therm: lock the list of slaves for the bulk read
  w1: don't hold list_mutex while a slave is torn down
  w1: netlink: drop the slave after the bus is unlocked
  w1: ds2805: use the bus mutex to talk on the bus
  w1: ds28e04: use the bus mutex to talk on the bus
  w1: ds2482: set the strong pull-up with its byte
  w1: remove the master's files before taking its locks
  w1: use the bus mutex for the "rw" file
  misc: bcm-vk: fix DMA allocation memory leak
  ...
</content>
</entry>
<entry>
<title>Merge tag 'nfs-for-7.4-2' of git://git.linux-nfs.org/projects/anna/linux-nfs</title>
<updated>2026-11-15T21:48:31Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2026-11-15T21:48:31Z</published>
<link rel='alternate' type='text/html' href='https://bastion.nosebs.vip/g/linux.git/commit/?id=f70886e5a510cd7fc2c3aef91c46a14f4485fe63'/>
<id>urn:sha1:f70886e5a510cd7fc2c3aef91c46a14f4485fe63</id>
<content type='text'>
Pull NFS client fixes from Anna Schumaker:

 - Various NFS and SunRPC fixes from Avi Weiss

 - Various localio fixes from Mike Snitzer

 - Delegated timestamp fixes from Jeff Layton

 - CB_NOTIFY_LOCK fixes from Olga Kornievskaia

 - Various sunrpc, flexfiles, and xprtrdma fixes from Tim Menninger

* tag 'nfs-for-7.4-2' of git://git.linux-nfs.org/projects/anna/linux-nfs: (26 commits)
  NFSv4: Prevent indefinite waits for out-of-order OPEN stateids
  NFSv4/flexfiles: limit transport disconnects when cancelling I/O
  SUNRPC: add request-scoped disconnects when cancelling tasks
  pNFS: avoid repeatedly cancelling I/O for the same lseg
  xprtrdma: serialize unmap_sync with xprt_disconnect
  NFSv4: remember that the server may send CB_NOTIFY_LOCK
  NFSv4: wake blocking lock waiters when a delegated lock is released
  NFS: stamp after the server's ctime following a CLONE
  NFS: stamp after the server's ctime when truncating under delegated times
  NFS: don't let delegated c/mtime stamps go backward
  NFS/localio: give the LOCALIO probe a short timeout of its own
  NFS/localio: probe again for LOCALIO when localio_enabled is set to Y
  NFS/localio: hold the client across an asynchronous LOCALIO probe
  SUNRPC: Balance queue accounting when relocating a task
  SUNRPC: Balance switch queue length on transport removal
  SUNRPC: Fix TCP-with-TLS transport class identification
  SUNRPC: preserve transport security policy when cloning clients
  SUNRPC: preserve timeout policy when cloning clients
  SUNRPC: preserve fatal network errors during RPC binding
  sunrpc: instantiate rpc_pipefs dentry before publishing it
  ...
</content>
</entry>
<entry>
<title>Merge tag 'timers-urgent-2026-11-15' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip</title>
<updated>2026-11-15T17:09:04Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2026-11-15T17:09:04Z</published>
<link rel='alternate' type='text/html' href='https://bastion.nosebs.vip/g/linux.git/commit/?id=0feaf5349e0a0521de3406343df32954801784d9'/>
<id>urn:sha1:0feaf5349e0a0521de3406343df32954801784d9</id>
<content type='text'>
Pull timer fixes from Ingo Molnar::

 - Add VDSO_UNALIGNED_PACKED config option for targets without efficient
   unaligned memory accesses (such as ARMv5), and turn it on for
   !CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS platforms.

   Propagate these changes into tooling headers as well (Ian Rogers)

 - Read getboottime64() offsets under the tk_core.seq sequence counter
   (Hungyu Lin)

 - Keep tsacct task begin times stable across suspend (Hungyu Lin)

 - Reject cross timestamps for invalid AUX clocks (Avi Weiss)

 - Refresh auxiliary timekeeper base before offset validation (Avi
   Weiss)

* tag 'timers-urgent-2026-11-15' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  timekeeping: Refresh auxiliary base before offset validation
  timekeeping: Reject cross timestamps for invalid AUX clocks
  tsacct: Keep task begin times stable across suspend
  timekeeping: Read getboottime64() offsets under the sequence counter
  tools headers: Update the vdso/unaligned.h copy with the kernel sources
  vdso: Add VDSO_UNALIGNED_PACKED config option
</content>
</entry>
<entry>
<title>Merge tag 'core-urgent-2026-11-15' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip</title>
<updated>2026-11-15T16:59:45Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2026-11-15T16:59:45Z</published>
<link rel='alternate' type='text/html' href='https://bastion.nosebs.vip/g/linux.git/commit/?id=d56cd25dc0dc3fdb79e1f1df8dc366dabff8ec54'/>
<id>urn:sha1:d56cd25dc0dc3fdb79e1f1df8dc366dabff8ec54</id>
<content type='text'>
Pull core syscall fixes from Ingo Molnar:

 - Two generic syscall entry code fixes for return code
   data type definitions (Florian Bezdeka)

* tag 'core-urgent-2026-11-15' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  entry: Complete syscall_enter_from_user_mode_work() to bool migration
  entry: Fix return type of syscall_trace_enter()
</content>
</entry>
<entry>
<title>mm/gup: limit pagecache folio refcount when grabbing references</title>
<updated>2026-11-14T15:36:05Z</updated>
<author>
<name>David Hildenbrand (Arm)</name>
<email>david@kernel.org</email>
</author>
<published>2026-11-12T22:53:24Z</published>
<link rel='alternate' type='text/html' href='https://bastion.nosebs.vip/g/linux.git/commit/?id=2d9bcd380585abc436f055fbb618b34f98882004'/>
<id>urn:sha1:2d9bcd380585abc436f055fbb618b34f98882004</id>
<content type='text'>
Let's add __folio_ref_count_over_limit() checks in fast and slow GUP
before acquiring additional references or pins.

Keep it simple and use the check for all folio types.

Also propagate try_grab_folio() errors when grabbing additional
references in __get_user_pages() and in memfd_pin_folios(), so hitting
the limit returns -ENOMEM instead of -EFAULT and -EINVAL, respectively.

Keep the existing invalid-refcount warnings.

Fixes: 800d8c63b2e9 ("shmem: add huge pages support")
Fixes: 99cb0dbd47a1 ("mm,thp: add read-only THP support for (non-shmem) FS")
Fixes: 793917d997df ("mm/readahead: Add large folio readahead")
Cc: stable@vger.kernel.org
Reviewed-by: Jose A. Perez de Azpillaga &lt;azpijr@gmail.com&gt;
Reviewed-by: Pedro Falcato &lt;pfalcato@suse.de&gt;
Link: https://patch.msgid.link/20261112-refcount_overflow_stable-v4-5-ad3deef0bd23@kernel.org
Signed-off-by: David Hildenbrand (Arm) &lt;david@kernel.org&gt;
</content>
</entry>
<entry>
<title>mm/mmu_gather: flush pending references early before the folio limit</title>
<updated>2026-11-14T15:36:05Z</updated>
<author>
<name>David Hildenbrand (Arm)</name>
<email>david@kernel.org</email>
</author>
<published>2026-11-12T22:53:22Z</published>
<link rel='alternate' type='text/html' href='https://bastion.nosebs.vip/g/linux.git/commit/?id=317bd7d28b248fd4d4e14614d7c30b17a36ef4d7'/>
<id>urn:sha1:317bd7d28b248fd4d4e14614d7c30b17a36ef4d7</id>
<content type='text'>
When a task zaps mappings (e.g., MADV_DONTNEED), it can drop the PT lock
and defer dropping the folio references. In the meantime, page faults
can refault pagecache folios, creating more references for the same
folios. These deferred references can build up over multiple VMAs.

Let's just request a flush after enqueueing folios whose refcount reached
a certain threshold. Start flushing well before new references are refused,
regardless of the caller's privileges.

When returning "true" from __tlb_remove_folio_pages_size(), PTE zapping
will flush the TLB before dropping the PT lock, but drop the references
afterwards. Refaults can still race with that, but flushing early reduces
the risk of letting others hit the limit.

This is a temporary measure until we have something better.

Reported-by: Chris Mason &lt;mason@kernel.org&gt;
Fixes: 800d8c63b2e9 ("shmem: add huge pages support")
Fixes: 99cb0dbd47a1 ("mm,thp: add read-only THP support for (non-shmem) FS")
Fixes: 793917d997df ("mm/readahead: Add large folio readahead")
Cc: stable@vger.kernel.org
Reviewed-by: Jose A. Perez de Azpillaga &lt;azpijr@gmail.com&gt;
Reviewed-by: Lance Yang &lt;lance.yang@linux.dev&gt;
Reviewed-by: Pedro Falcato &lt;pfalcato@suse.de&gt;
Link: https://patch.msgid.link/20261112-refcount_overflow_stable-v4-3-ad3deef0bd23@kernel.org
Signed-off-by: David Hildenbrand (Arm) &lt;david@kernel.org&gt;
</content>
</entry>
<entry>
<title>mm: limit pagecache folio refcount when splicing into pipes</title>
<updated>2026-11-14T15:36:05Z</updated>
<author>
<name>David Hildenbrand (Arm)</name>
<email>david@kernel.org</email>
</author>
<published>2026-11-12T22:53:21Z</published>
<link rel='alternate' type='text/html' href='https://bastion.nosebs.vip/g/linux.git/commit/?id=c6c9a4c1c9a1669693330205cb9d86fafd3cf235'/>
<id>urn:sha1:c6c9a4c1c9a1669693330205cb9d86fafd3cf235</id>
<content type='text'>
Similar to mapping pagecache folios into page tables, let's reject
additional references when splicing folios into a pipe if the refcount
is at its limit.

This will prevent more cases of possible folio refcount overflows with
large pagecache folios.

Introduce folio_get_checked() for checked reference acquisition when
the caller already holds a reference. It warns and fails on a non-positive
refcount and rejects additional references at the limit.

Add __folio_ref_count_over_limit() so folio_get_checked() can reuse the
refcount instead of having to read it a second time.

Use folio_get_checked() in splice_folio_into_pipe() and
fuse_ref_folio(), returning -EFAULT on failure, like we already do for
pipe-buffer duplication. Similarly, make try_get_page() use it instead.

Likely try_get_page() should be renamed (or removed) later, as it doesn't
match the folio_try_get() semantics and is confusing.

If we hit the limit after splicing some data, return the number of bytes
already spliced. Teach the callers to handle errors, and stop
filemap_splice_read() if we only spliced part of a folio, so we don't
skip ahead to the next folio: note that we wouldn't run into this
scenario before as we always spliced the requested range.

The check in try_get_page() also covers pipe-buffer duplication by tee()
and partial pipe-to-pipe splicing.

Note that we deliberately will not fall back to the slow path of copying
the folio, particularly as the folio might have an invalid refcount. If
it is ever really required, we can revisit.

Fixes: 800d8c63b2e9 ("shmem: add huge pages support")
Fixes: 99cb0dbd47a1 ("mm,thp: add read-only THP support for (non-shmem) FS")
Fixes: 793917d997df ("mm/readahead: Add large folio readahead")
Cc: stable@vger.kernel.org
Reviewed-by: Jose A. Perez de Azpillaga &lt;azpijr@gmail.com&gt;
Reviewed-by: Pedro Falcato &lt;pfalcato@suse.de&gt;
Link: https://patch.msgid.link/20261112-refcount_overflow_stable-v4-2-ad3deef0bd23@kernel.org
Signed-off-by: David Hildenbrand (Arm) &lt;david@kernel.org&gt;
</content>
</entry>
<entry>
<title>mm: limit pagecache folio refcount when mapping pages</title>
<updated>2026-11-14T15:35:59Z</updated>
<author>
<name>David Hildenbrand (Arm)</name>
<email>david@kernel.org</email>
</author>
<published>2026-11-12T22:53:20Z</published>
<link rel='alternate' type='text/html' href='https://bastion.nosebs.vip/g/linux.git/commit/?id=26b8f029ce5224dd5c5f45a4bc964a209c259914'/>
<id>urn:sha1:26b8f029ce5224dd5c5f45a4bc964a209c259914</id>
<content type='text'>
With large file folios, overflowing the folio mapcount and refcount
became possible more easily. For anon folios it is currently not really
an issue: each large anon folio can only be mapped once into a process; on
4k kernels it would be more processes than usually allowed on a system,
and on 16k or 64k kernels the processes alone would consume hundreds of
GiB. Something to be sorted out at some point, but it's not as urgent.

Being able to overflow the refcount is not really big news, but it's about
time that we do something about it because some modern technology might
find ways to abuse it :)

One of the enablers for that was commit ddc58f27f9ee ("mm: drop tail page
refcounting"), however, file thp support was added later.

File folios can be mapped multiple times into the same process, allowing
for processes to hold many references to the same folio.

As a short-term solution, let's introduce two folio refcount limits:
one for ordinary consumers and one for admins. Leave some headroom
before the refcount goes negative, which we really don't want (having
the mapcount go negative is also not expected).

Start reporting SIGBUS and a ratelimited warning if we run into limits.
When restoring mappings from migration entries, instead zap the pte/pmd
entry. We allow for slightly exceeding the limit to keep things simpler.

During fork(), prefer not copying page table entries over failing fork.
For fault-around, check in next_uptodate_folio() before trying to lock
the folio.

Export folio_ref_count_over_limit_slowpath() using EXPORT_SYMBOL_GPL
right away so modules can use it through try_get_page(), where we will
use it next.

Use has_capability_noaudit(current, CAP_SYS_RESOURCE),
so filesystem credential overrides do not affect access to the admin
reserve, and to not generate auditing messages simply because we access
optional reserves.

Don't grant access to the admin reserve from kernel threads, from
interrupt context, where "current" is just the interrupted task, or with
IRQs disabled, as even unaudited capability checks can take locks.

This is far from ideal, but better than all easy alternatives we can
backport comfortably. For now it fixes the big problem: letting
the refcount (+mapcount) go negative and cause trouble.

This is only a temporary fix. Keep the mapping checks explicit and
separate from reference acquisition: most are expected to disappear when
we rework the underlying refcounting.

Check order 0 folios as well for consistency: each
folio_add_file_rmap*() and folio_dup_file_rmap*() needs a prior check.

Adjust the check in folio_get() to just check for invalid refcounts and
drop folio_ref_zero_or_close_to_overflow(): we really don't want
negative refcounts or negative mapcounts. Convert to VM_WARN_ON_FOLIO as
we touch it.

Also, just document -EHWPOISON for copy_present_ptes() while at it.

Note: When zapping file migration entries, uffd-wp is preserved using PTE
markers, but uffd-rwp protection is lost because there is no corresponding
marker. try_to_unmap() already has the same problem when unmapping file
folios, so we'll happily ignore it.

Reported-by: Chris Mason &lt;mason@kernel.org&gt;
Fixes: 800d8c63b2e9 ("shmem: add huge pages support")
Fixes: 99cb0dbd47a1 ("mm,thp: add read-only THP support for (non-shmem) FS")
Fixes: 793917d997df ("mm/readahead: Add large folio readahead")
Cc: stable@vger.kernel.org
Reviewed-by: Jose A. Perez de Azpillaga &lt;azpijr@gmail.com&gt;
Acked-by: Zi Yan &lt;ziy@nvidia.com&gt;
Reviewed-by: Pedro Falcato &lt;pfalcato@suse.de&gt;
Link: https://patch.msgid.link/20261112-refcount_overflow_stable-v4-1-ad3deef0bd23@kernel.org
Signed-off-by: David Hildenbrand (Arm) &lt;david@kernel.org&gt;
</content>
</entry>
</feed>
