FROMGIT: f2fs: flush data when enabling checkpoint back

During checkpoint=disable period, f2fs bypasses all the synchronous IOs such as
sync and fsync. So, when enabling it back, we must flush all of them in order
to keep the data persistent. Otherwise, suddern power-cut right after enabling
checkpoint will cause data loss.

Bug: 171063590
Fixes: 4354994f097d ("f2fs: checkpoint disabling")
Cc: stable@vger.kernel.org
Reviewed-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
(cherry picked from commit 8d52dbb373579b48f5758dd0cdd2ac0fb4e5be7f git://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git dev)
Signed-off-by: Jaegeuk Kim <jaegeuk@google.com>
Change-Id: Iaca2d6fc1841fffa8677d5d592732c94241fb3fb
(cherry picked from commit e39210f0cc71f9bab72fb7517d1b58738dfaed86)
1 file changed
tree: d7bd3a9bd5202fa525caa9e896d7ef0df34b25f9
  1. arch/
  2. block/
  3. certs/
  4. crypto/
  5. Documentation/
  6. drivers/
  7. firmware/
  8. fs/
  9. include/
  10. init/
  11. ipc/
  12. kernel/
  13. lib/
  14. mm/
  15. net/
  16. samples/
  17. scripts/
  18. security/
  19. sound/
  20. techpack/
  21. test/
  22. tools/
  23. usr/
  24. virt/
  25. .clang-format
  26. .cocciconfig
  27. .get_maintainer.ignore
  28. .gitattributes
  29. .gitignore
  30. .mailmap
  31. Androidbp
  32. AndroidKernel.mk
  33. build.config
  34. build.config.aarch64
  35. build.config.boundsan
  36. build.config.common
  37. build.config.common.clang
  38. build.config.cuttlefish.aarch64
  39. build.config.cuttlefish.x86_64
  40. build.config.debug_api
  41. build.config.debug_hang
  42. build.config.debug_locking
  43. build.config.debug_memory
  44. build.config.floral
  45. build.config.floral.common
  46. build.config.floral.common.clang
  47. build.config.floral_debug_api
  48. build.config.floral_debug_hang
  49. build.config.floral_debug_locking
  50. build.config.floral_debug_memory
  51. build.config.floral_kasan
  52. build.config.floral_khwasan
  53. build.config.floral_no-cfi
  54. build.config.floral_performance
  55. build.config.gcc
  56. build.config.goldfish.arm
  57. build.config.goldfish.arm64
  58. build.config.goldfish.mips
  59. build.config.goldfish.mips64
  60. build.config.goldfish.x86
  61. build.config.goldfish.x86_64
  62. build.config.kasan
  63. build.config.khwasan
  64. build.config.no-cfi
  65. build.config.performance
  66. build.config.sunfish
  67. build.config.sunfish.common
  68. build.config.sunfish.common.clang
  69. build.config.sunfish_debug_api
  70. build.config.sunfish_debug_hang
  71. build.config.sunfish_debug_locking
  72. build.config.sunfish_debug_memory
  73. build.config.sunfish_kasan
  74. build.config.sunfish_khwasan
  75. build.config.sunfish_no-cfi
  76. build.config.sunfish_performance
  77. build_floral.sh
  78. build_sunfish.sh
  79. COPYING
  80. CREDITS
  81. gen_headers_arm.bp
  82. gen_headers_arm64.bp
  83. Kbuild
  84. Kconfig
  85. kernel_headers.py
  86. MAINTAINERS
  87. Makefile
  88. OWNERS
  89. PREUPLOAD.cfg
  90. README
  91. verity_dev_keys.x509