Re: [PATCH] fs/9p: Add new options to Documentation

From: asmadeus
Date: Sun Apr 02 2023 - 14:23:23 EST


Christian Schoenebeck wrote on Sun, Apr 02, 2023 at 04:07:51PM +0200:
> > So, mapping of existing (deprecated) legacy modes:
> > - none (obvious) write_policy=writethrough
> > - *readahead -> cache=file cache_validate_open write_policy=writethrough
> > - mmap -> cache=file cache_validate=open write_policy=writeback
>
> Mmm, why is that "file"? To me "file" sounds like any access to files is
> cached, whereas cache=mmap just uses the cache if mmap() was called, not for
> any other file access.

The semantics are slightly different but I don't think anyone would
mind; mmap was introduced as a way of having minimal caching but file
caching + /sys/class/bdi/9p*/max_bytes to 0 should be almost identical
once we've made sure our cache code sends bigger than 4k writes at a
time (I *think* that's still a problem and there was netfs work in the
ways, but you'd have noticed?)

--
Dominique