Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp1073882ybi; Fri, 24 May 2019 16:47:13 -0700 (PDT) X-Google-Smtp-Source: APXvYqxma1FEDcQcacTJUyF9S24g6GFfgkPuvCPaTuECn1MBnXhyMOfZDbtKtr165ZYGIBa/T87M X-Received: by 2002:a17:902:148:: with SMTP id 66mr50890368plb.143.1558741633852; Fri, 24 May 2019 16:47:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1558741633; cv=none; d=google.com; s=arc-20160816; b=l952PwsXtEOD99tR1UXARXVks3CCja7nREZW+46fznYKtWDD4NmBVYMDiGIuDUdiw3 yhHSDACcNpjVUlTHf49m+LMEXJ5pPiMoJqLVzrZM+2maJBjxkiBomQhVI9uEfHM7Q21m fxd/ez11dbIf57zY+tyiAP+abYBwu0R8xYZInKY1kyH8ucaGSEuhzroTcPR+gGo8jZOO EFpAi9Ut3+VptmNAoL90fqr7Xax7+FjwuDnex77xmla2UZtB0mhAaN+vDvyiK/7ucmM/ yqD49F59HrKX8VwlKusbDVq8+iZs9uuSAVCa4ojfVusuMVMPzr4p0hFZwC0sR3sccayV hw/Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=JQmBaRrQ0RmcVdFAdlRTB6MtalC5bA03DtpY0M0jO6c=; b=D9GNCmFw0h8SgwI8wZ1r5aKkCjb09e66xv7avGgqceo8dhK6OWkkczpgsE95G6Je8H VMHYY9hNrnf4ev65YVccMgJHe/F34RNeNFV0JjMYbkCxY+trfU9cD2SJwrl2O3lTgG21 07x2sMaGZ6BykcLVOa0i6fV3/efYUMoIHN8LSPjRSjrK+XGEoTYx2Ze5cdT1Gl8tyoUr bGI9G6VnQ5IeqLm3ErgCtMUG8cnlJtv2BL4qL2UNKygenltXCFYysIZa5kbtyhmNd9nP EKHiGkXCgFvwdqV77mxHgyccHUEytzShwb1hY+qbRmC4DDtie5U0xxebN7l8l8PV7ulv ZLqQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r18si6028614pgv.433.2019.05.24.16.46.58; Fri, 24 May 2019 16:47:13 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726137AbfEXXpy (ORCPT + 99 others); Fri, 24 May 2019 19:45:54 -0400 Received: from zeniv.linux.org.uk ([195.92.253.2]:42488 "EHLO ZenIV.linux.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725920AbfEXXpy (ORCPT ); Fri, 24 May 2019 19:45:54 -0400 Received: from viro by ZenIV.linux.org.uk with local (Exim 4.92 #3 (Red Hat Linux)) id 1hUJsj-0001OM-6M; Fri, 24 May 2019 23:45:49 +0000 Date: Sat, 25 May 2019 00:45:49 +0100 From: Al Viro To: Alexey Dobriyan Cc: Linus Torvalds , Christian Brauner , Linux List Kernel Mailing , linux-fsdevel Subject: Re: [PATCH v2 0/2] close_range() Message-ID: <20190524234549.GO17978@ZenIV.linux.org.uk> References: <20190523182152.GA6875@avx2> <20190524183903.GB2658@avx2> <20190524212740.GA7165@avx2> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190524212740.GA7165@avx2> User-Agent: Mutt/1.11.3 (2019-02-01) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, May 25, 2019 at 12:27:40AM +0300, Alexey Dobriyan wrote: > What about orthogonality of interfaces? > > fdmap() > bulk_close() > > Now fdmap() can be reused for lsof/criu and it is only 2 system calls > for close-everything usecase which is OK because readdir is 4(!) minimum: > > open > getdents > getdents() = 0 > close > > Writing all of this I understood how fdmap can be made more faster which > neither getdents() nor even read() have the luxury of: it can return > a flag if more data is available so that application would do next fdmap() > only if truly necessary. Tactless question: what has traumatised you so badly about string operations? Because that seems to be the common denominator to a lot of things...