mm, swap_cgroup: reschedule when neeed in swap_cgroup_swapoff()
authorDavid Rientjes <rientjes@google.com>
Fri, 7 Apr 2017 23:05:00 +0000 (16:05 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Sat, 8 Apr 2017 07:47:49 +0000 (00:47 -0700)
commit460bcec84e11c75122ace5976214abbc596eb91b
treed73d64a305d28d8bf9a0389b021aa543f18e223b
parente11f8b7b6c4ea13bf8af6b8f42b45e15b554a92b
mm, swap_cgroup: reschedule when neeed in swap_cgroup_swapoff()

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

Reschedule when needed.

Link: http://lkml.kernel.org/r/alpine.DEB.2.10.1704061315270.80559@chino.kir.corp.google.com
Signed-off-by: David Rientjes <rientjes@google.com>
Acked-by: Michal Hocko <mhocko@suse.com>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Cc: Vladimir Davydov <vdavydov.dev@gmail.com>
Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
mm/swap_cgroup.c