aboutsummaryrefslogtreecommitdiffstats
path: root/mm
diff options
context:
space:
mode:
Diffstat (limited to 'mm')
-rw-r--r--mm/huge_memory.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/mm/huge_memory.c b/mm/huge_memory.c
index 860ea912785..9833d8ecf38 100644
--- a/mm/huge_memory.c
+++ b/mm/huge_memory.c
@@ -140,10 +140,7 @@ static int start_khugepaged(void)
140 int err = 0; 140 int err = 0;
141 if (khugepaged_enabled()) { 141 if (khugepaged_enabled()) {
142 int wakeup; 142 int wakeup;
143 if (unlikely(!mm_slot_cache || !mm_slots_hash)) { 143
144 err = -ENOMEM;
145 goto out;
146 }
147 mutex_lock(&khugepaged_mutex); 144 mutex_lock(&khugepaged_mutex);
148 if (!khugepaged_thread) 145 if (!khugepaged_thread)
149 khugepaged_thread = kthread_run(khugepaged, NULL, 146 khugepaged_thread = kthread_run(khugepaged, NULL,
@@ -163,7 +160,7 @@ static int start_khugepaged(void)
163 } else 160 } else
164 /* wakeup to exit */ 161 /* wakeup to exit */
165 wake_up_interruptible(&khugepaged_wait); 162 wake_up_interruptible(&khugepaged_wait);
166out: 163
167 return err; 164 return err;
168} 165}
169 166