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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 31DA3C4332F for ; Fri, 18 Nov 2022 19:36:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=8QhWLdNTzUPAa8IaCUylagEay73tUgTMvPxhabqc46M=; b=ejldWYKwFxcp/f 0D+aS9OIbLWlkoRKWpNE7TueXSjs6XURL1xsA88FHGW2MorxQZMwq3KKSfgotjBvc4pAGQhX55pdY Y/sT4FV2Ulcnwy/eGQszwaUMYevmyy8i//nTkM6zzsdX3VJMdHvoQGzXZTPSIsU1xFush0CB92DhC zedpRcKUqXibLg8YqhuCb8ppmwK4js6NNQb4qyV6vScg7t1eOjMBubz6aOnpV32bwzydAaXETuXIo fnE17krySrQydKY2XEBLbaNIL2F1LDDsfZzrao8yRveQSCTQWkPO9FPYe/mfEBh95I1Wndha3pVTU qhQ7Badrs57lx8v8qfNQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1ow78r-007c7B-Cq; Fri, 18 Nov 2022 19:35:13 +0000 Received: from ams.source.kernel.org ([145.40.68.75]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1ow78n-007c69-Qs for linux-arm-kernel@lists.infradead.org; Fri, 18 Nov 2022 19:35:11 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 6E796B824FF; Fri, 18 Nov 2022 19:35:08 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2EE61C433C1; Fri, 18 Nov 2022 19:35:05 +0000 (UTC) From: Catalin Marinas To: David Hildenbrand , Pasha Tatashin , Anshuman Khandual , Liu Shixin , Rafael Aquini , Denys Vlasenko , Kefeng Wang , Will Deacon Cc: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: (subset) [PATCH v2 0/2] arm64: fix two bug about page table check Date: Fri, 18 Nov 2022 19:35:02 +0000 Message-Id: <166879995436.2970319.8402648264263746100.b4-ty@arm.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221117075602.2904324-1-liushixin2@huawei.com> References: <20221117075602.2904324-1-liushixin2@huawei.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20221118_113510_033614_761022F5 X-CRM114-Status: GOOD ( 13.33 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, 17 Nov 2022 15:56:00 +0800, Liu Shixin wrote: > Denys Vlasenko has reported two bug about page table check on arm64. > On arm64, pmd_present() contains non-leaf pmd and invalid pmd too. > > When collapse hugepage, the pmd is non-leaf and should skip the check. > Use pmd_leaf() instead of pmd_present(). > > When split hugepage, the pmd will be marked as invalid and then populate. > So we should decrease file_map_count when invalid pmd and then increase > when populate the pmd. Add pmd_valid() check. > > [...] Applied to arm64 (for-next/fixes), thanks! [1/2] arm64/mm: fix incorrect file_map_count for non-leaf pmd/pud https://git.kernel.org/arm64/c/5b47348fc0b1 I only merged the first patch in this series as Will had some questions on the second patch (it does seem weird that the pud and pmd functions are different w.r.t. the p*d_user() checks). -- Catalin _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel