Prev: [PATCH 0/5] use idr kernel library instead of handles
Next: [PATCH v2] cpuidle: extend cpuidle and menu governor to handle dynamic states
From: Ondrej Zary on 28 Jul 2010 17:30 Hello, after very long bisection, I finally found what's causing memory corruption during hibernation on my machine sice 2.6.31: https://bugzilla.kernel.org/show_bug.cgi?id=15753 It's commit c9e444103b5e7a5a3519f9913f59767f92e33baf (mm: reuse unused swap entry if necessary). I don't know anything about swapping in Linux so I don't have a clue what's wrong with that commit. -- Ondrej Zary -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo(a)vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
From: Rafael J. Wysocki on 28 Jul 2010 17:40 On Wednesday, July 28, 2010, Ondrej Zary wrote: > Hello, > after very long bisection, I finally found what's causing memory corruption > during hibernation on my machine sice 2.6.31: > https://bugzilla.kernel.org/show_bug.cgi?id=15753 > > It's commit c9e444103b5e7a5a3519f9913f59767f92e33baf (mm: reuse unused swap > entry if necessary). > > I don't know anything about swapping in Linux so I don't have a clue what's > wrong with that commit. Thanks for bisecting! This looks rather serious. I'd be grateful from any clues from the mm guys involved (CCed). Do you use s2disk or the built-in hibernation code? Rafael -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo(a)vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
From: Ondrej Zary on 28 Jul 2010 17:40 On Wednesday 28 July 2010 23:34:07 Rafael J. Wysocki wrote: > On Wednesday, July 28, 2010, Ondrej Zary wrote: > > Hello, > > after very long bisection, I finally found what's causing memory > > corruption during hibernation on my machine sice 2.6.31: > > https://bugzilla.kernel.org/show_bug.cgi?id=15753 > > > > It's commit c9e444103b5e7a5a3519f9913f59767f92e33baf (mm: reuse unused > > swap entry if necessary). > > > > I don't know anything about swapping in Linux so I don't have a clue > > what's wrong with that commit. > > Thanks for bisecting! > > This looks rather serious. I'd be grateful from any clues from the mm guys > involved (CCed). > > Do you use s2disk or the built-in hibernation code? I use built-in code (echo disk >/sys/power/state). The machine has 256MB RAM and 256MB swap partition. -- Ondrej Zary -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo(a)vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
From: KAMEZAWA Hiroyuki on 28 Jul 2010 21:20 On Wed, 28 Jul 2010 23:38:09 +0200 Ondrej Zary <linux(a)rainbow-software.org> wrote: > On Wednesday 28 July 2010 23:34:07 Rafael J. Wysocki wrote: > > On Wednesday, July 28, 2010, Ondrej Zary wrote: > > > Hello, > > > after very long bisection, I finally found what's causing memory > > > corruption during hibernation on my machine sice 2.6.31: > > > https://bugzilla.kernel.org/show_bug.cgi?id=15753 > > > > > > It's commit c9e444103b5e7a5a3519f9913f59767f92e33baf (mm: reuse unused > > > swap entry if necessary). > > > > > > I don't know anything about swapping in Linux so I don't have a clue > > > what's wrong with that commit. > > > > Thanks for bisecting! > > > > This looks rather serious. I'd be grateful from any clues from the mm guys > > involved (CCed). > > > > Do you use s2disk or the built-in hibernation code? > > I use built-in code (echo disk >/sys/power/state). The machine has 256MB RAM > and 256MB swap partition. > I don't know much about hibernation but it seems my code break something, sorry. The commit does if swap_map[] shows that there is only SwapCache, no real swap users, try to reuse it by detaching a page from SwapCache. In usual cases, lock_page(page): add_to_swap(page); // assign swap offset and mark as SwapCache try_to_unmap(); // swap's usage count +1 (swap_duplicate()) unlock_page(page); Then, SwapCache will not be reused in usual cases. What code should I look into ? kernel/power/swap.c ?? Thanks, -Kame -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo(a)vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
From: KAMEZAWA Hiroyuki on 28 Jul 2010 23:00
On Thu, 29 Jul 2010 10:06:26 +0900 KAMEZAWA Hiroyuki <kamezawa.hiroyu(a)jp.fujitsu.com> wrote: > On Wed, 28 Jul 2010 23:38:09 +0200 > Ondrej Zary <linux(a)rainbow-software.org> wrote: > > > On Wednesday 28 July 2010 23:34:07 Rafael J. Wysocki wrote: > > > On Wednesday, July 28, 2010, Ondrej Zary wrote: > > > > Hello, > > > > after very long bisection, I finally found what's causing memory > > > > corruption during hibernation on my machine sice 2.6.31: > > > > https://bugzilla.kernel.org/show_bug.cgi?id=15753 > > > > > > > > It's commit c9e444103b5e7a5a3519f9913f59767f92e33baf (mm: reuse unused > > > > swap entry if necessary). > > > > > > > > I don't know anything about swapping in Linux so I don't have a clue > > > > what's wrong with that commit. > > > > > > Thanks for bisecting! > > > > > > This looks rather serious. I'd be grateful from any clues from the mm guys > > > involved (CCed). > > > > > > Do you use s2disk or the built-in hibernation code? > > > > I use built-in code (echo disk >/sys/power/state). The machine has 256MB RAM > > and 256MB swap partition. > > BTW, what happens at resume ? How to page-in and remap ? Thanks, -Kame -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo(a)vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ |