lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <e7f80acd-623b-4fda-9292-6f8344d0f185@arm.com>
Date: Fri, 14 Feb 2025 12:47:31 +0530
From: Anshuman Khandual <anshuman.khandual@....com>
To: Christophe Leroy <christophe.leroy@...roup.eu>, linux-mm@...ck.org
Cc: steven.price@....com, Catalin Marinas <catalin.marinas@....com>,
 Will Deacon <will@...nel.org>, Jonathan Corbet <corbet@....net>,
 Marc Zyngier <maz@...nel.org>, Michael Ellerman <mpe@...erman.id.au>,
 Nicholas Piggin <npiggin@...il.com>, Paul Walmsley
 <paul.walmsley@...ive.com>, Palmer Dabbelt <palmer@...belt.com>,
 Heiko Carstens <hca@...ux.ibm.com>, Vasily Gorbik <gor@...ux.ibm.com>,
 Thomas Gleixner <tglx@...utronix.de>, Ingo Molnar <mingo@...hat.com>,
 Andrew Morton <akpm@...ux-foundation.org>,
 linux-arm-kernel@...ts.infradead.org, linux-doc@...r.kernel.org,
 linux-kernel@...r.kernel.org, kvmarm@...ts.linux.dev,
 linuxppc-dev@...ts.ozlabs.org, linux-riscv@...ts.infradead.org,
 linux-s390@...r.kernel.org
Subject: Re: [PATCH 4/4] mm: Rename GENERIC_PTDUMP and PTDUMP_CORE

On 2/13/25 13:08, Christophe Leroy wrote:
> 
> 
> Le 13/02/2025 à 05:09, Anshuman Khandual a écrit :
>> Platforms subscribe into generic ptdump implementation via GENERIC_PTDUMP.
>> But generic ptdump gets enabled via PTDUMP_CORE. These configs combination
>> is confusing as they sound very similar and does not differentiate between
>> platform's feature subscription and feature enablement for ptdump. Rename
>> the configs as ARCH_HAS_PTDUMP and PTDUMP making it more clear and improve
>> readability.
> 
> For me GENERIC_PTDUMP is more explicit and similar to GENERIC_IOMAP or GENERIC_IOREMAP or GENERIC_GETTIMEOFDAY: The arch provides the necessary helpers to use the generic implementation.

I do realize that GENERIC_ is another method for achieving shared
feature across multiple platforms via providing necessary helpers.
But I guess there might be a difference - it might not have other
similar but separate dependent configs ?

> 
> For me ARCH_HAS_PTDUMP just mean't that an architecture implements PTDUMP, it doesn't mean it does it by using the generic infrastructure.

ARCH_HAS_XXX indicates that an architecture subscribes to a generic
feature XXX, by implementing all necessary helpers. But the feature
in itself is a generic and a shared one.

If the platform were to implement a feature on its own without any
generic component, it could do that via a separate platform specific
config without requiring ARCH_HAS_XXX based subscription indication.

> 
> For instance, arm32 implements PTDUMP but without using the generic one so I would say that arm32 has PTDUMP and expect it to select ARCH_HAS_PTDUMP

Actually it does not need to select ARCH_HAS_PTDUMP, as it does not
subscribe into generic PTDUMP. Let's see PTDUMP configs on arm (32)

ARM_PTDUMP_CORE
ARM_PTDUMP_DEBUGFS	--> select ARM_PTDUMP_CORE
ARM_DEBUG_WX 		--> select ARM_PTDUMP_CORE

The platform has a self contained PTDUMP implementation which does
not depend on generic PTDUMP at all. Hence all these ptdump configs
are marked as ARM_ etc as they are platform specific.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ