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=-14.0 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED 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 74AA2C5519F for ; Wed, 18 Nov 2020 06:58:31 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id F07F524654 for ; Wed, 18 Nov 2020 06:58:30 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="nCca7bfY"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="U45SNSKJ" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org F07F524654 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References:Message-ID: Subject:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=k9nSTBQYnJmfEhvbet9Fi1i4Wp42MeZ56IUi0xrDSNY=; b=nCca7bfYHzrRjcAcfNDPUYDzh dUv78Vhz76uaVG7z5JUAWu+6eVhgH61KMduvqzWCcEXFykXnJ4Jt8RrsF+fsN1c1RKJ05JHS2n+eL kdprLBIc0drNLwIYUV/w52OateZS9bWLKC/N6IzjY17AVUkCGHBGLH65YncnDkouJKPGv/wejwrHS 7smy6vN+cgypardaliHBGWXRjOxttx3TOvJI1vOTuRsL4DlmxvxVzCS7ccUIJWpWQKnM9UpNm3pU0 OLNOlrTjGzUP7Zhq3ywYE0s5iFLhkNeSaXwW2xMvtsUFM0n7N//NoUnpknA//sV0M5iigAFBRqM/S wRZ4npXqQ==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kfHPC-0004Ku-0E; Wed, 18 Nov 2020 06:57:26 +0000 Received: from mail.kernel.org ([198.145.29.99]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kfHP8-0004J9-EO; Wed, 18 Nov 2020 06:57:23 +0000 Received: from kernel.org (unknown [77.125.7.142]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id C5BB624654; Wed, 18 Nov 2020 06:57:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1605682641; bh=p9re6A1RRg6oU6SsuX3QRE0t8ggbYYLXloFK2ojmgAo=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=U45SNSKJGotiPIakEwaAseiV27AsVkyTNt66bCAHLcpiM1G9GhxPaQQlROUaXdH9c rZ2SGl1DirjI0HjrC5eRlRQ7rEdibP7yq1sGHKXfUjmBvTCB1ZAiMR3V9ZcpXtRamU 6btiE8gvCG8QTrNMjF7yXVOnKyB3lsNIE30mk1FQ= Date: Wed, 18 Nov 2020 08:57:06 +0200 From: Mike Rapoport To: Catalin Marinas Subject: Re: [PATCH v9 8/9] arch, mm: wire up memfd_secret system call were relevant Message-ID: <20201118065706.GL370813@kernel.org> References: <20201117162932.13649-1-rppt@kernel.org> <20201117162932.13649-9-rppt@kernel.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201118_015722_691049_4594D488 X-CRM114-Status: GOOD ( 24.28 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Mark Rutland , David Hildenbrand , Peter Zijlstra , Dave Hansen , linux-mm@kvack.org, linux-kselftest@vger.kernel.org, "H. Peter Anvin" , Christopher Lameter , Shuah Khan , Thomas Gleixner , Elena Reshetova , linux-arch@vger.kernel.org, Tycho Andersen , linux-nvdimm@lists.01.org, Will Deacon , x86@kernel.org, Matthew Wilcox , Mike Rapoport , Ingo Molnar , Michael Kerrisk , Palmer Dabbelt , Arnd Bergmann , James Bottomley , Borislav Petkov , Alexander Viro , Andy Lutomirski , Paul Walmsley , "Kirill A. Shutemov" , Dan Williams , linux-arm-kernel@lists.infradead.org, linux-api@vger.kernel.org, linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org, Palmer Dabbelt , linux-fsdevel@vger.kernel.org, Andrew Morton , Rick Edgecombe , Roman Gushchin Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Tue, Nov 17, 2020 at 05:15:30PM +0000, Catalin Marinas wrote: > On Tue, Nov 17, 2020 at 06:29:31PM +0200, Mike Rapoport wrote: > > From: Mike Rapoport > > > > Wire up memfd_secret system call on architectures that define > > ARCH_HAS_SET_DIRECT_MAP, namely arm64, risc-v and x86. > > > > Signed-off-by: Mike Rapoport > > Acked-by: Palmer Dabbelt > > Acked-by: Arnd Bergmann > > --- > > arch/arm64/include/asm/unistd.h | 2 +- > > arch/arm64/include/asm/unistd32.h | 2 ++ > > arch/arm64/include/uapi/asm/unistd.h | 1 + > > arch/riscv/include/asm/unistd.h | 1 + > > arch/x86/entry/syscalls/syscall_32.tbl | 1 + > > arch/x86/entry/syscalls/syscall_64.tbl | 1 + > > include/linux/syscalls.h | 1 + > > include/uapi/asm-generic/unistd.h | 6 +++++- > > scripts/checksyscalls.sh | 4 ++++ > > 9 files changed, 17 insertions(+), 2 deletions(-) > > > > diff --git a/arch/arm64/include/asm/unistd.h b/arch/arm64/include/asm/unistd.h > > index 86a9d7b3eabe..949788f5ba40 100644 > > --- a/arch/arm64/include/asm/unistd.h > > +++ b/arch/arm64/include/asm/unistd.h > > @@ -38,7 +38,7 @@ > > #define __ARM_NR_compat_set_tls (__ARM_NR_COMPAT_BASE + 5) > > #define __ARM_NR_COMPAT_END (__ARM_NR_COMPAT_BASE + 0x800) > > > > -#define __NR_compat_syscalls 442 > > +#define __NR_compat_syscalls 443 > > #endif > > > > #define __ARCH_WANT_SYS_CLONE > > diff --git a/arch/arm64/include/asm/unistd32.h b/arch/arm64/include/asm/unistd32.h > > index 6c1dcca067e0..5279481ec95b 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_watch_mount 441 > > __SYSCALL(__NR_watch_mount, sys_watch_mount) > > +/* 442 is memfd_secret, it is not implemented for 32-bit */ > > +__SYSCALL(442, sys_ni_syscall) > > It now behaves correctly for compat but I don't think we need to > increment __NR_compat_syscalls. The compat syscall handler already calls > sys_ni_syscall() if out of range. Ok, let's drop this change as well :) > So the only arm64 change needed is defining __ARCH_WANT_MEMFD_SECRET > (well, we don't have a use for it yet ;)). > > -- > Catalin -- Sincerely yours, Mike. _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel