Skip to content

Commit

Permalink
[PATCH] Add try_to_freeze() to rt-test kthreads
Browse files Browse the repository at this point in the history
When CONFIG_RT_MUTEX_TESTER is enabled kernel refuses to suspend the
machine because it's unable to freeze the rt-test-* threads.

Add try_to_freeze() after schedule() so that the threads will be freezed
correctly; I've tested the patch and it lets the notebook suspends and
resumes nicely.

Signed-off-by: Luca Tettamanti <[email protected]>
Cc: Ingo Molnar <[email protected]>
Acked-by: Thomas Gleixner <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
tettamanti authored and Linus Torvalds committed Jul 15, 2006
1 parent ddca60c commit 60198f9
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions kernel/rtmutex-tester.c
Original file line number Diff line number Diff line change
Expand Up @@ -275,6 +275,7 @@ static int test_func(void *data)

/* Wait for the next command to be executed */
schedule();
try_to_freeze();

if (signal_pending(current))
flush_signals(current);
Expand Down

0 comments on commit 60198f9

Please sign in to comment.