ao? 2011a1'11ae??29ae?JPY 14:02, KAMEZAWA Hiroyuki a??e??: > > You can't know whether the 'page' is allocated by alloc_page() in fallocate() > or just found as exiting one. > Then, yourwill corrupt existing pages in error path. > Is it allowed ? > According to the comment, /* * shmem_getpage_gfp - find page in cache, or get from swap, or allocate * * If we allocate a new one we do not mark it dirty. That's up to the * vm. If we swap it in we mark it dirty since we also free the swap * entry since a page cannot live in both the swap and page cache */ so we can know if the page is newly allocated by checking page dirty bit. Or am I missing something? But whoops, I sent a wrong version of this patch, the below one is the correct one. Sorry for this.