From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933856AbcECRDD (ORCPT ); Tue, 3 May 2016 13:03:03 -0400 Received: from e38.co.us.ibm.com ([32.97.110.159]:36056 "EHLO e38.co.us.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756048AbcECRDB (ORCPT ); Tue, 3 May 2016 13:03:01 -0400 X-IBM-Helo: d03dlp03.boulder.ibm.com X-IBM-MailFrom: arbab@linux.vnet.ibm.com X-IBM-RcptTo: arnd@arndb.de;hannes@cmpxchg.org;hughd@google.com;rientjes@google.com;linux-mm@kvack.org;iamjoonsoo.kim@lge.com;akpm@linux-foundation.org;kirill.shutemov@linux.intel.com;aarcange@redhat.com;riel@redhat.com;mhocko@suse.com;vbabka@suse.cz;mgorman@techsingularity.net;linux-kernel@vger.kernel.org;paul.gortmaker@windriver.com Date: Tue, 3 May 2016 12:02:47 -0500 From: Reza Arbab To: Vlastimil Babka , Arnd Bergmann , Paul Gortmaker , Andrew Morton Cc: Andrea Arcangeli , "Kirill A. Shutemov" , Rik van Riel , Joonsoo Kim , Mel Gorman , David Rientjes , Michal Hocko , Johannes Weiner , Hugh Dickins , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: kcompactd hang during memory offlining Message-ID: <20160503170247.GA4239@arbab-laptop.austin.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline Organization: IBM Linux Technology Center User-Agent: Mutt/1.5.21 (2010-09-15) X-TM-AS-GCONF: 00 X-Content-Scanned: Fidelis XPS MAILER x-cbid: 16050317-0029-0000-0000-000027850707 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Assume memory47 is the last online block left in node1. This will hang: # echo offline > /sys/devices/system/node/node1/memory47/state After a couple of minutes, the following pops up in dmesg: INFO: task bash:957 blocked for more than 120 seconds. Not tainted 4.6.0-rc6+ #6 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. bash D ffff8800b7adbaf8 0 957 951 0x00000000 ffff8800b7adbaf8 ffff880034d5b880 ffff8800b698d4c0 ffff8800b7adc000 7fffffffffffffff ffff88003381ff10 ffff8800b698d4c0 0000000000180000 ffff8800b7adbb10 ffffffff817be0b5 ffff88003381ff08 ffff8800b7adbbc0 Call Trace: [] schedule+0x35/0x80 [] schedule_timeout+0x1ac/0x270 [] ? check_preempt_wakeup+0x100/0x220 [] ? check_preempt_curr+0x80/0x90 [] wait_for_completion+0xe1/0x120 [] ? wake_up_q+0x70/0x70 [] kthread_stop+0x4f/0x110 [] kcompactd_stop+0x26/0x40 [] __offline_pages.constprop.28+0x7e6/0x840 [] offline_pages+0x11/0x20 [] memory_block_action+0x73/0x1d0 [] memory_subsys_offline+0x47/0x60 [] device_offline+0x86/0xb0 [] store_mem_state+0xda/0xf0 [] dev_attr_store+0x18/0x30 [] sysfs_kf_write+0x37/0x40 [] kernfs_fop_write+0x11d/0x170 [] __vfs_write+0x37/0x120 [] ? security_file_permission+0x3d/0xc0 [] ? percpu_down_read+0x12/0x50 [] vfs_write+0xa9/0x1a0 [] ? security_file_fcntl+0x43/0x60 [] SyS_write+0x55/0xc0 [] entry_SYSCALL_64_fastpath+0x1a/0xa4 Bisect ends on commit 698b1b306 ("mm, compaction: introduce kcompactd"). -- Reza Arbab