Index: linux-2.6.17-rc2-mm1/mm/migrate.c =================================================================== --- linux-2.6.17-rc2-mm1.orig/mm/migrate.c 2006-04-28 13:40:54.435538677 -0700 +++ linux-2.6.17-rc2-mm1/mm/migrate.c 2006-04-28 13:51:21.604518807 -0700 @@ -318,6 +318,7 @@ page_count(page) != 2 + !!PagePrivate(page) || *radix_pointer != page) { write_unlock_irq(&mapping->tree_lock); + printk(KERN_ERR "mapping lock retry: page=%p page_count=%d\n", page_address(page), page_count(page)); return -EAGAIN; } @@ -474,6 +475,7 @@ { int rc; + printk(KERN_ERR "fallback_migrate_page\n"); /* * Removing the ptes may have dirtied the page */ @@ -494,6 +496,7 @@ */ remove_migration_ptes(page, page); + printk(KERN_ERR "Page is dirty\n"); if (!mapping->a_ops->writepage) /* No write method for the address space */ return -EINVAL; @@ -510,6 +513,7 @@ if (rc == AOP_WRITEPAGE_ACTIVATE) return -EAGAIN; + printk(KERN_ERR "Successful write triggered.\n"); lock_page(page); /* * The lock was dropped by writepage() and so something @@ -525,11 +529,13 @@ if (page_has_buffers(page) && !try_to_release_page(page, GFP_KERNEL)) return -EAGAIN; + printk(KERN_ERR "before move_mapping\n"); rc = migrate_page_move_mapping(mapping, newpage, page); if (rc) return rc; + printk(KERN_ERR "ready to copy\n"); migrate_page_copy(newpage, page); return 0; @@ -624,8 +630,13 @@ * Retry if we were unable to remove all mappings. */ rc = -EAGAIN; - if (page_mapcount(page)) + if (page_mapcount(page)) { + printk(KERN_ERR "Retry: page=%p mapcount = %d\n", page_address(page), page_mapcount(page)); goto remove_migentry; + } + + printk(KERN_ERR "Migration %p->%p attempt %d:\n", page_address(page), page_address(newpage), pass); + lock_page(newpage); /* Prepare mapping for the new page.*/ @@ -656,6 +667,8 @@ unlock_page: unlock_page(page); + printk(KERN_ERR "Migration %p->%p status %d:\n", page_address(page), page_address(newpage),rc); + next: if (likely(rc == 0)) { /* Successful migration. */ Index: linux-2.6.17-rc2-mm1/fs/xfs/linux-2.6/xfs_aops.c =================================================================== --- linux-2.6.17-rc2-mm1.orig/fs/xfs/linux-2.6/xfs_aops.c 2006-04-18 20:00:49.000000000 -0700 +++ linux-2.6.17-rc2-mm1/fs/xfs/linux-2.6/xfs_aops.c 2006-04-28 13:45:46.633174543 -0700 @@ -1459,5 +1459,5 @@ .commit_write = generic_commit_write, .bmap = xfs_vm_bmap, .direct_IO = xfs_vm_direct_IO, - .migratepage = buffer_migrate_page, +// .migratepage = buffer_migrate_page, };