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=ham 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 86B99C433E6 for ; Tue, 9 Feb 2021 09:27:43 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id EEA8A64EBA for ; Tue, 9 Feb 2021 09:27:42 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org EEA8A64EBA Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=hisilicon.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 565856B0005; Tue, 9 Feb 2021 04:27:42 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 4EF886B006C; Tue, 9 Feb 2021 04:27:42 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 390616B006E; Tue, 9 Feb 2021 04:27:42 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0113.hostedemail.com [216.40.44.113]) by kanga.kvack.org (Postfix) with ESMTP id 1EEC56B0005 for ; Tue, 9 Feb 2021 04:27:42 -0500 (EST) Received: from smtpin10.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay04.hostedemail.com (Postfix) with ESMTP id D9301A76C for ; Tue, 9 Feb 2021 09:27:41 +0000 (UTC) X-FDA: 77798201922.10.thing99_5104ed427606 Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin10.hostedemail.com (Postfix) with ESMTP id B49591698ED for ; Tue, 9 Feb 2021 09:27:41 +0000 (UTC) X-HE-Tag: thing99_5104ed427606 X-Filterd-Recvd-Size: 3159 Received: from szxga07-in.huawei.com (szxga07-in.huawei.com [45.249.212.35]) by imf07.hostedemail.com (Postfix) with ESMTP for ; Tue, 9 Feb 2021 09:27:40 +0000 (UTC) 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 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: 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 > > . >