From patchwork Tue Nov 8 14:09:09 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Catalin Marinas X-Patchwork-Id: 81330 Delivered-To: patch@linaro.org Received: by 10.182.113.165 with SMTP id iz5csp1714225obb; Tue, 8 Nov 2016 06:09:29 -0800 (PST) X-Received: by 10.98.33.133 with SMTP id o5mr23553532pfj.32.1478614169109; Tue, 08 Nov 2016 06:09:29 -0800 (PST) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t65si37150235pfb.51.2016.11.08.06.09.28; Tue, 08 Nov 2016 06:09:29 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752871AbcKHOJQ (ORCPT + 27 others); Tue, 8 Nov 2016 09:09:16 -0500 Received: from foss.arm.com ([217.140.101.70]:60752 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751134AbcKHOJO (ORCPT ); Tue, 8 Nov 2016 09:09:14 -0500 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id DE5EDCF6; Tue, 8 Nov 2016 06:09:13 -0800 (PST) Received: from e104818-lin.cambridge.arm.com (e104818-lin.cambridge.arm.com [10.1.206.48]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 76C943F25D; Tue, 8 Nov 2016 06:09:12 -0800 (PST) Date: Tue, 8 Nov 2016 14:09:09 +0000 From: Catalin Marinas To: Huang Shijie Cc: dwoods@mellanox.com, steve.capper@arm.com, will.deacon@arm.com, linux-kernel@vger.kernel.org, kaly.xin@arm.com, akpm@linux-foundation.org, nd@arm.com, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH v2 0/2] arm64: fix the bugs found in the hugetlb test Message-ID: <20161108140909.GF29087@e104818-lin.cambridge.arm.com> References: <1478583879-14654-1-git-send-email-shijie.huang@arm.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <1478583879-14654-1-git-send-email-shijie.huang@arm.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Nov 08, 2016 at 01:44:37PM +0800, Huang Shijie wrote: > (3) The test result in the Softiron and Juno-r1 boards: > > This detail test result shows below (both the "make func" & "make stress"): > > 4KB granule: > > 1.1) PTE + Contiguous bit : 4K x 16 = 64K (per huge page size) > Test result : PASS > > 1.2) PMD : 2M x 1 = 2M (per huge page size) > Test result : PASS > > 1.3) PMD + Contiguous bit : 2M x 16 = 32M (per huge page size) > Test result : PASS > > 64KB granule: > > 3.1) PTE + Contiguous bit : 64K x 32 = 2M (per huge page size) > Test result : PASS > > 3.2) PMD + Contiguous bit : 512M x 32 = 16G (per huge page size) > Test result : no hardware to support this test Don't we have support for single (non-contiguous) PMD huge page with 64K pages (512M per huge page)? I gave it a try and it seems to work (though without your patches applied ;)). > Huang Shijie (2): > arm64: hugetlb: remove the wrong pmd check in find_num_contig() > arm64: hugetlb: fix the wrong address for several functions For these patches: Reviewed-by: Catalin Marinas I'm not sure whether Will plans to push them into 4.9. AFAICT, the contiguous huge pages never worked properly, so we may not count it as a regression but a new feature. If Will doesn't take them, I'll queue the patches for 4.10. BTW, I think we also need to fix this (no functional change though): -- Catalin diff --git a/arch/arm64/mm/hugetlbpage.c b/arch/arm64/mm/hugetlbpage.c index 2e49bd252fe7..0a4c97b618ec 100644 --- a/arch/arm64/mm/hugetlbpage.c +++ b/arch/arm64/mm/hugetlbpage.c @@ -323,7 +323,7 @@ __setup("hugepagesz=", setup_hugepagesz); static __init int add_default_hugepagesz(void) { if (size_to_hstate(CONT_PTES * PAGE_SIZE) == NULL) - hugetlb_add_hstate(CONT_PMD_SHIFT); + hugetlb_add_hstate(CONT_PTE_SHIFT); return 0; } arch_initcall(add_default_hugepagesz);