probe_subpage_writeable(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

Welcome to the Kernel API Manual, bestie πŸ’– β€” the page we're vibing with is literally probe_subpage_writeable(9), and it's giving very specific kernel energy, no cap.

🌸 NAME 🌸

probe_subpage_writeable β€” probe the user range for write faults at sub-page granularity (e.g. arm64 MTE) πŸ’…

✨ SYNOPSIS ✨

size_t probe_subpage_writeable (char __user *uaddr , size_t size );

πŸŽ€ ARGUMENTS πŸŽ€

  • uaddr β€” start of address range πŸ“, aka where the range begins.
  • size β€” size of address range πŸ“, aka how many bytes we're looking at.

πŸ’– DESCRIPTION πŸ’–

Okay so the tea β˜•: this returns 0 on success, and on a fault it returns the number of bytes not probed. That's the whole return contract, periodt.

It is expected that the caller checked for the write permission of each page in the range either by put_user or GUP. Bestie, that's not optional background noise β€” it's expected. πŸ‘€

The architecture port can implement a more efficient get_user probing if the same sub-page faults are triggered by either a read or a write. Highkey architecture-specific efficiency moment ✨.

πŸ¦‹ SEE ALSO πŸ¦‹

Kernel file ./include/linux/uaccess.h and these iconic (9) besties:


This cutie lives in ./include/linux, is dated October 2026, and answers to probe_subpage_writeable(9) β€” mwah πŸ’‹βœ¨

πŸ“¦ where this page comes from