From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B09DA3570A5 for ; Thu, 20 Nov 2025 16:16:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763655410; cv=none; b=gwHOksUuiybaGHlnXJ0ECfOq/pmspgtWca2/nZNnrl0JO9v/y5KtaXf9vk4Y/EYxxAWCtl3Pqd8sAxPZ7GF5Ej+XsT0T4FV/fqTnvo8r73bflujGEVqAEBQMcWMUKgJALC58og/WXOkXYcW8GihWaPPK6w+IRYxntg5S+Qrh89M= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763655410; c=relaxed/simple; bh=M92zrJo15LkoNQeVHbbYAkVceVCaMVDtXlbIX0qD0sE=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=cxoSyp6xt0CAAT/d8l/gTgRzMYaz+EoYMyOE5JB8EQiMCj8GqWqfeziZHOfIShOsrFgyQ+L7wT6k1frDAGdYIaA1BQ5PXpbAUOWaqEewvHqbzDF6kt0iPHxLsP1G8orY/YHZZmNJpSG45nLdvRAyVK5NU4jHvI/EJn3GZLZxIBo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com 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 40762339; Thu, 20 Nov 2025 08:16:40 -0800 (PST) Received: from arm.com (arrakis.cambridge.arm.com [10.1.197.46]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id B71E83F73B; Thu, 20 Nov 2025 08:16:46 -0800 (PST) Date: Thu, 20 Nov 2025 16:16:44 +0000 From: Catalin Marinas To: Ryan Roberts Cc: Yang Shi , will@kernel.org, cl@gentwo.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] arm64: mm: fix direct map use over accounting Message-ID: References: <20251119235706.1944517-1-yang@os.amperecomputing.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: On Thu, Nov 20, 2025 at 03:11:21PM +0000, Ryan Roberts wrote: > On 19/11/2025 23:57, Yang Shi wrote: > > The create_pgd_mapping() families may be used in other paths other than > > creating the linear map. And spliting kernel page table may be used for > > non-linear map either. So we need check whether the address is linear > > map address or not before accounting to direct map use. Encapsulate the > > linear map address check in the new add/sub helpers. The new helpers are > > nop if CONFIG_PROC_FS is not enabled. [...] > Overall, my opinion is that this patch is not quite cooked yet. Personally I'd > prefer to see the first half reverted then we can wait another cycle until this > is ready and apply it all in one go. Thanks for the feedback Ryan. I'll revert and queue it again later once you acked it. -- Catalin