f2fs: avoid wrong decrypted data from disk
authorJaegeuk Kim <jaegeuk@kernel.org>
Thu, 23 Aug 2018 04:18:00 +0000 (21:18 -0700)
committerPDO SCM Team <hudsoncm@motorola.com>
Wed, 8 Apr 2020 13:51:38 +0000 (08:51 -0500)
commitb446e678e4d8702fdadacf830bd39369ad51fd40
tree64a38cc04c6abf75c3fdaca200fb4b7e99c57232
parent7a406afe792372bcea6189a9f3dda07c0844e1ff
f2fs: avoid wrong decrypted data from disk

1. Create a file in an encrypted directory
2. Do GC & drop caches
3. Read stale data before its bio for metapage was not issued yet

Mot-CRs-fixed: (CR)

Reviewed-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Git-commit: 0ded69f632bb717be9aeea3ae74e29050fcb060c
Git-repo: https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git/
[stummala@codeaurora.org: Back port the change]
Signed-off-by: Sahitya Tummala <stummala@codeaurora.org>
Signed-off-by: Jignesh Patel <jignesh@motorola.com>
Change-Id: I6ca2ad656efd230b20caa2240e681dbb9f145394
Reviewed-on: https://gerrit.mot.com/1526092
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Submit-Approved: Jira Key
fs/f2fs/data.c
fs/f2fs/f2fs.h
fs/f2fs/file.c
fs/f2fs/segment.c