Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757003AbbLAViH (ORCPT ); Tue, 1 Dec 2015 16:38:07 -0500 Received: from mga01.intel.com ([192.55.52.88]:61139 "EHLO mga01.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756185AbbLAViF (ORCPT ); Tue, 1 Dec 2015 16:38:05 -0500 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.20,370,1444719600"; d="scan'208";a="862507888" Date: Tue, 1 Dec 2015 23:38:01 +0200 From: "Kirill A. Shutemov" To: Sasha Levin Cc: Vlastimil Babka , "linux-mm@kvack.org" , LKML Subject: Re: mm: BUG in __munlock_pagevec Message-ID: <20151201213801.GA138207@black.fi.intel.com> References: <565C5C38.3040705@oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <565C5C38.3040705@oracle.com> User-Agent: Mutt/1.5.23.1 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1256 Lines: 38 On Mon, Nov 30, 2015 at 09:24:56AM -0500, Sasha Levin wrote: > Hi all, > > I've hit the following while fuzzing with trinity on the latest -next kernel: > > > [ 850.305385] page:ffffea001a5a0f00 count:0 mapcount:1 mapping:dead000000000400 index:0x1ffffffffff > [ 850.306773] flags: 0x2fffff80000000() > [ 850.307175] page dumped because: VM_BUG_ON_PAGE(1 && PageTail(page)) > [ 850.308027] page_owner info is not active (free page?) Could you check this completely untested patch: diff --git a/mm/mlock.c b/mm/mlock.c index af421d8bd6da..9197b6721a1e 100644 --- a/mm/mlock.c +++ b/mm/mlock.c @@ -393,6 +393,13 @@ static unsigned long __munlock_pagevec_fill(struct pagevec *pvec, if (!page || page_zone_id(page) != zoneid) break; + /* + * Do not use pagevec for PTE-mapped THP, + * munlock_vma_pages_range() will handle them. + */ + if (PageTransCompound(page)) + break; + get_page(page); /* * Increase the address that will be returned *before* the -- Kirill A. Shutemov -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/