{
  "slug": "rwf-dontcache",
  "term": "RWF_DONTCACHE",
  "aliases": [
    "uncached buffered I/O",
    "buffered I/O drop-behind"
  ],
  "definition": "RWF_DONTCACHE is a Linux per-operation flag requesting best-effort removal of page-cache content newly instantiated by a buffered read or write.",
  "note": "The flag is documented since Linux 6.14; previously cached ranges are not pruned by the hint, and unsupported targets report EOPNOTSUPP. Writes initiate writeback, which is not a durability guarantee. [rwf-api] The v6.14 filemap_read path still copies cached folios to the caller before attempting drop-behind; this is not O_DIRECT or proof of zero-copy transfer. [dropbehind-source]",
  "advantages": [
    "Can limit cache retention for one-pass buffered access while retaining already cached ranges."
  ],
  "limitations": [
    "No hard guarantee of final cache state, durable completion or improved throughput."
  ],
  "related": [
    "buffered-io",
    "page-cache",
    "direct-io",
    "posix-fadv-noreuse",
    "posix-fadv-dontneed",
    "fsync"
  ],
  "citations": [
    {
      "id": "rwf-api",
      "label": "readv(2)",
      "title": "Linux man-pages 6.19: readv(2), RWF_DONTCACHE and RWF_DSYNC/RWF_SYNC.",
      "url": "https://man7.org/linux/man-pages/man2/readv.2.html",
      "accessed": "2026-10-15"
    },
    {
      "id": "dropbehind-source",
      "label": "Linux v6.14 filemap",
      "title": "Linux v6.14 mm/filemap.c: filemap_read and drop-behind read completion.",
      "url": "https://github.com/torvalds/linux/blob/v6.14/mm/filemap.c",
      "accessed": "2026-10-15"
    }
  ],
  "status": "shipping",
  "supersedes": [],
  "supersededBy": [],
  "firstSeen": null,
  "lastSeen": null,
  "updated": "2026-10-15"
}
