Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751081AbcDPEzV (ORCPT ); Sat, 16 Apr 2016 00:55:21 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:58694 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750791AbcDPEzV (ORCPT ); Sat, 16 Apr 2016 00:55:21 -0400 Date: Fri, 15 Apr 2016 21:55:19 -0700 From: Andrew Morton To: Matthew Wilcox Cc: Hugh Dickins , "Kirill A. Shutemov" , Andrea Arcangeli , Andres Lagar-Cavilla , Yang Shi , Ning Qu , David Rientjes , linux-kernel@vger.kernel.org, linux-mm@kvack.org Subject: Re: [PATCH 09/10] huge pagecache: mmap_sem is unlocked when truncation splits pmd Message-Id: <20160415215519.98f179c7418d4d2e9b316240@linux-foundation.org> In-Reply-To: <20160414173922.GE3120@linux.intel.com> References: <20160414173922.GE3120@linux.intel.com> X-Mailer: Sylpheed 3.4.2 (GTK+ 2.24.28; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 542 Lines: 13 On Thu, 14 Apr 2016 13:39:22 -0400 Matthew Wilcox wrote: > On Tue, Apr 05, 2016 at 01:55:23PM -0700, Hugh Dickins wrote: > > zap_pmd_range()'s CONFIG_DEBUG_VM !rwsem_is_locked(&mmap_sem) BUG() > > will be invalid with huge pagecache, in whatever way it is implemented: > > truncation of a hugely-mapped file to an unhugely-aligned size would > > easily hit it. > > We can reproduce this BUG() in the current Linus tree with DAX PMDs. > Andrew, can you send this patch to Linus for inclusion in 4.7? Wilco, thanks.