[haiku-commits] haiku: hrev49560 - docs/user/drivers

  • From: mmlr@xxxxxxxx
  • To: haiku-commits@xxxxxxxxxxxxx
  • Date: Fri, 21 Aug 2015 21:11:41 +0200 (CEST)

hrev49560 adds 1 changeset to branch 'master'
old head: c4a9344a117d3c918506c5d91300a6ce3554c7a2
new head: 5ca445dfc6fb352f2a74e238e29f4708273974ec
overview:
http://cgit.haiku-os.org/haiku/log/?qt=range&q=5ca445dfc6fb+%5Ec4a9344a117d

----------------------------------------------------------------------------

5ca445dfc6fb: FS module docs: Add documentation for entry_cache_add_missing().

This was missed when introducing the feature in hrev49558. Thanks Jérôme
for the pointer!

Also add a note explaining that update operations on cached entries and
the removal of uncached entries are safe.

[ Michael Lotz <mmlr@xxxxxxxx> ]

----------------------------------------------------------------------------

Revision: hrev49560
Commit: 5ca445dfc6fb352f2a74e238e29f4708273974ec
URL: http://cgit.haiku-os.org/haiku/commit/?id=5ca445dfc6fb
Author: Michael Lotz <mmlr@xxxxxxxx>
Date: Fri Aug 21 19:02:55 2015 UTC

----------------------------------------------------------------------------

1 file changed, 10 insertions(+)
docs/user/drivers/fs_modules.dox | 10 ++++++++++

----------------------------------------------------------------------------

diff --git a/docs/user/drivers/fs_modules.dox b/docs/user/drivers/fs_modules.dox
index e386f19..80e2c0e 100644
--- a/docs/user/drivers/fs_modules.dox
+++ b/docs/user/drivers/fs_modules.dox
@@ -316,6 +316,16 @@
entry_cache_add() function when it encounters an entry that might not
yet
be known to the entry cache and entry_cache_remove() when a directory
entry has been removed.
+ The entry cache can also be used for negative caching. If the file
system
+ determines that the requested entry is not present during a lookup,
it can
+ cache this lookup failure by calling entry_cache_add_missing().
Further
+ calls to fs_vnode_ops::lookup() for the missing entry will then be
+ avoided.
+ Note that it is safe to call entry_cache_add() and
+ entry_cache_add_missing() with the same directory/name pair previously
+ given to either function to update a cache entry, without needing to
call
+ entry_cache_remove() first. It is also safe to call
entry_cache_remove()
+ for pairs that have never been added to the cache.
*/

// TODO:


Other related posts:

  • » [haiku-commits] haiku: hrev49560 - docs/user/drivers - mmlr