Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

JFS: use __set_current_state()

use __set_current_state(TASK_*) instead of current->state = TASK_*

Signed-off-by: Milind Arun Choudhary <milindchoudhary@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Dave Kleikamp <shaggy@linux.vnet.ibm.com>

authored by

Milind Arun Choudhary and committed by
Dave Kleikamp
3cbb1c8e 3e2221c7

+6 -6
+1 -1
fs/jfs/jfs_lock.h
··· 45 45 io_schedule(); \ 46 46 lock_cmd; \ 47 47 } \ 48 - current->state = TASK_RUNNING; \ 48 + __set_current_state(TASK_RUNNING); \ 49 49 remove_wait_queue(&wq, &__wait); \ 50 50 } while (0) 51 51
+2 -2
fs/jfs/jfs_logmgr.c
··· 1590 1590 set_current_state(TASK_UNINTERRUPTIBLE); 1591 1591 LOGGC_UNLOCK(log); 1592 1592 schedule(); 1593 - current->state = TASK_RUNNING; 1593 + __set_current_state(TASK_RUNNING); 1594 1594 LOGGC_LOCK(log); 1595 1595 remove_wait_queue(&target->gcwait, &__wait); 1596 1596 } ··· 2361 2361 } else { 2362 2362 set_current_state(TASK_INTERRUPTIBLE); 2363 2363 schedule(); 2364 - current->state = TASK_RUNNING; 2364 + __set_current_state(TASK_RUNNING); 2365 2365 } 2366 2366 } while (!kthread_should_stop()); 2367 2367
+3 -3
fs/jfs/jfs_txnmgr.c
··· 136 136 set_current_state(TASK_UNINTERRUPTIBLE); 137 137 TXN_UNLOCK(); 138 138 io_schedule(); 139 - current->state = TASK_RUNNING; 139 + __set_current_state(TASK_RUNNING); 140 140 remove_wait_queue(event, &wait); 141 141 } 142 142 ··· 2798 2798 set_current_state(TASK_INTERRUPTIBLE); 2799 2799 LAZY_UNLOCK(flags); 2800 2800 schedule(); 2801 - current->state = TASK_RUNNING; 2801 + __set_current_state(TASK_RUNNING); 2802 2802 remove_wait_queue(&jfs_commit_thread_wait, &wq); 2803 2803 } 2804 2804 } while (!kthread_should_stop()); ··· 2990 2990 set_current_state(TASK_INTERRUPTIBLE); 2991 2991 TXN_UNLOCK(); 2992 2992 schedule(); 2993 - current->state = TASK_RUNNING; 2993 + __set_current_state(TASK_RUNNING); 2994 2994 } 2995 2995 } while (!kthread_should_stop()); 2996 2996