From 8345b6448d292a8da4464debb4dc65b55f1f6eeb Mon Sep 17 00:00:00 2001 From: Raghavendra G Date: Fri, 30 Oct 2009 00:10:20 +0000 Subject: performance/io-cache: change the data-types to be big enough to hold size of data flushed. Signed-off-by: Anand V. Avati BUG: 335 (Io-cache optimization) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=335 --- xlators/performance/io-cache/src/io-cache.c | 8 ++++---- xlators/performance/io-cache/src/io-cache.h | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'xlators') diff --git a/xlators/performance/io-cache/src/io-cache.c b/xlators/performance/io-cache/src/io-cache.c index da3f4f15d..84b184993 100644 --- a/xlators/performance/io-cache/src/io-cache.c +++ b/xlators/performance/io-cache/src/io-cache.c @@ -95,12 +95,12 @@ ioc_inode_need_revalidate (ioc_inode_t *ioc_inode) * * assumes lock is held */ -int32_t +int64_t __ioc_inode_flush (ioc_inode_t *ioc_inode) { ioc_page_t *curr = NULL, *next = NULL; - int32_t destroy_size = 0; - int32_t ret = 0; + int64_t destroy_size = 0; + int64_t ret = 0; list_for_each_entry_safe (curr, next, &ioc_inode->cache.page_lru, page_lru) { @@ -116,7 +116,7 @@ __ioc_inode_flush (ioc_inode_t *ioc_inode) void ioc_inode_flush (ioc_inode_t *ioc_inode) { - int32_t destroy_size = 0; + int64_t destroy_size = 0; ioc_inode_lock (ioc_inode); { diff --git a/xlators/performance/io-cache/src/io-cache.h b/xlators/performance/io-cache/src/io-cache.h index 49d3d000b..de6cb3527 100644 --- a/xlators/performance/io-cache/src/io-cache.h +++ b/xlators/performance/io-cache/src/io-cache.h @@ -313,7 +313,7 @@ ioc_inode_update (ioc_table_t *table, inode_t *inode, uint32_t weight); int64_t ioc_page_destroy (ioc_page_t *page); -int32_t +int64_t __ioc_inode_flush (ioc_inode_t *ioc_inode); void -- cgit