fsdax: factor out helpers to simplify the dax fault code
authorShiyang Ruan <ruansy.fnst@fujitsu.com>
Wed, 11 Aug 2021 01:33:14 +0000 (18:33 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Tue, 17 Aug 2021 04:26:33 +0000 (21:26 -0700)
commit55f81639a7152848f204f9af3f9b1a14a5944be1
tree1efee336396bed26834ef8aa48f0288b3b6ae069
parentb74b1293e6cae70bade491067f15b9d33e040cad
fsdax: factor out helpers to simplify the dax fault code

The dax page fault code is too long and a bit difficult to read. And it
is hard to understand when we trying to add new features. Some of the
PTE/PMD codes have similar logic. So, factor out helper functions to
simplify the code.

Signed-off-by: Shiyang Ruan <ruansy.fnst@fujitsu.com>
Reviewed-by: Ritesh Harjani <riteshh@linux.ibm.com>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
[hch: minor cleanups]
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
fs/dax.c