Received: by 2002:a05:6358:489b:b0:bb:da1:e618 with SMTP id x27csp209908rwn; Wed, 14 Sep 2022 19:12:04 -0700 (PDT) X-Google-Smtp-Source: AA6agR7t6ez3vWPHFMuWJ3cN/1IWF+jdTDhWWxGrhfCrg7OWFg9EBTTXN6TleHCKn6sxcK4kAxkn X-Received: by 2002:a17:906:8a45:b0:77c:dd3:cebd with SMTP id gx5-20020a1709068a4500b0077c0dd3cebdmr14616121ejc.668.1663207924418; Wed, 14 Sep 2022 19:12:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1663207924; cv=none; d=google.com; s=arc-20160816; b=0tOM4VUZooI0StWYpbgFSnU3ukDTXdJ2n3WiZ3SOsj1oO/bCgkyl1ArvkBbDRCR1MD 1juvstUDFI7igh0E8HgLe0er8vuaDjJYRT0y+WXQSr0Su5SZnjmydcOzakDJZ2mQ2B2X sfnzlPbsB2FRU9F2GZKhB7ZduHfqA2pcl9QscHLzIKfw2ugzwMUQz3AsJsxOw7/0ijXN 76nK6o66XKxiW2iYarLV6s/FIwe6QUUwzfv0TktCje2oQYVOST7K/qoObjNBV6kvJQLB sk/XanPNnhWEublmzmFecERAiyeR1qDLOwg8vcgtejIv2KNrS9U5mpoYgedkmFwVBHiQ QIrw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:references:message-id :content-transfer-encoding:cc:date:in-reply-to:from:subject :mime-version:dkim-signature; bh=aHrMqKnOhvrceoKDNwr4kJF7nEDwLaJAxZRfEElDacM=; b=EAYZRDarkfCniNgSsMQ8okWeNbDHDZi1Pct/gp23C8AMS04xNDNHunjpJHVY9dfltn Vkk0n6U5x+RbqjIVriW6n4JooCY5WTvvRhqTmgotiOe2s15wHLTgcf3ZsaaQLcZB8g3v qSWvFods8ATfFhOvGYtu2srrXc5X/EXfzec9bv17LtCgDBDj2QPB1kA3QFAVJANuw/Eh Pse4qDpYeX0VecBwaVC67U3GCdyxwPLv398vBhSJem5LgWAlDUOFw+2HUf4viLIvW+33 8RoX2uVfKAN3tX/mcrD13LPo5WxAmybO8veS0EiB6ETntkCWRhOaA/dB87qHAWmmFk9A 80xw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=NOK9QL6c; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f18-20020a50a6d2000000b0044f24b145a3si12145805edc.214.2022.09.14.19.11.39; Wed, 14 Sep 2022 19:12:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=NOK9QL6c; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229885AbiIOBky (ORCPT + 99 others); Wed, 14 Sep 2022 21:40:54 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58396 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229473AbiIOBkv (ORCPT ); Wed, 14 Sep 2022 21:40:51 -0400 Received: from out0.migadu.com (out0.migadu.com [94.23.1.103]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 972D32A25B; Wed, 14 Sep 2022 18:40:48 -0700 (PDT) Content-Type: text/plain; charset=utf-8 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1663206046; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=aHrMqKnOhvrceoKDNwr4kJF7nEDwLaJAxZRfEElDacM=; b=NOK9QL6c//UcrFx6c0l7e3u6T3ikeR3S7RiyaScZazN8wsGha6NRbAbuzX4Cfw2v+zq51Y 7CWGErYlPAkwbIO4kuO4+cMqn8M24j/UIslfY4vEJndq6Dr5HZHgWQgt5QZbpKCgE0E2+f vqonwUNyZXx1RB2YKrAjmb9GjSVqg5M= MIME-Version: 1.0 Subject: Re: [PATCH 03/21] mm/hugetlb: correct demote page offset logic X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Muchun Song In-Reply-To: <20220913195508.3511038-4-opendmb@gmail.com> Date: Thu, 15 Sep 2022 09:40:34 +0800 Cc: Andrew Morton , Jonathan Corbet , Rob Herring , Krzysztof Kozlowski , Frank Rowand , Mike Kravetz , Muchun Song , Mike Rapoport , Christoph Hellwig , Marek Szyprowski , Robin Murphy , Borislav Petkov , "Paul E. McKenney" , Neeraj Upadhyay , Randy Dunlap , Damien Le Moal , Florian Fainelli , David Hildenbrand , Zi Yan , Oscar Salvador , Hari Bathini , Kees Cook , - , KOSAKI Motohiro , Mel Gorman , Linux Doc Mailing List , linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, Linux MM , iommu@lists.linux.dev Content-Transfer-Encoding: quoted-printable Message-Id: <1CA76834-D826-4799-A114-0E27A10D062F@linux.dev> References: <20220913195508.3511038-1-opendmb@gmail.com> <20220913195508.3511038-4-opendmb@gmail.com> To: Doug Berger X-Migadu-Flow: FLOW_OUT X-Migadu-Auth-User: linux.dev X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > On Sep 14, 2022, at 03:54, Doug Berger wrote: >=20 > With gigantic pages it may not be true that struct page structures > are contiguous across the entire gigantic page. The mem_map_offset > function is used here in place of direct pointer arithmetic to > correct for this. >=20 > Fixes: 8531fc6f52f5 ("hugetlb: add hugetlb demote page support") > Signed-off-by: Doug Berger With Matthew=E2=80=99s suggestion. Acked-by: Muchun Song Thanks.