Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp4003309pxj; Tue, 8 Jun 2021 04:16:21 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzOxOEraelKatHolohY015Kvu2BLekMea0VLAtuS7JdWhC7qn95noi0Y19d1vWhuURcZEaO X-Received: by 2002:a17:907:7747:: with SMTP id kx7mr22892560ejc.400.1623150980848; Tue, 08 Jun 2021 04:16:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623150980; cv=none; d=google.com; s=arc-20160816; b=DYrK7DBbfGXY3N/tA8cnAbUSGts0ylmD61r8Nx+DUEN2pGdmt0MfDnC8bzVCAaZZss WIlRebYRR6ym93lS6aqtxD4H+8AisJkDgDVJO4IOqXkQqkwZ5HRc6ANQYZ/fCQzl2SMI bY+3pLyqpM3s9RfeEhglcK4PEO5yKEphRXLBX00bfWKhDjrY4a/2xa6756Rb3Z8beZ5b qtSpyNWYKPf5oor7/jNdCJbO03E5i0411r512v5yyWXT7bZTxa19O5EQ96fB6Pwijo56 L2Wie8Mew3qvBt5zobL2zW9VGMumYtAyEH1ibIX2Q+mih10fGF7LAkTEz8td/oGMF+mL 2Djg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=ovIkYns7j9P9zkan8ZpW94p/Ph5Bd/YkXqGXNcknxS0=; b=jIlV4BHKOF3xTMT4z6GuGdzq0y3KchSQpEZ99tzXnQRWqYh01+VUcKDwzK1U6n5gkk G9VWWfNBIt+MPt4wRhBFKmVQFRAtjmt9qw8Vo1NxAoCC65uSfXqya30jwg3vq3D2O9xv RIqYMMQBHnxRslA7Qzib7VsjILv4wt5ZQOrrPx+1VFVx8bNJj93iI2GCTigmuTB1LJE6 WJQwM4TCkan2jioRqLF2BBsR59oShTbvWbWHfnHsyq7+IiPAIaz7NhnxOL1f9KZ+pOe0 TKI1PCGmf34Px2H0NehBB8RwEz/wxGsoQRV94RYwtR0gcwf9juEZ/zMM6vc8FySoFd+F zmUg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=ljZwGPKF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d8si15894214edv.484.2021.06.08.04.15.57; Tue, 08 Jun 2021 04:16:20 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=ljZwGPKF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231409AbhFHLPi (ORCPT + 99 others); Tue, 8 Jun 2021 07:15:38 -0400 Received: from mail.kernel.org ([198.145.29.99]:48872 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230190AbhFHLPi (ORCPT ); Tue, 8 Jun 2021 07:15:38 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id CE7EB6128A; Tue, 8 Jun 2021 11:13:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1623150813; bh=A6VpHR3oddi2suLec2a8UbPlr39nefG0fVnTuz2uXk8=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=ljZwGPKFpGidXrQDPvcVbFHoOwEk2DUTv7muK0IHXxDKQYGLKwd7RPQJs9wr+mjc2 NWc5SRe+en635+znruA9DOqveNp01teR7cqN/b5kfsVOVylrO+53HQiFqvTYlycCxg xi8YK42QXjUzf2KWpwEx97q0gVod1ATu1XT0nC8c= Date: Tue, 8 Jun 2021 13:13:30 +0200 From: Greg KH To: Andrey Semashev Cc: Nicholas Piggin , =?iso-8859-1?Q?Andr=E9?= Almeida , acme@kernel.org, Sebastian Andrzej Siewior , corbet@lwn.net, Davidlohr Bueso , Darren Hart , fweimer@redhat.com, joel@joelfernandes.org, kernel@collabora.com, krisman@collabora.com, libc-alpha@sourceware.org, linux-api@vger.kernel.org, linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, malteskarupke@fastmail.fm, Ingo Molnar , Peter Zijlstra , pgriffais@valvesoftware.com, Peter Oskolkov , Steven Rostedt , shuah@kernel.org, Thomas Gleixner , z.figura12@gmail.com Subject: Re: [PATCH v4 00/15] Add futex2 syscalls Message-ID: References: <20210603195924.361327-1-andrealmeid@collabora.com> <1622799088.hsuspipe84.astroid@bobo.none> <1622853816.mokf23xgnt.astroid@bobo.none> <6d8e3bb4-0cef-b991-9a16-1f03d10f131d@gmail.com> <1622980258.cfsuodze38.astroid@bobo.none> <1623114630.pc8fq7r5y9.astroid@bobo.none> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jun 08, 2021 at 02:03:50PM +0300, Andrey Semashev wrote: > On 6/8/21 4:25 AM, Nicholas Piggin wrote: > > > > Are shared pthread mutexes using existing pthread APIs that are today > > implemented okay with futex1 system call a good reason to constrain > > futex2 I wonder? Or do we have an opportunity to make a bigger change > > to the API so it suffers less from non deterministic latency (for > > example)? > > If futex2 is not able to cover futex1 use cases then it cannot be viewed as > a replacement. In the long term this means futex1 cannot be deprecated and > has to be maintained. My impression was that futex1 was basically > unmaintainable(*) and futex2 was an evolution of futex1 so that users of > futex1 could migrate relatively easily and futex1 eventually removed. Maybe > my impression was wrong, but I would like to see futex2 as a replacement and > extension of futex1, so the latter can be deprecated at some point. You can never delete a kernel system call, so even if you "deprecate" it, it still needs to be supported for forever. Best of all would be if internally your "futex2" code would replace the "futex1" code so that there is no two different code bases. That would be the only sane way forward, having 2 code bases to work with is just insane. > (*) I use "unmaintainable" in a broad sense here. It exists and works in > newer kernel versions and may receive code changes that are necessary to > keep it working, but maintainers refuse any extensions or modifications of > the code, mostly because of its complexity. Adding additional complexity for no good reason is not a good idea, especially if you are asking others to maintain and support that complexity. Would you want to have to do that work? So what's keeping the futex2 code from doing all that futex1 does so that the futex1 code can be deleted internally? thanks, greg k-h