Merge Christoph's freeze cleanup patch
此提交包含在:
@@ -116,7 +116,7 @@ static int kafsasyncd(void *arg)
|
||||
remove_wait_queue(&kafsasyncd_sleepq, &myself);
|
||||
set_current_state(TASK_RUNNING);
|
||||
|
||||
try_to_freeze(PF_FREEZE);
|
||||
try_to_freeze();
|
||||
|
||||
/* discard pending signals */
|
||||
afs_discard_my_signals();
|
||||
|
@@ -91,7 +91,7 @@ static int kafstimod(void *arg)
|
||||
complete_and_exit(&kafstimod_dead, 0);
|
||||
}
|
||||
|
||||
try_to_freeze(PF_FREEZE);
|
||||
try_to_freeze();
|
||||
|
||||
/* discard pending signals */
|
||||
afs_discard_my_signals();
|
||||
|
@@ -167,7 +167,7 @@ loop:
|
||||
}
|
||||
|
||||
wake_up(&journal->j_wait_done_commit);
|
||||
if (current->flags & PF_FREEZE) {
|
||||
if (freezing(current)) {
|
||||
/*
|
||||
* The simpler the better. Flushing journal isn't a
|
||||
* good idea, because that depends on threads that may
|
||||
@@ -175,7 +175,7 @@ loop:
|
||||
*/
|
||||
jbd_debug(1, "Now suspending kjournald\n");
|
||||
spin_unlock(&journal->j_state_lock);
|
||||
refrigerator(PF_FREEZE);
|
||||
refrigerator();
|
||||
spin_lock(&journal->j_state_lock);
|
||||
} else {
|
||||
/*
|
||||
|
@@ -2359,9 +2359,9 @@ int jfsIOWait(void *arg)
|
||||
lbmStartIO(bp);
|
||||
spin_lock_irq(&log_redrive_lock);
|
||||
}
|
||||
if (current->flags & PF_FREEZE) {
|
||||
if (freezing(current)) {
|
||||
spin_unlock_irq(&log_redrive_lock);
|
||||
refrigerator(PF_FREEZE);
|
||||
refrigerator();
|
||||
} else {
|
||||
add_wait_queue(&jfs_IO_thread_wait, &wq);
|
||||
set_current_state(TASK_INTERRUPTIBLE);
|
||||
|
@@ -2788,9 +2788,9 @@ int jfs_lazycommit(void *arg)
|
||||
/* In case a wakeup came while all threads were active */
|
||||
jfs_commit_thread_waking = 0;
|
||||
|
||||
if (current->flags & PF_FREEZE) {
|
||||
if (freezing(current)) {
|
||||
LAZY_UNLOCK(flags);
|
||||
refrigerator(PF_FREEZE);
|
||||
refrigerator();
|
||||
} else {
|
||||
DECLARE_WAITQUEUE(wq, current);
|
||||
|
||||
@@ -2987,9 +2987,9 @@ int jfs_sync(void *arg)
|
||||
/* Add anon_list2 back to anon_list */
|
||||
list_splice_init(&TxAnchor.anon_list2, &TxAnchor.anon_list);
|
||||
|
||||
if (current->flags & PF_FREEZE) {
|
||||
if (freezing(current)) {
|
||||
TXN_UNLOCK();
|
||||
refrigerator(PF_FREEZE);
|
||||
refrigerator();
|
||||
} else {
|
||||
DECLARE_WAITQUEUE(wq, current);
|
||||
|
||||
|
@@ -313,7 +313,7 @@ static int nlm_wait_on_grace(wait_queue_head_t *queue)
|
||||
prepare_to_wait(queue, &wait, TASK_INTERRUPTIBLE);
|
||||
if (!signalled ()) {
|
||||
schedule_timeout(NLMCLNT_GRACE_WAIT);
|
||||
try_to_freeze(PF_FREEZE);
|
||||
try_to_freeze();
|
||||
if (!signalled ())
|
||||
status = 0;
|
||||
}
|
||||
|
@@ -1771,9 +1771,9 @@ xfsbufd(
|
||||
|
||||
INIT_LIST_HEAD(&tmp);
|
||||
do {
|
||||
if (unlikely(current->flags & PF_FREEZE)) {
|
||||
if (unlikely(freezing(current))) {
|
||||
xfsbufd_force_sleep = 1;
|
||||
refrigerator(PF_FREEZE);
|
||||
refrigerator();
|
||||
} else {
|
||||
xfsbufd_force_sleep = 0;
|
||||
}
|
||||
|
@@ -483,7 +483,7 @@ xfssyncd(
|
||||
set_current_state(TASK_INTERRUPTIBLE);
|
||||
timeleft = schedule_timeout(timeleft);
|
||||
/* swsusp */
|
||||
try_to_freeze(PF_FREEZE);
|
||||
try_to_freeze();
|
||||
if (vfsp->vfs_flag & VFS_UMOUNT)
|
||||
break;
|
||||
|
||||
|
新增問題並參考
封鎖使用者