[PATCH 00/23] Implement basic file system operations

Valerie Aurora val at versity.com
Fri Apr 4 11:45:16 PDT 2025


This patch series implements most of the remaining basic file system
operations:

 * mkdir/rmdir/unlink/lookup/rename
 * file data
 * (short) extended attributes

Additional extras include:

 * conversion to inode number plus generation
 * improved debugfs output
 * some documentation
 * minor bug fixes
 * temporary hack to allow client disconnect from devd

Changes since last version:

This series should address 100% of the comments from the last code
review; if it's not in here, that's my mistake. rename() and
setxattr() replace now use the btree replace operation. The rename()
bug of writing to a read-only inode is fixed. A bunch of flag names
are shorter. debugfs output includes file size. debugfs error
reporting is now consistently formatted.

As usual, take the patches you like and I'll fix up the rest! In
particular, the hack for client disconnect can live in my branch until
I get mapd doing this correctly.

Valerie

Auke Kok (1):
  Insert \n before cmd output when input is not a tty

Chris Kirby (1):
  Fix null dereference in socket_recv_thread()

Valerie Aurora (21):
  Improve naming of dtype code
  Send quit signal to process, not process group
  Don't overwrite op.val_size on btree delete
  Add brief instructions on how to run ngnfs
  Move inode number and generation into ino_gen struct
  Add i_size to debugfs stat output
  Add parent inode number/generation for directories
  Add auto-generated "." and ".." entries to directories
  Consolidate error printing in debugfs
  Add ngnfs_dir_lookup() and debugfs lookup command
  Extend debugfs stat command to take an optional file name
  Add the cd command to debugfs
  Add ngnfs_dir_mkdir() and debugfs command
  Add ngnfs_dir_unlink(), ngnfs_dir_rmdir(), and debugfs commands
  Add ngnfs_dir_rename() and very basic debugfs command
  Add rename benchmark command to debugfs
  Add create benchmark command to debugfs
  Add set/get/remove xattrs with up to 503 bytes of name + value
  Add ngnfs_xattr_list() and debugfs command
  Add file data and debugfs read/write commands
  Temporary hack to remove cache state on client disconnect

 README.md             |   7 +-
 cli/debugfs.c         | 622 +++++++++++++++++++++++++++++++++++++--
 devd/cache-mode.c     |  25 ++
 devd/cache-mode.h     |   1 +
 devd/ngnfs-devd.c     |   3 +-
 docs/development.md   |  31 ++
 shared/btree.c        |   4 +-
 shared/data.c         | 495 +++++++++++++++++++++++++++++++
 shared/data.h         |  13 +
 shared/dir.c          | 664 +++++++++++++++++++++++++++++++++++++++---
 shared/dir.h          |  38 ++-
 shared/format-block.h |  61 +++-
 shared/inode.c        |  83 ++++--
 shared/inode.h        |  21 +-
 shared/lk/xattr.h     |  10 +
 shared/mkfs.c         |   5 +-
 shared/mtr-socket.c   |   4 +-
 shared/xattr.c        | 432 +++++++++++++++++++++++++++
 shared/xattr.h        |  16 +
 utask/net.c           |   9 +-
 utask/net.h           |   3 +-
 21 files changed, 2432 insertions(+), 115 deletions(-)
 create mode 100644 shared/data.c
 create mode 100644 shared/data.h
 create mode 100644 shared/lk/xattr.h
 create mode 100644 shared/xattr.c
 create mode 100644 shared/xattr.h

-- 
2.48.1




More information about the ngnfs-devel mailing list