- Pass 1: Scan the directory tree, increasing nlink according to every dirent found.
- Pass 2: Scan for inodes with nlink == 0 and remove them. If they were directories, then decrement the nlink of
their children too, and repeat the scan. (jffs2_free_full_dirent, jffs2_mark_node_obsolate)
- Pass 3: Scan again and free the dirent structs.
Havasi Ferenc
2005-12-22