commit 87bca033d12960afeb4725e8e8eb5044e575d8ba
Author: Yiannis Pericleous <[EMAIL PROTECTED]>
Date: Sun Mar 18 17:23:31 2007 -0400
cleanup ic only if free blocks/inodes below certain %
wake_up_sioa now makes sure sioa resumes before calling thread
diff --git a/fs/unionfs/odf.h b/fs/unionfs/odf.h
index ce97346..ce41c30 100644
--- a/fs/unionfs/odf.h
+++ b/fs/unionfs/odf.h
@@ -61,7 +61,9 @@
#define ODF_DIRENT_MAGIC 0x0DFD1300
/* Reclaim thread timeout */
-#define ODF_RC_TIMEOUT 10000
+#define ODF_CL_TIMEOUT 10000
+#define ODF_CL_PCNT_I 25 /* cleanup ic when % of free inodes goes below this
val */
+#define ODF_CL_PCNT_B 30 /* cleanup ic when % of free blocks goes below this
val */
#define ODF_CONTENT "content"
#define ODF_CONTENT_LEN 7
diff --git a/fs/unionfs/sioq.c b/fs/unionfs/sioq.c
index a2cc293..fc87dc2 100644
--- a/fs/unionfs/sioq.c
+++ b/fs/unionfs/sioq.c
@@ -70,6 +70,7 @@ int __run_sioa(void *args)
schedule();
}
current->state = TASK_INTERRUPTIBLE;
+ mutex_lock(&sioa_args->sleep_lock);
schedule_timeout(sioa_args->timeout);
}
diff --git a/fs/unionfs/sioq.h b/fs/unionfs/sioq.h
index 91109a3..0cda1be 100644
--- a/fs/unionfs/sioq.h
+++ b/fs/unionfs/sioq.h
@@ -61,6 +61,7 @@ struct sioa_args {
signed long timeout;
void (*work) (void*);
int (*done) (void*);
+ struct mutex sleep_lock;
union {
struct cleanup_args cleanup;
_______________________________________________
unionfs-cvs mailing list: http://unionfs.filesystems.org/
[email protected]
http://www.fsl.cs.sunysb.edu/mailman/listinfo/unionfs-cvs