[PATCH 04/15] ceph: Add a migrate_folio method

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The ceph_snap_context is independent of the address of the data, so we
can implement folio migration by just removing the ceph_snap_context
from the existing folio and attach it to the new one, which is exactly
what filemap_migrate_folio() does.

Signed-off-by: Matthew Wilcox (Oracle) <willy@xxxxxxxxxxxxx>
---
 fs/ceph/addr.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/fs/ceph/addr.c b/fs/ceph/addr.c
index 7c7dfcd63cd1..a0a1fac1a0db 100644
--- a/fs/ceph/addr.c
+++ b/fs/ceph/addr.c
@@ -1563,6 +1563,7 @@ const struct address_space_operations ceph_aops = {
 	.invalidate_folio = ceph_invalidate_folio,
 	.release_folio = ceph_release_folio,
 	.direct_IO = noop_direct_IO,
+	.migrate_folio = filemap_migrate_folio,
 };
 
 static void ceph_block_sigs(sigset_t *oldset)
-- 
2.40.1




[Index of Archives]     [CEPH Users]     [Ceph Large]     [Ceph Dev]     [Information on CEPH]     [Linux BTRFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux