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 Received: from lists.ozlabs.org (lists.ozlabs.org [112.213.38.117]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id ABD38C27C4F for ; Sun, 23 Jun 2024 17:11:25 +0000 (UTC) Authentication-Results: lists.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20201202 header.b=SHcWkbRT; dkim-atps=neutral Received: from boromir.ozlabs.org (localhost [IPv6:::1]) by lists.ozlabs.org (Postfix) with ESMTP id 4W6d0q0WKLz3cXS for ; Mon, 24 Jun 2024 03:11:23 +1000 (AEST) Authentication-Results: lists.ozlabs.org; dmarc=pass (p=none dis=none) header.from=kernel.org Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20201202 header.b=SHcWkbRT; dkim-atps=neutral Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=kernel.org (client-ip=139.178.84.217; helo=dfw.source.kernel.org; envelope-from=guoren@kernel.org; receiver=lists.ozlabs.org) Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 4W6d023DpBz30WS for ; Mon, 24 Jun 2024 03:10:42 +1000 (AEST) Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by dfw.source.kernel.org (Postfix) with ESMTP id B6CF662558 for ; Sun, 23 Jun 2024 17:10:40 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 01D4EC4AF13 for ; Sun, 23 Jun 2024 17:10:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1719162640; bh=aosSO/S+etUamgM4SS3mlQ3heoMUr6FZbeXpiXEovy0=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=SHcWkbRTRysffowmKeNtbvp9bhDl+zoDvjEJ2fFDHg7LSDrwqFsJdD9YYXV4Vr+sp 2E8pAnecGBkfcW3fYWlLjSsfPlPKcXnQ8nJbcMvEmYSYZS0YcgH+rt/qDOrTB8Gvu+ agZuIo6AmTpr2D4xK4pBnUswovpS9ueZT7VqTzkz0VoNehsJKjKIbT7Hxbmzrk7px2 nKkeeohgJbLaTj1UD/4bc2iBlfTD7iIkm5ON/CNdK03bV+FGcWIvguDXvdHM+5cgLf OB8EHfsL2MFz6vrCmyH5CregCIOmWkoz7MbvmFg/cF39yMwxMHUAlyiXqW1imSaGS0 Nv1EJ4Jnnv/6A== Received: by mail-lj1-f177.google.com with SMTP id 38308e7fff4ca-2ec0f3b9cfeso40653691fa.0 for ; Sun, 23 Jun 2024 10:10:39 -0700 (PDT) X-Forwarded-Encrypted: i=1; AJvYcCUgZYPwosLPjwpcmEeFYD0pHFldvgfs8V0PQNA//Mf+t1VPkolOZRFVCHZomO/G26HSIIY/kAJlan/bb2/OEH7L+vDfhpsiYpYsyz3fIw== X-Gm-Message-State: AOJu0YxLSlIIg462P36IK+UYOn8YQUsZJNgdxT4k++y5uILRn/XVJkH5 RCupI4Cm3NSgL5b22Cl5YP3fV+45fSIdvOgMSy4BqP8yuqZDO5SxpTgktrfkpOjUTgecsAh1B1+ OXYPcBKHeg8OylmEYsC0TnuEtHJ0= X-Google-Smtp-Source: AGHT+IHxMABTsjE/bTBoMOuJE1ctF+u0ZebsEtw1bh3nJ1bb3woGpWj5W/Pz1qQmYslYoKzzGRd0eu1pNlr+yN6Ofzo= X-Received: by 2002:a2e:3101:0:b0:2ec:1cf1:b74c with SMTP id 38308e7fff4ca-2ec594cfe8fmr16740431fa.32.1719162638077; Sun, 23 Jun 2024 10:10:38 -0700 (PDT) MIME-Version: 1.0 References: <20240620162316.3674955-1-arnd@kernel.org> <20240620162316.3674955-11-arnd@kernel.org> In-Reply-To: <20240620162316.3674955-11-arnd@kernel.org> From: Guo Ren Date: Mon, 24 Jun 2024 01:10:25 +0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 10/15] csky, hexagon: fix broken sys_sync_file_range To: Arnd Bergmann Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Rich Felker , Andreas Larsson , linux-mips@vger.kernel.org, Christophe Leroy , "H. Peter Anvin" , sparclinux@vger.kernel.org, linux-arch@vger.kernel.org, linux-s390@vger.kernel.org, Helge Deller , linux-sh@vger.kernel.org, linux-csky@vger.kernel.org, "Naveen N . Rao" , Arnd Bergmann , Heiko Carstens , musl@lists.openwall.com, Nicholas Piggin , Alexander Viro , John Paul Adrian Glaubitz , ltp@lists.linux.it, Brian Cain , Christian Brauner , Thomas Bogendoerfer , libc-alpha@sourceware.org, linux-parisc@vger.kernel.org, linux-kernel@vger.kernel.org, stable@vger.kernel.org, linux-hexagon@vger.kernel.org, linux-fsdevel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, "David S. Miller" Errors-To: linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Sender: "Linuxppc-dev" On Fri, Jun 21, 2024 at 12:24=E2=80=AFAM Arnd Bergmann wr= ote: > > From: Arnd Bergmann > > Both of these architectures require u64 function arguments to be > passed in even/odd pairs of registers or stack slots, which in case of > sync_file_range would result in a seven-argument system call that is > not currently possible. The system call is therefore incompatible with > all existing binaries. > > While it would be possible to implement support for seven arguments > like on mips, it seems better to use a six-argument version, either > with the normal argument order but misaligned as on most architectures > or with the reordered sync_file_range2() calling conventions as on > arm and powerpc. > > Cc: stable@vger.kernel.org > Signed-off-by: Arnd Bergmann > --- > arch/csky/include/uapi/asm/unistd.h | 1 + > arch/hexagon/include/uapi/asm/unistd.h | 1 + > 2 files changed, 2 insertions(+) > > diff --git a/arch/csky/include/uapi/asm/unistd.h b/arch/csky/include/uapi= /asm/unistd.h > index 7ff6a2466af1..e0594b6370a6 100644 > --- a/arch/csky/include/uapi/asm/unistd.h > +++ b/arch/csky/include/uapi/asm/unistd.h > @@ -6,6 +6,7 @@ > #define __ARCH_WANT_SYS_CLONE3 > #define __ARCH_WANT_SET_GET_RLIMIT > #define __ARCH_WANT_TIME32_SYSCALLS > +#define __ARCH_WANT_SYNC_FILE_RANGE2 For csky part. Acked-by: Guo Ren > #include > > #define __NR_set_thread_area (__NR_arch_specific_syscall + 0) > diff --git a/arch/hexagon/include/uapi/asm/unistd.h b/arch/hexagon/includ= e/uapi/asm/unistd.h > index 432c4db1b623..21ae22306b5d 100644 > --- a/arch/hexagon/include/uapi/asm/unistd.h > +++ b/arch/hexagon/include/uapi/asm/unistd.h > @@ -36,5 +36,6 @@ > #define __ARCH_WANT_SYS_VFORK > #define __ARCH_WANT_SYS_FORK > #define __ARCH_WANT_TIME32_SYSCALLS > +#define __ARCH_WANT_SYNC_FILE_RANGE2 > > #include > -- > 2.39.2 > --=20 Best Regards Guo Ren