Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp40095pxj; Tue, 1 Jun 2021 14:36:07 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw/pwkDvqNP7G51db3wlJg3rCBrfPuLA1rcikUQTR///7YyAFPV0jnVWWVZyoJYs0Ovuisx X-Received: by 2002:a17:906:7f8d:: with SMTP id f13mr13765960ejr.272.1622583367360; Tue, 01 Jun 2021 14:36:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1622583367; cv=none; d=google.com; s=arc-20160816; b=iFk7lAVtDbRQz2gdQn0jNnG7sh4DRzrRMvLtIWXBewxspVCQiqt/+AwUW+zA2Q38su 2JIeWcFchReU0IKxe5W0WrwhPfB+b19ZHP49jBwpKzp3Xql2YAdr/iBd2jguROEjLdLS P1cw6VwuB+SKfnBHr0wFitIbC4/WYUs8uZ1gwpx6CL8ZPtvh+RXhYyEnELwmRPa7mBmT fozvVd4I6B2LADNy2fd7vX/6R1tmd3jcZ0ggpurCm9yrTKwZd8/0QDMhINEOTrdTcLw3 cJqTomfR0yi9OiAhgmdO6XS8yjrvO+cyxdZ3ensmwvmO+w0ru2fJn9uvoeksKGdBogdD z16Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=VtQlTRq3lnMUDQP6n+cCL3Pr5EYfmGRzRcuenjvwhbg=; b=ETsyWP+b1WB7R8+cSXMQ2bvAO5pbfwyIhF7uWc8o/h3mMkbibgs5ZAE46UGe6FI2wY T6e3gGEO0aQ8sNiSINwkLzDN3pIYJit5EIjxzT0RiPJc61rKO7ZoguYgDNyTI3N+k7i/ UxrAgUw9I8YBO2WYptXgPrZc9xcTVBMalceQ7XdpfrBiUxmHcw9N4WSS5ufHH/lPcvky FUOaAbJOqX6AAotNhaqQ9GvcYobxJpys8GwIsB3EQtVxV7qUthkbwsd++ei5M+dvWOZH LyFFa0f7yHQdug8haf0bo2CaD0X7CMIDNGz+w6FcNWJOkKso4ai1OWCLs/NAzqV2o1IV EAqA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=jSvFOe6o; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id rh9si19252061ejb.139.2021.06.01.14.35.43; Tue, 01 Jun 2021 14:36:07 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=jSvFOe6o; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234818AbhFAVfT (ORCPT + 99 others); Tue, 1 Jun 2021 17:35:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37390 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234747AbhFAVfR (ORCPT ); Tue, 1 Jun 2021 17:35:17 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 14299C061574 for ; Tue, 1 Jun 2021 14:33:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=VtQlTRq3lnMUDQP6n+cCL3Pr5EYfmGRzRcuenjvwhbg=; b=jSvFOe6oQvEot8Hy2t2tjZ0oly +rAFW4iWTtIqeDktq4WT7ML2dlJCIplA38nSg/xAGJY75rlRjDfLqPbXQrdXnrp0L4LnkpenIQItQ cRDow56xi46pK/14vztTUe4E1B4LcEngFPWGqOXgFUL6kNx1eaC7OyXbF3Lxg0JD0cbXsB2SRlS+k FOFkai8VEjxQjw7PCuFVE+7Ph6a/TpMfz0V/18nzZ7I4qphlSN5LAddPVzvsB4J5v9pJ6xkLJPw2U yys9VKEnH6YavCFZ4wJOD7v69DJ8bRArY2dFpZl0bhAgQqsxtkvo5fOa1mEWf5/3rcYyuuOiVmt3s JQk0VzXg==; Received: from willy by casper.infradead.org with local (Exim 4.94 #2 (Red Hat Linux)) id 1loC0F-00ASGe-N8; Tue, 01 Jun 2021 21:32:50 +0000 Date: Tue, 1 Jun 2021 22:32:47 +0100 From: Matthew Wilcox To: Hugh Dickins Cc: Andrew Morton , "Kirill A. Shutemov" , Yang Shi , Wang Yugui , Naoya Horiguchi , Alistair Popple , Ralph Campbell , Zi Yan , Miaohe Lin , Minchan Kim , Jue Wang , Peter Xu , Jan Kara , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 4/7] mm/thp: fix page_address_in_vma() on file THP tails Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jun 01, 2021 at 02:11:22PM -0700, Hugh Dickins wrote: > From: Jue Wang > > Anon THP tails were already supported, but memory-failure may need to use > page_address_in_vma() on file THP tails, which its page->mapping check did > not permit: fix it. > > hughd adds: no current usage is known to hit the issue, but this does fix > a subtle trap in a general helper: best fixed in stable sooner than later. > > Fixes: 800d8c63b2e9 ("shmem: add huge pages support") > Signed-off-by: Jue Wang > Signed-off-by: Hugh Dickins > Cc: Reviewed-by: Matthew Wilcox (Oracle)