diff options
author | Shaohua Li <shli@kernel.org> | 2012-10-10 22:34:00 -0400 |
---|---|---|
committer | NeilBrown <neilb@suse.de> | 2012-10-10 22:34:00 -0400 |
commit | 4ed8731d8e6bd2a88a30697fbf4f7e6e979a6c46 (patch) | |
tree | 3bb77592fa5a89b8e7f0ef84b8d7f53122bbd071 /drivers/md/md.c | |
parent | 57c67df48866d57b50d72eb198ffcc0cf7a6232d (diff) |
MD: change the parameter of md thread
Change the thread parameter, so the thread can carry extra info. Next patch
will use it.
Signed-off-by: Shaohua Li <shli@fusionio.com>
Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'drivers/md/md.c')
-rw-r--r-- | drivers/md/md.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/md/md.c b/drivers/md/md.c index 7a2b0793f66e..8e842b326ebd 100644 --- a/drivers/md/md.c +++ b/drivers/md/md.c | |||
@@ -6641,7 +6641,7 @@ static int md_thread(void * arg) | |||
6641 | 6641 | ||
6642 | clear_bit(THREAD_WAKEUP, &thread->flags); | 6642 | clear_bit(THREAD_WAKEUP, &thread->flags); |
6643 | if (!kthread_should_stop()) | 6643 | if (!kthread_should_stop()) |
6644 | thread->run(thread->mddev); | 6644 | thread->run(thread); |
6645 | } | 6645 | } |
6646 | 6646 | ||
6647 | return 0; | 6647 | return 0; |
@@ -6656,8 +6656,8 @@ void md_wakeup_thread(struct md_thread *thread) | |||
6656 | } | 6656 | } |
6657 | } | 6657 | } |
6658 | 6658 | ||
6659 | struct md_thread *md_register_thread(void (*run) (struct mddev *), struct mddev *mddev, | 6659 | struct md_thread *md_register_thread(void (*run) (struct md_thread *), |
6660 | const char *name) | 6660 | struct mddev *mddev, const char *name) |
6661 | { | 6661 | { |
6662 | struct md_thread *thread; | 6662 | struct md_thread *thread; |
6663 | 6663 | ||
@@ -7206,8 +7206,9 @@ EXPORT_SYMBOL_GPL(md_allow_write); | |||
7206 | 7206 | ||
7207 | #define SYNC_MARKS 10 | 7207 | #define SYNC_MARKS 10 |
7208 | #define SYNC_MARK_STEP (3*HZ) | 7208 | #define SYNC_MARK_STEP (3*HZ) |
7209 | void md_do_sync(struct mddev *mddev) | 7209 | void md_do_sync(struct md_thread *thread) |
7210 | { | 7210 | { |
7211 | struct mddev *mddev = thread->mddev; | ||
7211 | struct mddev *mddev2; | 7212 | struct mddev *mddev2; |
7212 | unsigned int currspeed = 0, | 7213 | unsigned int currspeed = 0, |
7213 | window; | 7214 | window; |