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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 A662CC43602 for ; Wed, 8 Jul 2026 16:05:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc: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=krPNCcLFhHo3if00xalCr+gaPn6sjX1aVc0xIQvwdWg=; b=4NCWQ4cXwjI7rG 64Jxwz8psAg2fgN3KJRrU81UV1ekpwsn76qHuHNLksTtu7QhUg1SzC3hgMbNSaF4iz+/ENDHsORmq xTqIPVwiK/uoNoE/L+8SslJKqvXHlqa2DEGvV7CuN0fv3mgp5Pv2grSvjHkgTG81E8RE/l/80hgd+ suFvyELlVW+VE7KEGa+OilYSceoIT2lb8T0gsq1g1fxiG0EmQJmT+Yij2c7Iet8BBY5VtyfdtSMuR xxTWWQRnDoaEYGOPT4gT3Gx7QBtktDIYMuI8KPzzCZUUJJJZwfkx4m4GvULcyWk1nhqQwdfm2H9Tt 5We0JEGyaec9JahNV7ZQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.99.1 #2 (Red Hat Linux)) id 1whUlb-0000000HYS4-2izU; Wed, 08 Jul 2026 16:04:55 +0000 Received: from us-smtp-delivery-124.mimecast.com ([170.10.129.124]) by bombadil.infradead.org with esmtps (Exim 4.99.1 #2 (Red Hat Linux)) id 1whUlY-0000000HYQj-3abz for linux-riscv@lists.infradead.org; Wed, 08 Jul 2026 16:04:54 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1783526691; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=8P/ciXzD2S1KvjG8yWg06YK1HrAoM9H+3p3KtWGqU68=; b=QNMa0SoAELWiVVl3X90v5WRokCF/4GsdTQObb6Xg/n1czmrdrMhu7/X6LZP1UwzVYO1vGv IL+dTSPmBCZiLBepdiypguJcyWQ/nEsF+STwfSLFZBklRB+WkOjcaE6xTU4Nx4DNoqGEo1 HAuoRNRyp36Ys1/7JkHokwurJaaLdA4= Received: from mx-prod-mc-06.mail-002.prod.us-west-2.aws.redhat.com (ec2-35-165-154-97.us-west-2.compute.amazonaws.com [35.165.154.97]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-595-fn1pYKmRPGGlbjH-rSP4QA-1; Wed, 08 Jul 2026 12:04:48 -0400 X-MC-Unique: fn1pYKmRPGGlbjH-rSP4QA-1 X-Mimecast-MFC-AGG-ID: fn1pYKmRPGGlbjH-rSP4QA_1783526682 Received: from mx-prod-int-03.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-03.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.12]) (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 mx-prod-mc-06.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 0E37718009D8; Wed, 8 Jul 2026 16:04:40 +0000 (UTC) Received: from fedora (unknown [10.44.33.83]) by mx-prod-int-03.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with SMTP id 1D1D21956040; Wed, 8 Jul 2026 16:04:21 +0000 (UTC) Received: by fedora (nbSMTP-1.00) for uid 1000 oleg@redhat.com; Wed, 8 Jul 2026 18:04:39 +0200 (CEST) Date: Wed, 8 Jul 2026 18:04:19 +0200 From: Oleg Nesterov To: Thomas Gleixner Cc: Jinjie Ruan , LKML , Peter Zijlstra , Mark Rutland , Kees Cook , Andy Lutomirski , Richard Henderson , Russell King , Catalin Marinas , Guo Ren , Geert Uytterhoeven , Thomas Bogendoerfer , Helge Deller , Yoshinori Sato , Richard Weinberger , Chris Zankel , linux-arm-kernel@lists.infradead.org, linux-alpha@vger.kernel.org, linux-csky@vger.kernel.org, linux-m68k@lists.linux-m68k.org, linux-mips@vger.kernel.org, linux-parisc@vger.kernel.org, linux-sh@vger.kernel.org, linux-um@lists.infradead.org, Michael Ellerman , Shrikanth Hegde , linuxppc-dev@lists.ozlabs.org, Huacai Chen , loongarch@lists.linux.dev, Paul Walmsley , Palmer Dabbelt , linux-riscv@lists.infradead.org, Sven Schnelle , linux-s390@vger.kernel.org, x86@kernel.org, Arnd Bergmann , Vineet Gupta , Will Deacon , Brian Cain , Michal Simek , Dinh Nguyen , "David S. Miller" , Andreas Larsson , linux-snps-arc@lists.infradead.org, linux-hexagon@vger.kernel.org, linux-openrisc@vger.kernel.org, sparclinux@vger.kernel.org, linux-arch@vger.kernel.org, Michal =?iso-8859-1?Q?Such=E1nek?= , Jonathan Corbet , linux-doc@vger.kernel.org Subject: Re: [patch 11/18] seccomp, treewide: Rename and convert __secure_computing() to return boolean Message-ID: References: <20260707181957.433213175@kernel.org> <20260707190254.230735780@kernel.org> <2e6ed364-ce8f-4b4b-8675-acd07f140f4f@huawei.com> <871pddsuzl.ffs@fw13> MIME-Version: 1.0 In-Reply-To: <871pddsuzl.ffs@fw13> X-Scanned-By: MIMEDefang 3.0 on 10.30.177.12 X-Mimecast-MFC-PROC-ID: NCczhUNQavFOrxoq5ZgfLFOxSwMnAawM4Rltij-8ZOs_1783526682 X-Mimecast-Originator: redhat.com Content-Disposition: inline X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.9.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20260708_090452_986111_A93F86CA X-CRM114-Status: GOOD ( 13.71 ) X-BeenThere: linux-riscv@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-riscv" Errors-To: linux-riscv-bounces+linux-riscv=archiver.kernel.org@lists.infradead.org On 07/08, Thomas Gleixner wrote: > > On Wed, Jul 08 2026 at 09:43, Jinjie Ruan wrote: > > > > The return value of __seccomp_filter is checked in the wrong way, check > > -1 should be replaced with check false, maybe: > > > > - if (__seccomp_filter(this_syscall, true)) > > - return -1; > > + if (!__seccomp_filter(this_syscall, true)) > > + return false; Or simply return __seccomp_filter(this_syscall, true); and remove "return true" below ? Either way, I personally like this change, I was always confused by these -1's. Acked-by: Oleg Nesterov _______________________________________________ linux-riscv mailing list linux-riscv@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-riscv