linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/4] Fix kmemleak races on the disable/error path
@ 2015-06-08 14:29 Catalin Marinas
  2015-06-08 14:29 ` [PATCH v2 1/4] mm: kmemleak: Allow safe memory scanning during kmemleak disabling Catalin Marinas
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Catalin Marinas @ 2015-06-08 14:29 UTC (permalink / raw)
  To: linux-mm; +Cc: linux-kernel, Andrew Morton, vigneshr

This is a follow-up to the initial patch fixing the kmemleak_scan page
fault during kmemleak disabling:

http://article.gmane.org/gmane.linux.kernel.mm/133707

The first patch is pretty much the same, apart from a clearer
(hopefully) commit log and code comment regarding the ordering of
kmemleak_free_enabled with the scanning thread. The race between
kmemleak_free() and kmemleak_do_cleanup() is fixed in the second patch.

The third patch fixes a potential deadlock on scan_mutex between the
kmemleak_scan_thread and kmemleak_do_cleanup().

The fourth patch is more of a theoretical scenario but worth fixing the
lock acquiring order.

Catalin Marinas (4):
  mm: kmemleak: Allow safe memory scanning during kmemleak disabling
  mm: kmemleak: Fix delete_object_*() race when called on the same
    memory block
  mm: kmemleak: Do not acquire scan_mutex in kmemleak_do_cleanup()
  mm: kmemleak: Avoid deadlock on the kmemleak object insertion error
    path

 mm/kmemleak.c | 75 +++++++++++++++++++++++++++++++++++++++++------------------
 1 file changed, 53 insertions(+), 22 deletions(-)

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2015-06-08 14:29 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-06-08 14:29 [PATCH v2 0/4] Fix kmemleak races on the disable/error path Catalin Marinas
2015-06-08 14:29 ` [PATCH v2 1/4] mm: kmemleak: Allow safe memory scanning during kmemleak disabling Catalin Marinas
2015-06-08 14:29 ` [PATCH v2 2/4] mm: kmemleak: Fix delete_object_*() race when called on the same memory block Catalin Marinas
2015-06-08 14:29 ` [PATCH v2 3/4] mm: kmemleak: Do not acquire scan_mutex in kmemleak_do_cleanup() Catalin Marinas
2015-06-08 14:29 ` [PATCH v2 4/4] mm: kmemleak: Avoid deadlock on the kmemleak object insertion error path Catalin Marinas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).