From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758422AbbDWWLW (ORCPT ); Thu, 23 Apr 2015 18:11:22 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:36030 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751022AbbDWWLU (ORCPT ); Thu, 23 Apr 2015 18:11:20 -0400 Date: Thu, 23 Apr 2015 15:11:18 -0700 From: Andrew Morton To: Zhang Zhen Cc: Linux MM , Linux Kernel Mailing List , , , , , , , , , David Rientjes , , Subject: Re: [PATCH] mm/hugetlb: reduce arch dependent code about huge_pmd_unshare Message-Id: <20150423151118.40c41fb1810f2aaa877163ae@linux-foundation.org> In-Reply-To: <552CC328.9050402@huawei.com> References: <1428996566-86763-1-git-send-email-zhenzhang.zhang@huawei.com> <552CC328.9050402@huawei.com> X-Mailer: Sylpheed 3.4.1 (GTK+ 2.24.23; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 14 Apr 2015 15:35:04 +0800 Zhang Zhen wrote: > Currently we have many duplicates in definitions of huge_pmd_unshare. > In all architectures this function just returns 0 when > CONFIG_ARCH_WANT_HUGE_PMD_SHARE is N. > > This patch put the default implementation in mm/hugetlb.c and lets > these architecture use the common code. Memory fails me. Why do some architectures (arm, arm64, x86_64) want huge_pmd_[un]share() while other architectures (ia64, tile, mips, powerpc, metag, sh, s390) do not?