keybase / kbfs

Keybase Filesystem (KBFS)
https://keybase.io/docs/kbfs
BSD 3-Clause "New" or "Revised" License
1.21k stars 135 forks source link

bcache: stop tracking prefetch status in memory #1987

Closed strib closed 5 years ago

strib commented 5 years ago

Now that blocks can move from the working set cache to the sync cache (which changes the block's prefetch status), it's hard to keep a synchronized view of the prefetch status in memory. So, just rely on the disk cache entirely for the prefetch status.

Note this contains a bit of a hack for storing the prefetch status in the block retrieval queue when there's no disk block cache. I couldn't find a more elegant way of doing it that didn't require splitting up the disk cache lookup into two calls, so I thought this was better.

Issue: KBFS-3644

strib commented 5 years ago

@jzila I will merge this into #1962 before I merge that one.