在 2024/2/27 0:58, Dan Williams 写道:
Shiyang Ruan wrote:
在 2024/1/12 10:21, Darrick J. Wong 写道:
On Thu, Jan 11, 2024 at 10:59:21AM -0600, Bill O'Donnell wrote:
On Fri, Sep 15, 2023 at 02:38:54PM +0800, Shiyang Ruan wrote:
FSDAX and reflink can work together now, let's drop this warning
在 2024/1/12 10:21, Darrick J. Wong 写道:
On Thu, Jan 11, 2024 at 10:59:21AM -0600, Bill O'Donnell wrote:
On Fri, Sep 15, 2023 at 02:38:54PM +0800, Shiyang Ruan wrote:
FSDAX and reflink can work together now, let's drop this warning.
Signed-off-by: Shiyang Ruan
Are there any updates
在 2024/1/4 20:26, Jan Kara 写道:
On Thu 04-01-24 18:49:25, Shiyang Ruan wrote:
Restore the tracepoint that was accidentally deleted before, and rename
to dax_insert_entry(). Also, since we are using XArray, rename
'radix_entry' to 'xa_entry'.
Signed-off-by: Shiyang Ruan
Looks good. Feel
在 2024/1/12 6:24, Bill O'Donnell 写道:
On Thu, Jun 29, 2023 at 04:16:49PM +0800, Shiyang Ruan wrote:
This patchset is to add gracefully unbind support for pmem.
Patch1 corrects the calculation of length and end of a given range.
Patch2 introduces a new flag call MF_MEM_REMOVE, to let dax
Restore the tracepoint that was accidentally deleted before, and rename
to dax_insert_entry(). Also, since we are using XArray, rename
'radix_entry' to 'xa_entry'.
Signed-off-by: Shiyang Ruan
---
fs/dax.c | 2 ++
include/trace/events/fs_dax.h | 47
在 2023/10/23 14:40, Chandan Babu R 写道:
On Fri, Oct 20, 2023 at 08:40:09 AM -0700, Darrick J. Wong wrote:
On Fri, Oct 20, 2023 at 03:26:32PM +0530, Chandan Babu R wrote:
On Thu, Sep 28, 2023 at 06:32:27 PM +0800, Shiyang Ruan wrote:
Changes since v14:
1. added/fixed code comments
orrectly. Also drop the cache of associated files before
pmem is removed.
[1]:
https://lore.kernel.org/linux-mm/161604050314.1463742.14151665140035795571.st...@dwillia2-desk3.amr.corp.intel.com/
[2]:
https://lore.kernel.org/linux-xfs/169116275623.3187159.16862410128731457358.stg-ugh@frogsfrogsfrogs
在 2023/10/10 0:47, Darrick J. Wong 写道:
On Mon, Oct 09, 2023 at 10:14:12PM +0800, Shiyang Ruan wrote:
在 2023/10/6 0:05, Darrick J. Wong 写道:
On Thu, Oct 05, 2023 at 04:53:12PM +0800, Shiyang Ruan wrote:
在 2023/10/5 8:08, Darrick J. Wong 写道:
Sorry, I sent the list below to Chandan
在 2023/10/6 0:05, Darrick J. Wong 写道:
On Thu, Oct 05, 2023 at 04:53:12PM +0800, Shiyang Ruan wrote:
在 2023/10/5 8:08, Darrick J. Wong 写道:
Sorry, I sent the list below to Chandan, didn't cc the maillist
because it's just a rough list rather than a PR:
1. subject: [v3] xfs: correct
在 2023/10/5 8:08, Darrick J. Wong 写道:
Sorry, I sent the list below to Chandan, didn't cc the maillist
because it's just a rough list rather than a PR:
1. subject: [v3] xfs: correct calculation for agend and blockcount
url:
在 2023/9/30 2:34, Dan Williams 写道:
Shiyang Ruan wrote:
在 2023/9/29 1:13, Darrick J. Wong 写道:
On Thu, Sep 28, 2023 at 09:20:52AM -0700, Andrew Morton wrote:
On Thu, 28 Sep 2023 16:44:00 +0800 Shiyang Ruan wrote:
But please pick the following patch[1] as well, which fixes failures
在 2023/10/1 9:43, kernel test robot 写道:
Hi Shiyang,
kernel test robot noticed the following build errors:
url:
https://github.com/intel-lab-lkp/linux/commits/UPDATE-20230928-183310/Shiyang-Ruan/xfs-fix-the-calculation-for-end-and-length/20230629-161913
base: the 2th patch of
https
在 2023/9/29 1:13, Darrick J. Wong 写道:
On Thu, Sep 28, 2023 at 09:20:52AM -0700, Andrew Morton wrote:
On Thu, 28 Sep 2023 16:44:00 +0800 Shiyang Ruan wrote:
But please pick the following patch[1] as well, which fixes failures of
xfs55[0-2] cases.
[1]
https://lore.kernel.org/linux-xfs
t progress)
are handled correctly. Also drop the cache of associated files before
pmem is removed.
[1]:
https://lore.kernel.org/linux-mm/161604050314.1463742.14151665140035795571.st...@dwillia2-desk3.amr.corp.intel.com/
[2]:
https://lore.kernel.org/linux-xfs/169116275623.3187159.16862410128
在 2023/9/27 23:30, Andrew Morton 写道:
On Wed, 27 Sep 2023 13:01:25 +0530 Chandan Babu R
wrote:
在 2023/9/27 13:17, Shiyang Ruan 写道:
在 2023/9/27 11:38, Chandan Babu R 写道:
On Tue, Sep 26, 2023 at 06:46:32 PM -0700, Darrick J. Wong wrote:
On Wed, Sep 27, 2023 at 11:18:42AM +1000, Dave
在 2023/9/27 16:17, Dan Williams 写道:
Shiyang Ruan wrote:
Changes since v13:
1. don't return error if _freeze(FREEZE_HOLDER_KERNEL) got other error
Now, if we suddenly remove a PMEM device(by calling unbind) which
contains FSDAX while programs are still accessing data
在 2023/9/27 13:17, Shiyang Ruan 写道:
在 2023/9/27 11:38, Chandan Babu R 写道:
On Tue, Sep 26, 2023 at 06:46:32 PM -0700, Darrick J. Wong wrote:
On Wed, Sep 27, 2023 at 11:18:42AM +1000, Dave Chinner wrote:
On Tue, Sep 26, 2023 at 07:55:19AM -0700, Darrick J. Wong wrote:
On Thu, Sep 21, 2023
在 2023/9/27 11:38, Chandan Babu R 写道:
On Tue, Sep 26, 2023 at 06:46:32 PM -0700, Darrick J. Wong wrote:
On Wed, Sep 27, 2023 at 11:18:42AM +1000, Dave Chinner wrote:
On Tue, Sep 26, 2023 at 07:55:19AM -0700, Darrick J. Wong wrote:
On Thu, Sep 21, 2023 at 04:33:04PM +0800, Shiyang Ruan
Hi,
Any comments?
--
Thanks,
Ruan.
在 2023/9/15 14:38, Shiyang Ruan 写道:
FSDAX and reflink can work together now, let's drop this warning.
Signed-off-by: Shiyang Ruan
---
fs/xfs/xfs_super.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/fs/xfs/xfs_super.c b/fs/xfs/xfs_super.c
index
FSDAX and reflink can work together now, let's drop this warning.
Signed-off-by: Shiyang Ruan
---
fs/xfs/xfs_super.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/fs/xfs/xfs_super.c b/fs/xfs/xfs_super.c
index 1f77014c6e1a..faee773fa026 100644
--- a/fs/xfs/xfs_super.c
+++ b/fs/xfs
nd processes(not only the current progress)
are handled correctly. Also drop the cache of associated files before
pmem is removed.
[1]:
https://lore.kernel.org/linux-mm/161604050314.1463742.14151665140035795571.st...@dwillia2-desk3.amr.corp.intel.com/
[2]:
https://lore.kernel.org/linux-xfs/16911627
在 2023/8/25 7:57, Darrick J. Wong 写道:
On Thu, Aug 24, 2023 at 05:41:50PM +0800, Shiyang Ruan wrote:
在 2023/8/24 7:36, Darrick J. Wong 写道:
On Wed, Aug 23, 2023 at 04:17:06PM +0800, Shiyang Ruan wrote:
Changes since v12:
1. correct flag name in subject (MF_MEM_REMOVE
在 2023/8/24 7:36, Darrick J. Wong 写道:
On Wed, Aug 23, 2023 at 04:17:06PM +0800, Shiyang Ruan wrote:
Changes since v12:
1. correct flag name in subject (MF_MEM_REMOVE => MF_MEM_PRE_REMOVE)
2. complete the behavior when fs has already frozen by kernel call
NOTICE: Inst
在 2023/8/8 8:31, Dan Williams 写道:
Shiyang Ruan wrote:
This patch is inspired by Dan's "mm, dax, pmem: Introduce
dev_pagemap_failure()"[1]. With the help of dax_holder and
->notify_failure() mechanism, the pmem driver is able to ask filesystem
on it to unmap all files in us
4151665140035795571.st...@dwillia2-desk3.amr.corp.intel.com/
[2]:
https://lore.kernel.org/linux-xfs/169116275623.3187159.16862410128731457358.stg-ugh@frogsfrogsfrogs/
Signed-off-by: Shiyang Ruan
---
drivers/dax/super.c | 3 +-
fs/xfs/xfs_notify_failure.c | 99 ++---
在 2023/8/1 11:25, Darrick J. Wong 写道:
On Mon, Jul 31, 2023 at 05:36:36PM +0800, Shiyang Ruan wrote:
在 2023/7/29 23:15, Darrick J. Wong 写道:
On Thu, Jun 29, 2023 at 04:16:51PM +0800, Shiyang Ruan wrote:
This patch is inspired by Dan's "mm, dax, pmem: Introduce
dev_pagemap_failure
在 2023/7/29 23:15, Darrick J. Wong 写道:
On Thu, Jun 29, 2023 at 04:16:51PM +0800, Shiyang Ruan wrote:
This patch is inspired by Dan's "mm, dax, pmem: Introduce
dev_pagemap_failure()"[1]. With the help of dax_holder and
->notify_failure() mechanism, the pmem driver is able to a
在 2023/7/20 9:50, Shiyang Ruan 写道:
在 2023/7/14 22:18, Darrick J. Wong 写道:
On Fri, Jul 14, 2023 at 05:07:58PM +0800, Shiyang Ruan wrote:
Hi Darrick,
Thanks for applying the 1st patch.
Now, since this patch is based on the new freeze_super()/thaw_super()
api[1], I'd like to ask what's
在 2023/7/25 6:47, Alison Schofield 写道:
On Wed, Jul 19, 2023 at 04:05:26PM +0800, Shiyang Ruan wrote:
The first for_each only do acpi_nfit_init_ars() for NFIT_SPA_VOLATILE
and NFIT_SPA_PM, which can be moved to next one.
Can the result of nfit_spa_type(nfit_spa->spa) change as a res
在 2023/7/14 22:18, Darrick J. Wong 写道:
On Fri, Jul 14, 2023 at 05:07:58PM +0800, Shiyang Ruan wrote:
Hi Darrick,
Thanks for applying the 1st patch.
Now, since this patch is based on the new freeze_super()/thaw_super()
api[1], I'd like to ask what's the plan for this api? It seems to have
The first for_each only do acpi_nfit_init_ars() for NFIT_SPA_VOLATILE
and NFIT_SPA_PM, which can be moved to next one.
Signed-off-by: Shiyang Ruan
---
drivers/acpi/nfit/core.c | 8
1 file changed, 8 deletions(-)
diff --git a/drivers/acpi/nfit/core.c b/drivers/acpi/nfit/core.c
index
.stgit@frogsfrogsfrogs/
--
Thanks,
Ruan.
在 2023/6/29 16:16, Shiyang Ruan 写道:
This patch is inspired by Dan's "mm, dax, pmem: Introduce
dev_pagemap_failure()"[1]. With the help of dax_holder and
->notify_failure() mechanism, the pmem driver is able to ask filesystem
on it to un
/linux-xfs/168688010689.860947.1788875898367401950.stgit@frogsfrogsfrogs/
Signed-off-by: Shiyang Ruan
---
drivers/dax/super.c | 3 +-
fs/xfs/xfs_notify_failure.c | 86 ++---
include/linux/mm.h | 1 +
mm/memory-failure.c | 17 ++--
4 file
The value of "end" should be "start + length - 1".
Signed-off-by: Shiyang Ruan
Reviewed-by: Darrick J. Wong
---
fs/xfs/xfs_notify_failure.c | 9 +
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/fs/xfs/xfs_notify_failure.c b/fs/xfs/xfs_notify_failure.
the filesystem on the pmem gracefully.
Changes since v11:
Patch1:
1. correct the count calculation in xfs_failure_pgcnt().
(was a wrong fix in v11)
Patch2:
1. use new exclusive freeze_super/thaw_super API, to make sure the unbind
progress won't be disturbed by any other freezer.
Shiyang
在 2023/4/25 23:18, Darrick J. Wong 写道:
On Tue, Apr 25, 2023 at 03:23:15PM +0200, Jan Kara wrote:
On Tue 25-04-23 20:47:35, Shiyang Ruan wrote:
在 2023/4/20 20:09, Jan Kara 写道:
On Thu 20-04-23 10:07:39, Shiyang Ruan wrote:
在 2023/4/12 18:52, Shiyang Ruan 写道:
This is a RFC HOTFIX
在 2023/4/20 20:09, Jan Kara 写道:
On Thu 20-04-23 10:07:39, Shiyang Ruan wrote:
在 2023/4/12 18:52, Shiyang Ruan 写道:
This is a RFC HOTFIX.
This hotfix adds a exclusive forzen state to make sure any others won't
thaw the fs during xfs_dax_notify_failure():
#define SB_FREEZE_EXCLUSIVE
Ping~
在 2023/4/12 18:52, Shiyang Ruan 写道:
This is a RFC HOTFIX.
This hotfix adds a exclusive forzen state to make sure any others won't
thaw the fs during xfs_dax_notify_failure():
#define SB_FREEZE_EXCLUSIVE (SB_FREEZE_COMPLETE + 2)
Using +2 here is because Darrick's patch[0] is using +1
ssociated files before pmem is
removed.
[1]:
https://lore.kernel.org/linux-mm/161604050314.1463742.14151665140035795571.st...@dwillia2-desk3.amr.corp.intel.com/
Signed-off-by: Shiyang Ruan
---
drivers/dax/super.c | 3 +-
fs/xfs/xfs_notify_failure.c | 151
在 2023/4/6 22:54, Darrick J. Wong 写道:
On Thu, Apr 06, 2023 at 06:50:22PM +0800, Shiyang Ruan wrote:
在 2023/4/5 1:45, Darrick J. Wong 写道:
On Tue, Mar 28, 2023 at 09:41:46AM +, Shiyang Ruan wrote:
This patch is inspired by Dan's "mm, dax, pmem: Introduce
dev_pagemap_failure
在 2023/4/5 1:45, Darrick J. Wong 写道:
On Tue, Mar 28, 2023 at 09:41:46AM +, Shiyang Ruan wrote:
This patch is inspired by Dan's "mm, dax, pmem: Introduce
dev_pagemap_failure()"[1]. With the help of dax_holder and
->notify_failure() mechanism, the pmem driver is able to a
Ping
在 2023/3/28 17:41, Shiyang Ruan 写道:
This patchset is to add gracefully unbind support for pmem.
Patch1 corrects the calculation of length and end of a given range.
Patch2 introduces a new flag call MF_MEM_REMOVE, to let dax holder know
it is a remove event. With the help of notify_failure
is removed.
[1]:
https://lore.kernel.org/linux-mm/161604050314.1463742.14151665140035795571.st...@dwillia2-desk3.amr.corp.intel.com/
Signed-off-by: Shiyang Ruan
---
drivers/dax/super.c | 3 +-
fs/xfs/xfs_notify_failure.c | 56 +
include/linux/mm.h | 1 +
mm/memory-fai
have to be disassociated but now the pmem is not
exist.
For detail analysis of this change, please refer this link[1].
[1]
https://lore.kernel.org/linux-xfs/b1d9fc03-1a71-a75f-f87b-5819991e4...@fujitsu.com/
Shiyang Ruan (2):
xfs: fix the calculation of length and end
mm, pmem, xfs
The end should be start + length - 1. Also fix the calculation of the
length when seeking for intersection of notify range and device.
Signed-off-by: Shiyang Ruan
Reviewed-by: Darrick J. Wong
---
fs/xfs/xfs_notify_failure.c | 10 +-
1 file changed, 5 insertions(+), 5 deletions
在 2023/3/25 3:42, Andrew Morton 写道:
On Fri, 24 Mar 2023 10:28:00 + Shiyang Ruan wrote:
XFS allows CoW on non-shared extents to combat fragmentation[1]. The
old non-shared extent could be mwrited before, its dax entry is marked
dirty. To be able to delete this entry, clear its dirty
.GA11376@frogsfrogsfrogs/
Signed-off-by: Shiyang Ruan
---
fs/dax.c | 37 +
1 file changed, 37 insertions(+)
diff --git a/fs/dax.c b/fs/dax.c
index 5d2e9b10030e..2ababb89918d 100644
--- a/fs/dax.c
+++ b/fs/dax.c
@@ -781,6 +781,33 @@ static int
在 2023/3/21 18:59, Shiyang Ruan 写道:
在 2023/2/27 18:06, Shiyang Ruan 写道:
在 2023/2/27 8:07, Dave Chinner 写道:
On Fri, Feb 17, 2023 at 02:48:32PM +, Shiyang Ruan wrote:
This patch is inspired by Dan's "mm, dax, pmem: Introduce
dev_pagemap_failure()"[1]. With the help of
在 2023/3/24 12:17, Matthew Wilcox 写道:
On Fri, Mar 24, 2023 at 11:42:53AM +0800, Shiyang Ruan wrote:
在 2023/3/24 11:33, Matthew Wilcox 写道:
On Fri, Mar 24, 2023 at 09:50:54AM +0800, Shiyang Ruan wrote:
在 2023/3/24 6:11, Andrew Morton 写道:
On Thu, 23 Mar 2023 14:50:38 +0800 Shiyang Ruan
在 2023/3/24 6:12, Andrew Morton 写道:
On Thu, 23 Mar 2023 14:48:25 +0800 Shiyang Ruan wrote:
在 2023/3/23 7:12, Andrew Morton 写道:
On Wed, 22 Mar 2023 07:25:58 + Shiyang Ruan wrote:
In an dedupe corporation iter loop, the length of iomap_iter decreases
because it implies
在 2023/3/24 11:33, Matthew Wilcox 写道:
On Fri, Mar 24, 2023 at 09:50:54AM +0800, Shiyang Ruan wrote:
在 2023/3/24 6:11, Andrew Morton 写道:
On Thu, 23 Mar 2023 14:50:38 +0800 Shiyang Ruan wrote:
在 2023/3/23 7:03, Andrew Morton 写道:
On Wed, 22 Mar 2023 11:11:09 + Shiyang Ruan wrote
在 2023/3/24 6:11, Andrew Morton 写道:
On Thu, 23 Mar 2023 14:50:38 +0800 Shiyang Ruan wrote:
在 2023/3/23 7:03, Andrew Morton 写道:
On Wed, 22 Mar 2023 11:11:09 + Shiyang Ruan wrote:
unshare copies data from source to destination. But if the source is
HOLE or UNWRITTEN extents, we
在 2023/3/23 7:03, Andrew Morton 写道:
On Wed, 22 Mar 2023 11:11:09 + Shiyang Ruan wrote:
unshare copies data from source to destination. But if the source is
HOLE or UNWRITTEN extents, we should zero the destination, otherwise the
result will be unexpectable.
Please provide much more
在 2023/3/23 7:12, Andrew Morton 写道:
On Wed, 22 Mar 2023 07:25:58 + Shiyang Ruan wrote:
In an dedupe corporation iter loop, the length of iomap_iter decreases
because it implies the remaining length after each iteration. The
compare function should use the min length of the current
unshare copies data from source to destination. But if the source is
HOLE or UNWRITTEN extents, we should zero the destination, otherwise the
result will be unexpectable.
Fixes: d984648e428b ("fsdax,xfs: port unshare to fsdax")
Signed-off-by: Shiyang Ruan
---
fs/dax.c | 11 -
time")
Signed-off-by: Shiyang Ruan
---
fs/dax.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fs/dax.c b/fs/dax.c
index 3e457a16c7d1..9800b93ee14d 100644
--- a/fs/dax.c
+++ b/fs/dax.c
@@ -2022,8 +2022,8 @@ int dax_dedupe_file_range_compare(struct inode *src,
lof
在 2023/2/27 18:06, Shiyang Ruan 写道:
在 2023/2/27 8:07, Dave Chinner 写道:
On Fri, Feb 17, 2023 at 02:48:32PM +, Shiyang Ruan wrote:
This patch is inspired by Dan's "mm, dax, pmem: Introduce
dev_pagemap_failure()"[1]. With the help of dax_holder and
->notify_failure() mechan
在 2023/2/27 8:07, Dave Chinner 写道:
On Fri, Feb 17, 2023 at 02:48:32PM +, Shiyang Ruan wrote:
This patch is inspired by Dan's "mm, dax, pmem: Introduce
dev_pagemap_failure()"[1]. With the help of dax_holder and
->notify_failure() mechanism, the pmem driver is able to a
在 2023/2/21 5:25, Dave Chinner 写道:
On Fri, Feb 17, 2023 at 02:48:31PM +, Shiyang Ruan wrote:
xfs_notify_failure.c requires a method to invalidate all dax mappings.
drop_pagecache_sb() can do this but it is a static function and only
build with CONFIG_SYSCTL. Now, move its implementation
在 2023/2/20 17:39, Shiyang Ruan 写道:
在 2023/2/19 2:27, Matthew Wilcox 写道:
On Sat, Feb 18, 2023 at 09:16:43AM +0800, Shiyang Ruan wrote:
在 2023/2/18 0:14, Matthew Wilcox 写道:
On Fri, Feb 17, 2023 at 02:48:31PM +, Shiyang Ruan wrote:
- invalidate_mapping_pages(inode->i_mapping
在 2023/2/19 2:27, Matthew Wilcox 写道:
On Sat, Feb 18, 2023 at 09:16:43AM +0800, Shiyang Ruan wrote:
在 2023/2/18 0:14, Matthew Wilcox 写道:
On Fri, Feb 17, 2023 at 02:48:31PM +, Shiyang Ruan wrote:
- invalidate_mapping_pages(inode->i_mapping, 0, -1);
- i
在 2023/2/18 0:14, Matthew Wilcox 写道:
On Fri, Feb 17, 2023 at 02:48:31PM +, Shiyang Ruan wrote:
- invalidate_mapping_pages(inode->i_mapping, 0, -1);
- iput(toput_inode);
- toput_inode = inode;
-
- cond_resc
can choose which invalidate method to use.
Signed-off-by: Shiyang Ruan
---
fs/drop_caches.c| 29 +--
fs/super.c | 43 +
include/linux/fs.h | 2 ++
include/linux/pagemap.h | 1 +
mm/truncate.c | 20
5140035795571.st...@dwillia2-desk3.amr.corp.intel.com/
Signed-off-by: Shiyang Ruan
---
drivers/dax/super.c | 3 ++-
fs/xfs/xfs_notify_failure.c | 26 ++
include/linux/mm.h | 1 +
3 files changed, 29 insertions(+), 1 deletion(-)
diff --git a/drivers/dax/s
The end should be start + length - 1. Also fix the calculation of the
length when seeking for intersection of notify range and device.
Signed-off-by: Shiyang Ruan
Reviewed-by: Darrick J. Wong
---
fs/xfs/xfs_notify_failure.c | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff
ore invalidate dax mapping
Shiyang Ruan (3):
xfs: fix the calculation of length and end
fs: introduce super_drop_pagecache()
mm, pmem, xfs: Introduce MF_MEM_REMOVE for unbind
drivers/dax/super.c | 3 ++-
fs/drop_caches.c| 29 +
fs/supe
The copy_mc_to_kernel() will return 0 if it executed successfully.
Then the return value should be set to the length it copied.
Fixes: d984648e428b ("fsdax,xfs: port unshare to fsdax")
Signed-off-by: Shiyang Ruan
---
fs/dax.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletion
The copy_mc_to_kernel() will return 0 if it executed successfully.
Then the return value should be set to the length it copied.
Fixes: d984648e428b ("fsdax,xfs: port unshare to fsdax")
Signed-off-by: Shiyang Ruan
---
fs/dax.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/fs/
to copy the head and tail ranges which is
outside of the non-aligned area instead of copying the whole aligned
range. But in dax page fault, it will always be an aligned range. So,
we have to copy the whole range in this case.
Signed-off-by: Shiyang Ruan
Reviewed-by: Christoph Hellwig
Reviewed
Add address output in dax_iomap_pfn() in order to perform a memcpy() in
CoW case. Since this function both output address and pfn, rename it to
dax_iomap_direct_access().
Signed-off-by: Shiyang Ruan
Reviewed-by: Christoph Hellwig
Reviewed-by: Ritesh Harjani
---
fs/dax.c | 16
ax, we are able to make reflink
and fsdax work together in XFS.
(Rebased on v5.14-rc4 and Christoph's "switch iomap to an iterator model v2"[1])
[1]: https://lore.kernel.org/linux-xfs/20210809061244.1196573-1-...@lst.de/
==
Shiyang Ruan (8):
fsdax: Output address in dax_iomap_pfn() and r
Introduce xfs_mmaplock_two_inodes_and_break_dax_layout() for dax files
who are going to be deduped. After that, call compare range function
only when files are both DAX or not.
Signed-off-by: Shiyang Ruan
Reviewed-by: Darrick J. Wong
---
fs/xfs/xfs_file.c| 2 +-
fs/xfs/xfs_inode.c | 57
iginal struct iomap_ops and fsdax
specific ->actor_end(), which is for the end operations of reflink
- also introduce dax specific zero_range, truncate_page
- create new dax_iomap_ops for ext2 and ext4
Signed-off-by: Shiyang Ruan
---
fs/dax.c
-by: Shiyang Ruan
Reviewed-by: Christoph Hellwig
Reviewed-by: Ritesh Harjani
Reviewed-by: Darrick J. Wong
---
fs/dax.c | 39 ---
1 file changed, 28 insertions(+), 11 deletions(-)
diff --git a/fs/dax.c b/fs/dax.c
index 697a7b7bb96f..e49ba68cc7e4 100644
--- a/fs
With dax we cannot deal with readpage() etc. So, we create a dax
comparison function which is similar with
vfs_dedupe_file_range_compare().
And introduce dax_remap_file_range_prep() for filesystem use.
Signed-off-by: Goldwyn Rodrigues
Signed-off-by: Shiyang Ruan
Reviewed-by: Darrick J. Wong
Some operations, such as comparing a range of data in two files under
fsdax mode, requires nested iomap_begin()/iomap_end() on two files.
Thus, we introduce iomap_iter2() to accept two iteraters to operate
action on two files.
Signed-off-by: Shiyang Ruan
---
fs/iomap/core.c | 51
Punch hole on a reflinked file needs dax_iomap_cow_copy() too.
Otherwise, data in not aligned area will be not correct. So, add the
srcmap to dax_iomap_zero() and replace memset() as dax_iomap_cow_copy().
Signed-off-by: Shiyang Ruan
Reviewed-by: Ritesh Harjani
Reviewed-by: Darrick J. Wong
will be supported in the future. However,
some targets may not support it because of the non-linear mapping.
Signed-off-by: Shiyang Ruan
---
block/genhd.c | 56 +++
drivers/md/dm-linear.c| 20 +
include/linux/device-mapper.h | 5
include
. When it is done, call
dax_corrupted_range() for the holder of this mapped device.
Signed-off-by: Shiyang Ruan
---
drivers/md/dm.c | 126 +++-
1 file changed, 125 insertions(+), 1 deletion(-)
diff --git a/drivers/md/dm.c b/drivers/md/dm.c
index
mapped into their address spaces, but
future patches could actually do something about corrupt metadata.
After that, the memory failure needs to notify the processes who are
using those files.
Signed-off-by: Shiyang Ruan
---
drivers/dax/super.c | 12
fs/xfs/xfs_fsops.c | 5 ++
fs/xfs
.
Signed-off-by: Shiyang Ruan
---
fs/dax.c | 14 --
1 file changed, 8 insertions(+), 6 deletions(-)
diff --git a/fs/dax.c b/fs/dax.c
index dce6307a12eb..f5910d178695 100644
--- a/fs/dax.c
+++ b/fs/dax.c
@@ -352,9 +352,10 @@ static void dax_associate_entry(void *entry, struct
in fsdax mode. So, it is called when filesystem RMAP
results are found.
Signed-off-by: Shiyang Ruan
---
fs/dax.c| 45 ---
include/linux/dax.h | 16
include/linux/mm.h | 10 +++
mm/memory-failure.c | 64
with this error.
The filesystem will try to recover the corrupted data if necessary.
Signed-off-by: Shiyang Ruan
---
include/linux/memremap.h | 9 +
1 file changed, 9 insertions(+)
diff --git a/include/linux/memremap.h b/include/linux/memremap.h
index c0e9d35889e8..ed6980087db5 100644
--- a/include
memory_failure_dev_pagemap code is a bit complex before introduce RMAP
feature for fsdax. So it is needed to factor some helper functions to
simplify these code.
Signed-off-by: Shiyang Ruan
---
mm/memory-failure.c | 101 +---
1 file changed, 57
filesystem is being mounted,
or an target device is being activated.
Signed-off-by: Shiyang Ruan
---
drivers/dax/super.c | 46 +
include/linux/dax.h | 17 +
2 files changed, 63 insertions(+)
diff --git a/drivers/dax/super.c b/drivers/dax
|* md_dax_notify_failure()
| |-
| md_targets->iterate_devices()
| md_targets->rmap() => linear_rmap()
| dax_holder_notify_failure()
|* normal case
|-
mf_generic_kill_procs()
The fsdax & reflink support for XFS is not contained in this patchset.
(Rebased on v5.14
.
Signed-off-by: Shiyang Ruan
---
fs/dax.c | 14 --
1 file changed, 8 insertions(+), 6 deletions(-)
diff --git a/fs/dax.c b/fs/dax.c
index dce6307a12eb..f5910d178695 100644
--- a/fs/dax.c
+++ b/fs/dax.c
@@ -352,9 +352,10 @@ static void dax_associate_entry(void *entry, struct
. When it is done, call
dax_corrupted_range() for the holder of this mapped device.
Signed-off-by: Shiyang Ruan
---
drivers/md/dm.c | 126 +++-
1 file changed, 125 insertions(+), 1 deletion(-)
diff --git a/drivers/md/dm.c b/drivers/md/dm.c
index
mapped into their address spaces, but
future patches could actually do something about corrupt metadata.
After that, the memory failure needs to notify the processes who are
using those files.
Signed-off-by: Shiyang Ruan
---
drivers/dax/super.c | 12
fs/xfs/xfs_fsops.c | 5 ++
fs/xfs
in fsdax mode. So, it is called when filesystem RMAP
results are found.
Signed-off-by: Shiyang Ruan
---
fs/dax.c| 45 ---
include/linux/dax.h | 16
include/linux/mm.h | 10 +++
mm/memory-failure.c | 64
With dax_holder notify support, we are able to notify the memory failure
from pmem driver to upper layers. If there is something not support in
the notify routine, memory_failure will fall back to the generic hanlder.
Signed-off-by: Shiyang Ruan
---
drivers/nvdimm/pmem.c | 13 +
mm
filesystem is being mounted,
or an target device is being activated.
Signed-off-by: Shiyang Ruan
---
drivers/dax/super.c | 46 +
include/linux/dax.h | 17 +
2 files changed, 63 insertions(+)
diff --git a/drivers/dax/super.c b/drivers/dax
with this error.
The filesystem will try to recover the corrupted data if necessary.
Signed-off-by: Shiyang Ruan
---
include/linux/memremap.h | 9 +
1 file changed, 9 insertions(+)
diff --git a/include/linux/memremap.h b/include/linux/memremap.h
index c0e9d35889e8..ed6980087db5 100644
--- a/include
ntains the original struct iomap_ops and fsdax
specific ->actor_end(), which is for the end operations of reflink
- also introduce dax specific zero_range, truncate_page
- create new dax_iomap_ops for ext2 and ext4
Then enable fsdax and reflink together in xfs.
Signed-off-by: Shiyang Ruan
---
Add address output in dax_iomap_pfn() in order to perform a memcpy() in
CoW case. Since this function both output address and pfn, rename it to
dax_iomap_direct_access().
Signed-off-by: Shiyang Ruan
Reviewed-by: Christoph Hellwig
Reviewed-by: Ritesh Harjani
Reviewed-by: Darrick J. Wong
The core logic in the two dax page fault functions is similar. So, move
the logic into a common helper function. Also, to facilitate the
addition of new features, such as CoW, switch-case is no longer used to
handle different iomap types.
Signed-off-by: Shiyang Ruan
Reviewed-by: Christoph
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 them as helper functions to
simplify the code.
Signed-off-by: Shiyang Ruan
Reviewed-by: Christoph Hellwig
- simplify return logic in dax_fault_cow_page()
(Rebased on v5.13)
==
Shiyang Ruan (3):
fsdax: Factor helpers to simplify dax fault code
fsdax: Factor helper: dax_fault_actor()
fsdax: Output address in dax_iomap_pfn() and rename it
fs/d
Since owner tracking is triggerred by pmem device, these functions are
useless. So remove them.
Signed-off-by: Shiyang Ruan
---
fs/dax.c | 46 --
1 file changed, 46 deletions(-)
diff --git a/fs/dax.c b/fs/dax.c
index 7c5d8acd6bc5..cee8e61d1025
. When it is done, call
dax_corrupted_range() for the holder of this mapped device.
Signed-off-by: Shiyang Ruan
---
drivers/md/dm.c | 126 +++-
1 file changed, 125 insertions(+), 1 deletion(-)
diff --git a/drivers/md/dm.c b/drivers/md/dm.c
index
1 - 100 of 109 matches
Mail list logo