aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_super.c
diff options
context:
space:
mode:
authorDave Chinner <david@fromorbit.com>2013-06-27 02:04:53 -0400
committerBen Myers <bpm@sgi.com>2013-06-27 14:34:12 -0400
commit3ebe7d2d73179c4874aee4f32e043eb5acd9fa0f (patch)
tree39bf0b8fac593d4051ebfbc7011a26423a8f90a4 /fs/xfs/xfs_super.c
parent5f6bed76c0c85cb4d04885a5de00b629deee550b (diff)
xfs: Inode create log items
Introduce the inode create log item type for logical inode create logging. Instead of logging the changes in buffers, pass the range to be initialised through the log by a new transaction type. This reduces the amount of log space required to record initialisation during allocation from about 128 bytes per inode to a small fixed amount per inode extent to be initialised. This requires a new log item type to track it through the log and the AIL. This is a relatively simple item - most callbacks are noops as this item has the same life cycle as the transaction. Signed-off-by: Dave Chinner <david@fromorbit.com> Reviewed-by: Mark Tinguely <tinguely@sgi.com> Signed-off-by: Ben Myers <bpm@sgi.com>
Diffstat (limited to 'fs/xfs/xfs_super.c')
-rw-r--r--fs/xfs/xfs_super.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/fs/xfs/xfs_super.c b/fs/xfs/xfs_super.c
index 14924099bcb8..30ef68f8a390 100644
--- a/fs/xfs/xfs_super.c
+++ b/fs/xfs/xfs_super.c
@@ -51,6 +51,7 @@
51#include "xfs_inode_item.h" 51#include "xfs_inode_item.h"
52#include "xfs_icache.h" 52#include "xfs_icache.h"
53#include "xfs_trace.h" 53#include "xfs_trace.h"
54#include "xfs_icreate_item.h"
54 55
55#include <linux/namei.h> 56#include <linux/namei.h>
56#include <linux/init.h> 57#include <linux/init.h>
@@ -1650,9 +1651,15 @@ xfs_init_zones(void)
1650 KM_ZONE_SPREAD, NULL); 1651 KM_ZONE_SPREAD, NULL);
1651 if (!xfs_ili_zone) 1652 if (!xfs_ili_zone)
1652 goto out_destroy_inode_zone; 1653 goto out_destroy_inode_zone;
1654 xfs_icreate_zone = kmem_zone_init(sizeof(struct xfs_icreate_item),
1655 "xfs_icr");
1656 if (!xfs_icreate_zone)
1657 goto out_destroy_ili_zone;
1653 1658
1654 return 0; 1659 return 0;
1655 1660
1661 out_destroy_ili_zone:
1662 kmem_zone_destroy(xfs_ili_zone);
1656 out_destroy_inode_zone: 1663 out_destroy_inode_zone:
1657 kmem_zone_destroy(xfs_inode_zone); 1664 kmem_zone_destroy(xfs_inode_zone);
1658 out_destroy_efi_zone: 1665 out_destroy_efi_zone:
@@ -1691,6 +1698,7 @@ xfs_destroy_zones(void)
1691 * destroy caches. 1698 * destroy caches.
1692 */ 1699 */
1693 rcu_barrier(); 1700 rcu_barrier();
1701 kmem_zone_destroy(xfs_icreate_zone);
1694 kmem_zone_destroy(xfs_ili_zone); 1702 kmem_zone_destroy(xfs_ili_zone);
1695 kmem_zone_destroy(xfs_inode_zone); 1703 kmem_zone_destroy(xfs_inode_zone);
1696 kmem_zone_destroy(xfs_efi_zone); 1704 kmem_zone_destroy(xfs_efi_zone);