From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.5 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,NICE_REPLY_A, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 497A5C433DB for ; Tue, 9 Feb 2021 09:31:07 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id DE05D64EBE for ; Tue, 9 Feb 2021 09:31:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230303AbhBIJar (ORCPT ); Tue, 9 Feb 2021 04:30:47 -0500 Received: from szxga07-in.huawei.com ([45.249.212.35]:12881 "EHLO szxga07-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230090AbhBIJ2W (ORCPT ); Tue, 9 Feb 2021 04:28:22 -0500 Received: from DGGEMS405-HUB.china.huawei.com (unknown [172.30.72.58]) by szxga07-in.huawei.com (SkyGuard) with ESMTP id 4DZcvp1gvBz7jFf; Tue, 9 Feb 2021 17:26:14 +0800 (CST) Received: from [127.0.0.1] (10.40.188.87) by DGGEMS405-HUB.china.huawei.com (10.3.19.205) with Microsoft SMTP Server id 14.3.498.0; Tue, 9 Feb 2021 17:27:31 +0800 Subject: Re: [RFC PATCH v3 1/2] mempinfd: Add new syscall to provide memory pin To: Arnd Bergmann References: <1612685884-19514-1-git-send-email-wangzhou1@hisilicon.com> <1612685884-19514-2-git-send-email-wangzhou1@hisilicon.com> CC: "linux-kernel@vger.kernel.org" , "open list:IOMMU DRIVERS" , Linux-MM , Linux ARM , "Linux API" , Andrew Morton , Alexander Viro , gregkh , Barry Song , "Jason Gunthorpe" , , Jean-Philippe Brucker , Eric Auger , "Liguozhu (Kenneth)" , Zhangfei Gao , Sihang Chen From: Zhou Wang Message-ID: <753db746-292c-4f1d-c79f-9a7282a19ba2@hisilicon.com> Date: Tue, 9 Feb 2021 17:27:30 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.7.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Originating-IP: [10.40.188.87] X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2021/2/8 5:51, Arnd Bergmann wrote: > On Sun, Feb 7, 2021 at 9:18 AM Zhou Wang wrote: > >> diff --git a/arch/arm64/include/asm/unistd32.h b/arch/arm64/include/asm/unistd32.h >> index cccfbbe..3f49529 100644 >> --- a/arch/arm64/include/asm/unistd32.h >> +++ b/arch/arm64/include/asm/unistd32.h >> @@ -891,6 +891,8 @@ __SYSCALL(__NR_faccessat2, sys_faccessat2) >> __SYSCALL(__NR_process_madvise, sys_process_madvise) >> #define __NR_epoll_pwait2 441 >> __SYSCALL(__NR_epoll_pwait2, compat_sys_epoll_pwait2) >> +#define __NR_mempinfd 442 >> +__SYSCALL(__NR_mempinfd, sys_mempinfd) > > This adds a compat syscall for 32-bit tasks running on arm64 without adding > the same for the native arch/arm syscall table. Those two need to always > stay synchronized. In fact, new system call should ideally get assigned > on all architectures at the same time, with the same number (or +110 > on arch/alpha). Thank for pointing out this. I use an ARM64 machine to test, so currently only add it for ARM64 :) Best, Zhou > > Arnd > > . >