X-Git-Url: http://pileus.org/git/?a=blobdiff_plain;f=fs%2Fgfs2%2Fdaemon.c;h=e51991947d2cd876c39ba4eea0d8b6b31c838ebe;hb=bd45ac0c5daae35e7c71138172e63df5cf644cf6;hp=3548d9f31e0d5c6918d74115a5fd0f9f2b133f48;hpb=b43035a5ec4deecd43019728ab9347df82dd121f;p=~andy%2Flinux diff --git a/fs/gfs2/daemon.c b/fs/gfs2/daemon.c index 3548d9f31e0..e51991947d2 100644 --- a/fs/gfs2/daemon.c +++ b/fs/gfs2/daemon.c @@ -34,30 +34,6 @@ The kthread functions used to start these daemons block and flush signals. */ -/** - * gfs2_scand - Look for cached glocks and inodes to toss from memory - * @sdp: Pointer to GFS2 superblock - * - * One of these daemons runs, finding candidates to add to sd_reclaim_list. - * See gfs2_glockd() - */ - -int gfs2_scand(void *data) -{ - struct gfs2_sbd *sdp = data; - unsigned long t; - - while (!kthread_should_stop()) { - gfs2_scand_internal(sdp); - t = gfs2_tune_get(sdp, gt_scand_secs) * HZ; - if (freezing(current)) - refrigerator(); - schedule_timeout_interruptible(t); - } - - return 0; -} - /** * gfs2_glockd - Reclaim unused glock structures * @sdp: Pointer to GFS2 superblock @@ -106,56 +82,6 @@ int gfs2_recoverd(void *data) return 0; } -/** - * gfs2_logd - Update log tail as Active Items get flushed to in-place blocks - * @sdp: Pointer to GFS2 superblock - * - * Also, periodically check to make sure that we're using the most recent - * journal index. - */ - -int gfs2_logd(void *data) -{ - struct gfs2_sbd *sdp = data; - struct gfs2_holder ji_gh; - unsigned long t; - int need_flush; - - while (!kthread_should_stop()) { - /* Advance the log tail */ - - t = sdp->sd_log_flush_time + - gfs2_tune_get(sdp, gt_log_flush_secs) * HZ; - - gfs2_ail1_empty(sdp, DIO_ALL); - gfs2_log_lock(sdp); - need_flush = sdp->sd_log_num_buf > gfs2_tune_get(sdp, gt_incore_log_blocks); - gfs2_log_unlock(sdp); - if (need_flush || time_after_eq(jiffies, t)) { - gfs2_log_flush(sdp, NULL); - sdp->sd_log_flush_time = jiffies; - } - - /* Check for latest journal index */ - - t = sdp->sd_jindex_refresh_time + - gfs2_tune_get(sdp, gt_jindex_refresh_secs) * HZ; - - if (time_after_eq(jiffies, t)) { - if (!gfs2_jindex_hold(sdp, &ji_gh)) - gfs2_glock_dq_uninit(&ji_gh); - sdp->sd_jindex_refresh_time = jiffies; - } - - t = gfs2_tune_get(sdp, gt_logd_secs) * HZ; - if (freezing(current)) - refrigerator(); - schedule_timeout_interruptible(t); - } - - return 0; -} - /** * gfs2_quotad - Write cached quota changes into the quota file * @sdp: Pointer to GFS2 superblock