Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 324474
b: refs/heads/master
c: b29687f
h: refs/heads/master
v: v3
  • Loading branch information
Devendra Naga authored and Greg Kroah-Hartman committed Aug 14, 2012
1 parent 8bbd0fb commit 9dbd3f4
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 15 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f7523ab6c0a7c9eefee2ab7fd0df48fca839b490
refs/heads/master: b29687fb8857061348db95c13712ca36549725b2
29 changes: 15 additions & 14 deletions trunk/drivers/staging/csr/bh.c
Original file line number Diff line number Diff line change
Expand Up @@ -122,23 +122,24 @@ void uf_stop_thread(unifi_priv_t *priv, struct uf_thread *thread)
*
* ---------------------------------------------------------------------------
*/
void
void
uf_wait_for_thread_to_stop(unifi_priv_t *priv, struct uf_thread *thread)
{
/*
* kthread_stop() cannot handle the thread exiting while
* kthread_should_stop() is false, so sleep until kthread_stop()
* wakes us up.
*/
unifi_trace(priv, UDBG2, "%s waiting for the stop signal.\n", thread->name);
set_current_state(TASK_INTERRUPTIBLE);
if (!kthread_should_stop()) {
unifi_trace(priv, UDBG2, "%s schedule....\n", thread->name);
schedule();
}
/*
* kthread_stop() cannot handle the thread exiting while
* kthread_should_stop() is false, so sleep until kthread_stop()
* wakes us up
*/
unifi_trace(priv, UDBG2, "%s waiting for the stop signal.\n",
thread->name);
set_current_state(TASK_INTERRUPTIBLE);
if (!kthread_should_stop()) {
unifi_trace(priv, UDBG2, "%s schedule....\n", thread->name);
schedule();
}

thread->thread_task = NULL;
unifi_trace(priv, UDBG2, "%s exiting....\n", thread->name);
thread->thread_task = NULL;
unifi_trace(priv, UDBG2, "%s exiting....\n", thread->name);
} /* uf_wait_for_thread_to_stop() */


Expand Down

0 comments on commit 9dbd3f4

Please sign in to comment.