From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from psmtp.com (na3sys010amx196.postini.com [74.125.245.196]) by kanga.kvack.org (Postfix) with SMTP id EB7C86B0036 for ; Wed, 24 Jul 2013 14:52:43 -0400 (EDT) Message-ID: <51F02273.1050308@parallels.com> Date: Wed, 24 Jul 2013 22:52:35 +0400 From: Pavel Emelyanov MIME-Version: 1.0 Subject: Re: [PATCH] mm: Save soft-dirty bits on swapped pages References: <20130724160826.GD24851@moon> In-Reply-To: <20130724160826.GD24851@moon> Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit Sender: owner-linux-mm@kvack.org List-ID: To: Cyrill Gorcunov , Andrew Morton Cc: Linux MM , LKML , Andy Lutomirski , Matt Mackall , Xiao Guangrong , Marcelo Tosatti , KOSAKI Motohiro , Stephen Rothwell On 07/24/2013 08:08 PM, Cyrill Gorcunov wrote: > Andy Lutomirski reported that in case if a page with _PAGE_SOFT_DIRTY > bit set get swapped out, the bit is getting lost and no longer > available when pte read back. > > To resolve this we introduce _PTE_SWP_SOFT_DIRTY bit which is > saved in pte entry for the page being swapped out. When such page > is to be read back from a swap cache we check for bit presence > and if it's there we clear it and restore the former _PAGE_SOFT_DIRTY > bit back. > > One of the problem was to find a place in pte entry where we can > save the _PTE_SWP_SOFT_DIRTY bit while page is in swap. The > _PAGE_PSE was chosen for that, it doesn't intersect with swap > entry format stored in pte. > > Reported-by: Andy Lutomirski > Signed-off-by: Pavel Emelyanov > Signed-off-by: Cyrill Gorcunov > Cc: Andrew Morton > Cc: Matt Mackall > Cc: Xiao Guangrong > Cc: Marcelo Tosatti > Cc: KOSAKI Motohiro > Cc: Stephen Rothwell Acked-by: Pavel Emelyanov -- 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: email@kvack.org