[Top] [All Lists]

Re: [PATCH, RESEND] asm-generic, mm: pgtable: consolidate zero page help

To: "Kirill A. Shutemov" <>
Subject: Re: [PATCH, RESEND] asm-generic, mm: pgtable: consolidate zero page helpers
From: David Rientjes <>
Date: Wed, 12 Dec 2012 14:54:55 -0800 (PST)
Cc: Andrew Morton <>,, Arnd Bergmann <>,,, Martin Schwidefsky <>, Heiko Carstens <>,, Ralf Baechle <>, John Crispin <>
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed;; s=20120113; h=date:from:x-x-sender:to:cc:subject:in-reply-to:message-id :references:user-agent:mime-version:content-type; bh=05+xC4fgB6q12pou/KeBZJUaZRI19bHQ4h7zg86XZ/Q=; b=jaXxxHKtcWHNODDn+0qAT+oKB3ptWEM88mymZquMWmHrY2KzJeBzSztGr73GGjgl1v 8ATpnsftrFJHUK4JfE98oBf598bvl0+c9SDh4qi05a0quLJ/lQRJ5Ap+5zK3gnQDWJwf Ql0LDd6XgctRDsogyD4v1beaB3Wv3EFuAT14P7VEHK69tCsr94PBb2+QkMPYuXupGu5B 1pJqNw0Mxkcw157zqtB3SlSqLmfPejsfCYuHY3UY4p5LpCS/m2KaCfP1Tvl2aSsN78/U SC/RTM6dqIdF+bWFwWqu8JINNy2C8UB8fV3uvCmpt6puUf8lWRPGAiQgzJIug6x0vtlY Qvzg==
In-reply-to: <20121212105538.GA14208@otc-wbsnb-06>
List-archive: <>
List-help: <>
List-id: linux-mips <>
List-owner: <>
List-post: <>
List-software: Ecartis version 1.0.0
List-subscribe: <>
List-unsubscribe: <>
References: <> <> <20121212105538.GA14208@otc-wbsnb-06>
User-agent: Alpine 2.00 (DEB 1167 2008-08-23)
On Wed, 12 Dec 2012, Kirill A. Shutemov wrote:

> > What's the benefit from doing this other than generalizing some per-arch 
> > code?  It simply adds on more layer of redirection to try to find the 
> > implementation that matters for the architecture you're hacking on.
> The idea of asm-generic is consolidation arch code which can be re-used
> for different arches. It also makes support of new arches easier.

Yeah, but you're moving is_zero_pfn() unnecessarily into a header file 
when it is only used mm/memory.c and it adds a __HAVE_* definition that we 
always try to reduce (both __HAVE and __ARCH definitions are frowned 
upon).  I don't think it's much of a win to obfuscate the code because 
mips and s390 implement colored zero pages.

<Prev in Thread] Current Thread [Next in Thread>