From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755798Ab3LST0X (ORCPT ); Thu, 19 Dec 2013 14:26:23 -0500 Received: from kanga.kvack.org ([205.233.56.17]:52410 "EHLO kanga.kvack.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754413Ab3LST0W (ORCPT ); Thu, 19 Dec 2013 14:26:22 -0500 Date: Thu, 19 Dec 2013 14:26:21 -0500 From: Benjamin LaHaise To: Linus Torvalds Cc: Kent Overstreet , Dave Jones , Linux Kernel , linux-mm , Christoph Lameter , Al Viro Subject: Re: bad page state in 3.13-rc4 Message-ID: <20131219192621.GA9228@kvack.org> References: <20131219040738.GA10316@redhat.com> <20131219155313.GA25771@redhat.com> <20131219181134.GC25385@kmo-pixel> <20131219182920.GG30640@kvack.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.2i Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Dec 20, 2013 at 04:19:15AM +0900, Linus Torvalds wrote: > Yeah, that looks horribly buggy, if that's the intent. > > You can't just put_page() to remove something from the page cache. You > need to do the whole "remove from radix tree" rigamarole, see for > example delete_from_page_cache(). And you can't even do that blindly, > because if the page is under writeback or otherwise busy, just > removing it from the page cache and freeing it is wrong too. Okay, I'll rewriting it to use truncate to free the pages. -ben > Linus -- "Thought is the essence of where you are now."