Lines Matching refs:root
256 ffs_makefs(const char *image, const char *dir, fsnode *root, fsinfo_t *fsopts)
263 assert(root != NULL);
267 printf("ffs_makefs: image %s directory %s root %p\n",
268 image, dir, root);
277 ffs_validate(dir, root, fsopts);
297 if (! ffs_populate_dir(dir, root, fsopts))
325 ffs_validate(const char *dir, fsnode *root, fsinfo_t *fsopts)
334 assert(root != NULL);
381 ffs_size_dir(root, fsopts);
594 ffs_size_dir(fsnode *root, fsinfo_t *fsopts)
632 for (node = root; node != NULL; node = node->next) {
634 if (node == root) { /* we're at "." */
669 fsnode *root, fsinfo_t *fsopts)
697 if (cur == root) { /* "."; write dirbuf */
717 fsnode *root, fsinfo_t *fsopts)
756 if (cur == root) { /* "."; write dirbuf */
775 ffs_populate_dir(const char *dir, fsnode *root, fsinfo_t *fsopts)
785 assert(root != NULL);
792 printf("ffs_populate_dir: PASS 1 dir %s node %p\n", dir, root);
797 for (cur = root; cur != NULL; cur = cur->next) {
800 if (cur == root && cur->parent != NULL)
808 if (cur == root) { /* we're at "."; add ".." */
812 root->inode->nlink++; /* count my parent's link */
814 root->inode->nlink++; /* count my child's link */
831 for (cur = root; cur != NULL; cur = cur->next) {
837 if (snprintf(path, sizeof(path), "%s/%s/%s", cur->root,
848 root, fsopts);
851 root, fsopts);
877 for (cur = root; cur != NULL; cur = cur->next) {