X-Git-Url: http://git.vrable.net/?a=blobdiff_plain;f=bluesky%2Fbluesky.h;h=3fc1c6af1a7b63a8c1c9bb060cc3fac2626aa677;hb=f597cd5067ed36508118d2ecd29338e7b81f47e4;hp=fdc2e39fdff14f5160bf4abe052d8ad28a80d467;hpb=fb15c75f3c8eeb3d7b277795ced44bb4928273a1;p=bluesky.git diff --git a/bluesky/bluesky.h b/bluesky/bluesky.h index fdc2e39..3fc1c6a 100644 --- a/bluesky/bluesky.h +++ b/bluesky/bluesky.h @@ -116,6 +116,12 @@ typedef struct { uint64_t next_inum; /* Next available inode for allocation */ BlueSkyStore *store; + + /* Accounting for memory used for caches. Space is measured in blocks, not + * bytes. We track both total data in the caches and dirty data (total + * data includes dirty data). Updates to these variables must be made + * atomically. */ + gint cache_total, cache_dirty; } BlueSkyFS; /* Inode number of the root directory. */