From patchwork Thu Mar 23 10:52:38 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chaitanya S Prakash X-Patchwork-Id: 13185503 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id BBFA3C76195 for ; Thu, 23 Mar 2023 10:53:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231534AbjCWKxs (ORCPT ); Thu, 23 Mar 2023 06:53:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39744 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230038AbjCWKx3 (ORCPT ); Thu, 23 Mar 2023 06:53:29 -0400 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 127031A8; Thu, 23 Mar 2023 03:52:56 -0700 (PDT) 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 D4BE24B3; Thu, 23 Mar 2023 03:53:39 -0700 (PDT) Received: from a077209.blr.arm.com (a077209.arm.com [10.162.40.145]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 45A803F766; Thu, 23 Mar 2023 03:52:53 -0700 (PDT) From: Chaitanya S Prakash To: linux-mm@kvack.org, linux-kernel@vger.kernel.org Cc: Chaitanya S Prakash , Andrew Morton , "Aneesh Kumar K . V" , "Kirill A . Shutemov" , Shuah Khan , linux-kselftest@vger.kernel.org Subject: [PATCH 0/5] selftests/mm: Implement support for arm64 on va Date: Thu, 23 Mar 2023 16:22:38 +0530 Message-Id: <20230323105243.2807166-1-chaitanyas.prakash@arm.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-kselftest@vger.kernel.org The va_128TBswitch selftest is designed and implemented for PowerPC and x86 architectures which support a 128TB switch, up to 256TB of virtual address space and hugepage sizes of 16MB and 2MB respectively. Arm64 platforms on the other hand support a 256Tb switch, up to 4PB of virtual address space and a default hugepage size of 512MB when 64k pagesize is enabled. These architectural differences require introducing support for arm64 platforms, after which a more generic naming convention is suggested. The in code comments are amended to provide a more platform independent explanation of the working of the code and nr_hugepages are configured as required. Finally, the file running the testcase is modified in order to prevent skipping of hugetlb testcases of va_high_addr_switch. This series has been tested on 6.3.0-rc3 kernel, both on arm64 and x86 platforms. Cc: Andrew Morton Cc: Aneesh Kumar K.V Cc: Kirill A. Shutemov Cc: Shuah Khan Cc: linux-mm@kvack.org Cc: linux-kselftest@vger.kernel.org Cc: linux-kernel@vger.kernel.org Chaitanya S Prakash (5): selftests/mm: Add support for arm64 platform on va switch selftests/mm: Rename va_128TBswitch to va_high_addr_switch selftests/mm: Add platform independent in code comments selftests/mm: Configure nr_hugepages for arm64 selftests/mm: Run hugetlb testcases of va switch tools/testing/selftests/mm/Makefile | 4 +- tools/testing/selftests/mm/run_vmtests.sh | 12 +++++- ...va_128TBswitch.c => va_high_addr_switch.c} | 41 +++++++++++++++---- ..._128TBswitch.sh => va_high_addr_switch.sh} | 6 ++- 4 files changed, 49 insertions(+), 14 deletions(-) rename tools/testing/selftests/mm/{va_128TBswitch.c => va_high_addr_switch.c} (86%) rename tools/testing/selftests/mm/{va_128TBswitch.sh => va_high_addr_switch.sh} (89%)