From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752006AbcFCHP6 (ORCPT ); Fri, 3 Jun 2016 03:15:58 -0400 Received: from mail-pf0-f194.google.com ([209.85.192.194]:36621 "EHLO mail-pf0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751883AbcFCHP4 (ORCPT ); Fri, 3 Jun 2016 03:15:56 -0400 Date: Fri, 3 Jun 2016 16:15:51 +0900 From: Sergey Senozhatsky To: Michal Hocko Cc: Sergey Senozhatsky , Andrew Morton , Vlastimil Babka , "Kirill A. Shutemov" , Stephen Rothwell , linux-mm@kvack.org, linux-next@vger.kernel.org, linux-kernel@vger.kernel.org, Andrea Arcangeli Subject: Re: [linux-next: Tree for Jun 1] __khugepaged_exit rwsem_down_write_failed lockup Message-ID: <20160603071551.GA453@swordfish> References: <20160601131122.7dbb0a65@canb.auug.org.au> <20160602014835.GA635@swordfish> <20160602092113.GH1995@dhcp22.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20160602092113.GH1995@dhcp22.suse.cz> User-Agent: Mutt/1.6.1 (2016-04-27) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello, On (06/02/16 11:21), Michal Hocko wrote: [..] > @@ -2863,6 +2854,7 @@ static unsigned int khugepaged_scan_mm_slot(unsigned int pages, > > collect_mm_slot(mm_slot); > } > + mmput(mm); > > return progress; > } this possibly sleeping mmput() is called from under the spin_lock(&khugepaged_mm_lock). there is also a trivial build fixup needed (move collect_mm_slot() before __khugepaged_exit()). it's quite hard to trigger the bug (somehow), so I can't follow up with more information as of now. -ss