Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp1221445pxj; Fri, 4 Jun 2021 08:56:41 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzFO/MyGyNGTjJzY2O4sp1+VBmchXZ96n0KkMaqPJ9QNCAN3V0Kezub9n9PkHal8YpjLoxQ X-Received: by 2002:aa7:dd14:: with SMTP id i20mr5520488edv.110.1622822201096; Fri, 04 Jun 2021 08:56:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1622822201; cv=none; d=google.com; s=arc-20160816; b=HCcFviTRIcFNyL4n5U/NbfqbIEWW/o7irRKOAs51+SXI+n8nH1fIpOwhCvJNkyW9ha l3y4Rqb1ymrcOqOG7bgXdbywzJSC8CZp9UeJKz2t2TGTOl4/kwm+RqP6DFA3o35hTxET ZriSytAK3+OL5/d1tuUw+NRC4ibf9ZsXbs6mn/eGvSf4VuhRsgTu0RLhMbNfupSNeCAq EPLsGI2t77nckBy4V5US7DwbKt/EA/5+WX2gk+PZIgxJqS+kWczz2HKQWypNF2DmCO1B dG9AA1g/CLA4kKXCoDU1R/B/XHK+x4FwjB+4H/OVgQ2mW3JQWiuVqctjR3stzNG7RvSG lfvg== 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=oFCNS8GD7XvNmkv9HevhbndY3QsLqxRxLrMyqE667So=; b=lTN9cPfNHBzr6qa9+D22UL59zFi6l4ZbdtZGUD3umKM8DmJ3rtDB5OGcLBUNKaB3wK qzGpnUcN50vaPSKtI4MHSS59sUzFBlHUkRLIH0ZPcp23pQPDUSQS+BHUz3CwH6D6l47i XprNZyWCdQwC1V2phPoOTeLQLrGOzXbuqhUir9+Es1B0aqK42QFUMH8DLjcDpe5pE1ID q3GTJlI8IOdX8/7bfpId7cMJauSwDiZEeCnIV5gfm/bGcxqrrTEVeLoFvn4ADDA4ffy6 gqKEFs43qatnb0HQWvfXXU2PHZHhWHkNuGU4a9AAlvuOJxjhJRM9UcVOxrpuIgIyMGg1 ZDsg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@shutemov-name.20150623.gappssmtp.com header.s=20150623 header.b=UbOamRQH; 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 n1si5194182eja.710.2021.06.04.08.56.18; Fri, 04 Jun 2021 08:56:41 -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=@shutemov-name.20150623.gappssmtp.com header.s=20150623 header.b=UbOamRQH; 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 S231286AbhFDP5L (ORCPT + 99 others); Fri, 4 Jun 2021 11:57:11 -0400 Received: from mail-lj1-f176.google.com ([209.85.208.176]:42731 "EHLO mail-lj1-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229924AbhFDP5K (ORCPT ); Fri, 4 Jun 2021 11:57:10 -0400 Received: by mail-lj1-f176.google.com with SMTP id a4so12160192ljq.9 for ; Fri, 04 Jun 2021 08:55:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=shutemov-name.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=oFCNS8GD7XvNmkv9HevhbndY3QsLqxRxLrMyqE667So=; b=UbOamRQHTZORVcXzhrMn/JyMDM+zIvF6b53/bvhyd4Z6Z+1vnCWIG5EUV4KwH20QQB dtyHuIrAJX1kPAafBIXocSAdE57/cmfu2mW1cNn4jAR2ykCkvgFzpvPrfkFaovSXgDab 00bqljuG+JwZrwO/9hYvcFYeel1GtYmrq34SU3fDfWS2+htGxnml5R1Hr7jMDrgVWuEN FipvcGl5PvEb/pukv9AEvBurqWxdSon+MWxcgF/B3QCRn1AEnuvVlXMoCOt6nBrvva85 eyuoN4uT53nlRD2IJ5MLjbugLz1YWD/LsFyqM8wrymTHxG2v6OIpy6IQRv/nkLXtAHel j+Ew== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=oFCNS8GD7XvNmkv9HevhbndY3QsLqxRxLrMyqE667So=; b=EONvB8CrTTdXsJg6lAaUcINwmFxCnN9sZlALevYscS6Z+TnaNd+Jxi68iB2NmhevUT p8R56q33GrfY88MbVxW9rFVciX0IKS/ogdZTkGrRlJ0+LkRcYjfBT7oiOb5Vs5FTZs+d awDxtO+8Hclq9WEDQZ7XAoEYaoutsaTS4Q4iG0i5B4pI9sSN9Q35cLcCLrSGXpC20efr 1BQnmO2dsQYTeYQ+Vinjq6ngsnENisG/e0600uBlvQYupMUzSsYpCZBMr5ZeT2C++gPr XM8TWFBSZH3hitQ5hTDtiKJnK03ZtU9W4ARAwgGOvKVUecFVMs6OwdkydVnXe7O/VEgE Euaw== X-Gm-Message-State: AOAM5307QA27bz0ye+Hi67TpXe6PODUV3aaqZy3C2GXVOXWTcDWihpZd daQPZftLQa7SrecbVuwRSJbdnw== X-Received: by 2002:a2e:b60d:: with SMTP id r13mr4103967ljn.220.1622822063167; Fri, 04 Jun 2021 08:54:23 -0700 (PDT) Received: from box.localdomain ([86.57.175.117]) by smtp.gmail.com with ESMTPSA id v1sm646109lfq.284.2021.06.04.08.54.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 04 Jun 2021 08:54:22 -0700 (PDT) Received: by box.localdomain (Postfix, from userid 1000) id E0D401027A9; Fri, 4 Jun 2021 18:54:34 +0300 (+03) Date: Fri, 4 Jun 2021 18:54:34 +0300 From: "Kirill A. Shutemov" To: Hugh Dickins Cc: Andrew Morton , "Kirill A. Shutemov" , Yang Shi , Wang Yugui , Matthew Wilcox , 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: <20210604155434.uexotqaf5dmh3ygj@box.shutemov.name> 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: Acked-by: Kirill A. Shutemov -- Kirill A. Shutemov