Skip to contentSkip to conversation

Patch "mm, swap_cgroup: reschedule when neeed in swap_cgroup_swapoff()" has been added to the 4.4-stable tree

PATCH [email protected] 1 participant 1 message Jul 3, 2017

Subsystems (2)
lore
Share & tools
lore

[email protected]

author maintainer Applied
#0 lore raw

This is a note to let you know that I've just added the patch titled

mm, swap_cgroup: reschedule when neeed in swap_cgroup_swapoff()

to the 4.4-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
mm-swap_cgroup-reschedule-when-neeed-in-swap_cgroup_swapoff.patch
and it can be found in the queue-4.4 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.

Quoted 1 line

From 460bcec84e11c75122ace5976214abbc596eb91b Mon Sep 17 00:00:00 2001

From: David Rientjes <[email protected]>
Date: Fri, 7 Apr 2017 16:05:00 -0700
Subject: mm, swap_cgroup: reschedule when neeed in swap_cgroup_swapoff()

From: David Rientjes <[email protected]>

commit 460bcec84e11c75122ace5976214abbc596eb91b upstream.

We got need_resched() warnings in swap_cgroup_swapoff() because swap_cgroup_ctrl[type].length is particularly large.

Reschedule when needed.

---
 mm/swap_cgroup.c |    2 ++
 1 file changed, 2 insertions(+)
mm/swap_cgroup.c +2 -0
@@ -205,6 +205,8 @@ void swap_cgroup_swapoff(int type)
 			struct page *page = map[i];
 			if (page)
 				__free_page(page);
+			if (!(i % SWAP_CLUSTER_MAX))
+				cond_resched();
 		}
 		vfree(map);
 	}

Patches currently in stable-queue which might be from [email protected] are

queue-4.4/mm-swap_cgroup-reschedule-when-neeed-in-swap_cgroup_swapoff.patch