lkml.org 
[lkml]   [2008]   [Sep]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 1/4] memcg: account swap cache under lock
KAMEZAWA Hiroyuki wrote:
> While page-cache's charge/uncharge is done under page_lock(), swap-cache
> isn't. (anonymous page is charged when it's newly allocated.)
>
> This patch moves do_swap_page()'s charge() call under lock.
> I don't see any bad problem *now* but this fix will be good for future
> for avoiding unneccesary racy state.
>
>
> Changelog: (v5) -> (v6)
> - mark_page_accessed() is moved before lock_page().
> - fixed missing unlock_page()
> (no changes in previous version)

Looks good to me

Acked-by: Balbir Singh <balbir@linux.vnet.ibm.com>

--
Balbir


\
 
 \ /
  Last update: 2008-09-30 10:29    [W:0.089 / U:0.264 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site