tree: 4116e041de7bce5b483552fd519d198379fd5477 [path history] [tgz]
  1. test/
  2. third_party/
  3. admin.cc
  4. admin.h
  5. bcache.cc
  6. bcache.h
  7. BUILD.gn
  8. checkpoint.cc
  9. data.cc
  10. dir.cc
  11. dir.h
  12. dir_entry_cache.cc
  13. dir_entry_cache.h
  14. dir_hash.cc
  15. f2fs.cc
  16. f2fs.h
  17. f2fs_internal.h
  18. f2fs_layout.h
  19. f2fs_lib.h
  20. f2fs_types.h
  21. file.cc
  22. file.h
  23. file_cache.cc
  24. file_cache.h
  25. fsck.cc
  26. fsck.h
  27. gc.cc
  28. inline.cc
  29. inspect.cc
  30. inspect.h
  31. mkfs.cc
  32. mkfs.h
  33. mount.cc
  34. mount.h
  35. namei.cc
  36. namestring.h
  37. node.cc
  38. node.h
  39. node_page.cc
  40. node_page.h
  41. README.md
  42. recovery.cc
  43. segment.cc
  44. segment.h
  45. super.cc
  46. sync_host.cc
  47. sync_host.h
  48. vmo_manager.cc
  49. vmo_manager.h
  50. vnode.cc
  51. vnode.h
  52. vnode_cache.cc
  53. vnode_cache.h
  54. writeback.cc
  55. writeback.h
src/storage/f2fs/README.md

What is F2FS?

F2FS is the most commonly used log-structured file system in Linux. It supports flash-friendly features such as adaptive logging, multi-head logging, fsync acceleration, and node address translation. For more information see: https://www.usenix.org/conference/fast15/technical-sessions/presentation/lee

Limitations

  • Features under development: mmap(shared), gc, xattr, fallocate
  • We use LFS for new blocks but enforce SSR/IPU for rewritten blocks until gc is available.

How to test

Fuchsia filesystem tests

  • Build configuration for fs-tests (femu runs with f2fs data partition if you add --args=‘data_filesystem_format=“f2fs”’)

$ fx set core.x64 --with-base //src/storage/f2fs:tests

  • Run Fuchsia filesystem test suite with f2fs (slow-fs-tests can take more than 5 minutes.)

$ fx test f2fs-fs-tests f2fs-slow-fs-tests

  • Only run f2fs unit tests

$ fx test f2fs-unittest

Linux compatibility tests (EXPERIMENTAL)

  • Prerequisite

Linux kernel built with f2fs $ apt install f2fs-tools (on Debian/Ubuntu)

  • Build configuration for fs-tests

$ fx set core.x64 --with-base //src/storage/f2fs/test/compatibility:f2fs-compatibility-tests

  • Run Linux compatibility tests

$ fx test f2fs-compatibility-test