From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.linuxfoundation.org ([140.211.169.12]:59224 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750731AbdLLIcC (ORCPT ); Tue, 12 Dec 2017 03:32:02 -0500 Date: Tue, 12 Dec 2017 09:32:09 +0100 From: Greg Kroah-Hartman To: Jinpu Wang Cc: "Kirill A. Shutemov" , Andrea Arcangeli , Hillf Danton , stable , Andrew Morton , Linus Torvalds Subject: Re: [PATCH 1/3] thp: reduce indentation level in change_huge_pmd() Message-ID: <20171212083209.GF22935@kroah.com> References: <1512642172-7981-1-git-send-email-jinpu.wangl@profitbricks.com> <1512642172-7981-2-git-send-email-jinpu.wangl@profitbricks.com> <20171207120501.GA6159@kroah.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Sender: stable-owner@vger.kernel.org List-ID: On Thu, Dec 07, 2017 at 01:25:19PM +0100, Jinpu Wang wrote: > On Thu, Dec 7, 2017 at 1:05 PM, Greg Kroah-Hartman > wrote: > > On Thu, Dec 07, 2017 at 11:22:50AM +0100, Jack Wang wrote: > >> From: "Kirill A. Shutemov" > >> > >> commit 0a85e51d37645e9ce57e5e1a30859e07810ed07c upstream. > >> > >> Patch series "thp: fix few MADV_DONTNEED races" > >> > >> For MADV_DONTNEED to work properly with huge pages, it's critical to not > >> clear pmd intermittently unless you hold down_write(mmap_sem). > >> > >> Otherwise MADV_DONTNEED can miss the THP which can lead to userspace > >> breakage. > >> > >> See example of such race in commit message of patch 2/4. > >> > >> All these races are found by code inspection. I haven't seen them > >> triggered. I don't think it's worth to apply them to stable@. > >> > >> This patch (of 4): > > > > What about all 4 of these? > The 4 patches were from here: > http://lkml.iu.edu/hypermail/linux/kernel/1703.0/01274.html > > thp: reduce indentation level in change_huge_pmd() > thp: fix MADV_DONTNEED vs. numa balancing race > thp: fix MADV_DONTNEED vs. MADV_FREE race (the function exists only since 4.5+ ) > thp: fix MADV_DONTNEED vs clear soft dirty race (this one already > included since 4.4.63) > > > > > And should this also go into 4.9? I don't want to include fixes into > > 4.4-stable without them also being in 4.9-stable, as that would be a > > regression for people upgrading. > In 4.9, the last 2 were already applied, I will try to backport these > 3 commits also to 4.9 stable. Thanks for all of these now, all queued up. greg k-h