commit 7a96cbb08f3c9a9439467b7cd4b8cd5ce37c171a
Author: Yiannis Pericleous <[EMAIL PROTECTED]>
Date: Thu Apr 12 17:19:38 2007 -0400
odf doc update
diff --git a/Documentation/filesystems/unionfs/odf.txt
b/Documentation/filesystems/unionfs/odf.txt
index 4e82600..bb3b751 100644
--- a/Documentation/filesystems/unionfs/odf.txt
+++ b/Documentation/filesystems/unionfs/odf.txt
@@ -170,9 +170,9 @@ normal user's view.
An /odf is a hierarchy of directories and files with specific purposes, as
follows:
-1. /odf/sb is a plain file containing our superblock, which records branch
- configuration, UUIDs, etc. Each branch has a unique UUID so it can be
- identified consistently.
+1. /odf/sb contains the whiteoute file and a file containing our superblock,
+ which records branch configuration, UUIDs, etc. Each branch has a unique
+ UUID so it can be identified consistently.
2. /odf/ns/<PATH> is used for storing information about whiteouts, opaque
directories, and persistent inode numbers. We use the actual inum of the
@@ -180,7 +180,7 @@ follows:
stands for Name-Space.
3. /odf/ic/##/##/<INUM> is for caching readdir() results, where '##' is the
- 64-bit inum, broken one byte at a time, for up to an 8-deep hierarchy.
+ 64-bit inum, broken two bytes at a time, for up to a 4-deep hierarchy.
(It might be more efficient for '##' to go MSB->LSB, to help inum
locality.) The term 'ic' stands for icache.
@@ -240,10 +240,6 @@ The ODF superblock (/odf/sb) stores the following:
options again. (Optional: we can record portable information such as a
file system's LABEL.)
-- records whether this odf is newly formatted or in use. (We can store a
- "new" bit which is initialized on mkfs, or just count the number of inodes
- in use.)
-
- we might also need to record extra info to handle hardlinks (e.g., the
orig branch pathname from root of that branch's file system up to the
lower-branch dir name we stack on)
@@ -253,24 +249,19 @@ Actions:
1. To prepare a new ODF, just run "mkfs" on the /odf partition, and set the
"new" bit.
-2. on mount, clear odf "new" bit; get the number and list of branches, and
- their UUIDs, and store in /odf/sb.
+2. on mount, check if config file in /odf/sb exists; get the number and list
+ of branches, and their UUIDs, and store them in the config file.
3. on remount, if we reconfigure the branches, then
-(a) new bit cannot be on (else BUG_ON)
+(a) /odf/sb/config must exist (else BUG_ON)
-(b) compare old and new UUID list: if same (rare case), then ignore.
+(b) update /odf/sb/co file
-(c) if UUID list differs, and we didn't use the "odfforce" flag, then return
- EINVAL (or some other errno) because the odf cache will have been stale.
+(c) if "odfforce" flag was not specified clean the dir cache in /odf/ic
(d) otherwise, if you really wants to use an existing /odf cache (with
- possibly some stale info), then use options "remount,odfforce". (We may
- want to not implement "odfforce" initially, and see exactly what needs
- to be purged or kept upon odfforce. Besides, "odfforce" may only lead
- to trouble, so why risk it?)
-
+ possibly some stale info), then use options "remount,odfforce".
** Whiteouts and Opaque Dir actions
@@ -324,6 +315,8 @@ The above lookup procedure is further modified to handle
hard-links
remaining ones, and create wh; return "OK" but we may want to printk on
EIO or some other serious errors; if wh creation failed, return error.
+# XXX: need to handle hardlinks and unlinks
+
> is_empty(char * dir) utility function:
- checks if dir is logically empty or not
_______________________________________________
unionfs-cvs mailing list: http://unionfs.filesystems.org/
[email protected]
http://www.fsl.cs.sunysb.edu/mailman/listinfo/unionfs-cvs