From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8DFEEC6FA82 for ; Thu, 15 Sep 2022 02:49:37 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229992AbiIOCtg (ORCPT ); Wed, 14 Sep 2022 22:49:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50818 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229814AbiIOCtd (ORCPT ); Wed, 14 Sep 2022 22:49:33 -0400 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 0D499FF9; Wed, 14 Sep 2022 19:49:28 -0700 (PDT) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 0A66D1063; Wed, 14 Sep 2022 19:49:35 -0700 (PDT) Received: from [10.162.43.6] (unknown [10.162.43.6]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id C76C63F71A; Wed, 14 Sep 2022 19:49:25 -0700 (PDT) Message-ID: Date: Thu, 15 Sep 2022 08:19:22 +0530 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.11.0 Subject: Re: [PATCH] mm/hugetlb: correct demote page offset logic Content-Language: en-US To: Mike Kravetz , Doug Berger , Andrew Morton Cc: Muchun Song , Oscar Salvador , linux-mm@kvack.org, linux-kernel@vger.kernel.org, stable@vger.kernel.org References: <20220914190917.3517663-1-opendmb@gmail.com> From: Anshuman Khandual In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 9/15/22 02:48, Mike Kravetz wrote: > On 09/14/22 12:09, Doug Berger wrote: >> With gigantic pages it may not be true that struct page structures >> are contiguous across the entire gigantic page. The nth_page macro >> is used here in place of direct pointer arithmetic to correct for >> this. >> >> Fixes: 8531fc6f52f5 ("hugetlb: add hugetlb demote page support") >> Signed-off-by: Doug Berger >> Cc: >> --- >> mm/hugetlb.c | 14 ++++++++------ >> 1 file changed, 8 insertions(+), 6 deletions(-) > > Thanks! > > Reviewed-by: Mike Kravetz > > To answer Andrew's question about user-visible runtime effects. > We could get addressing exceptions. However, this is only possible in > configurations where CONFIG_SPARSEMEM && !CONFIG_SPARSEMEM_VMEMMAP. > Such a configuration option is rare an unknown to be the default > anywhere. In that case, should this be a 'Cc: stable' ? Although it does fix the above mentioned commit for a possible configuration. But should this be backported, if there could not have been an affected system ?