> Failure is fine if there is no folio or the folio is not uptodate. I > assume we can do: > > folio = __filemap_get_folio(r->mapping, pg_off, 0, 0); > if (!folio || !folio_test_uptodate(folio)) > return -EFAULT; > > Is this appropriate here? Yes EFAULTing is fine for this usage. -Andi