Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 276535
b: refs/heads/master
c: 1dfb059
h: refs/heads/master
i:
  276533: 42c6bfe
  276531: 8c3c064
  276527: 66cc7b1
v: v3
  • Loading branch information
Andrea Arcangeli authored and Linus Torvalds committed Dec 9, 2011
1 parent b460cbd commit 752692a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 13 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: b53fc7c2974a50913f49e1d800fe904a28c338e3
refs/heads/master: 1dfb059b9438633b0546c5431538a47f6ed99028
16 changes: 4 additions & 12 deletions trunk/mm/huge_memory.c
Original file line number Diff line number Diff line change
Expand Up @@ -2259,12 +2259,8 @@ static void khugepaged_do_scan(struct page **hpage)

static void khugepaged_alloc_sleep(void)
{
DEFINE_WAIT(wait);
add_wait_queue(&khugepaged_wait, &wait);
schedule_timeout_interruptible(
msecs_to_jiffies(
khugepaged_alloc_sleep_millisecs));
remove_wait_queue(&khugepaged_wait, &wait);
wait_event_freezable_timeout(khugepaged_wait, false,
msecs_to_jiffies(khugepaged_alloc_sleep_millisecs));
}

#ifndef CONFIG_NUMA
Expand Down Expand Up @@ -2313,14 +2309,10 @@ static void khugepaged_loop(void)
if (unlikely(kthread_should_stop()))
break;
if (khugepaged_has_work()) {
DEFINE_WAIT(wait);
if (!khugepaged_scan_sleep_millisecs)
continue;
add_wait_queue(&khugepaged_wait, &wait);
schedule_timeout_interruptible(
msecs_to_jiffies(
khugepaged_scan_sleep_millisecs));
remove_wait_queue(&khugepaged_wait, &wait);
wait_event_freezable_timeout(khugepaged_wait, false,
msecs_to_jiffies(khugepaged_scan_sleep_millisecs));
} else if (khugepaged_enabled())
wait_event_freezable(khugepaged_wait,
khugepaged_wait_event());
Expand Down

0 comments on commit 752692a

Please sign in to comment.