Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp1608012pxb; Thu, 4 Mar 2021 16:12:50 -0800 (PST) X-Google-Smtp-Source: ABdhPJwWhv+6LA5/5vTUJWfZ39I312s8oGlqWTnVsHnevBKI4Scs4rGmovA//MUcJ6br3aWdtA8W X-Received: by 2002:a02:8801:: with SMTP id r1mr7005317jai.51.1614903170437; Thu, 04 Mar 2021 16:12:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614903170; cv=none; d=google.com; s=arc-20160816; b=yRiPEjr4b0v+NzNNLzeFl22S/PTFjTviFWCJpJw/MSTbWVVl0esCSasdFb1fO1gfMU PPDayyZ1bEtTf2VINbDh1pEgOxi4k338Zis6fEqoKqTKSM+8w1IrUf6OPCqzARLXDVP6 hnx9mbraWroHzTvgvkgl81jxJraVovNZ3rtl1JDJbE3gXNGTBuDYkzdCYRxmspKzRim1 Jds0LIGX2yLKwNMb/m7ljsZIybz1tZjd74QJpcHvHYOjhL65SWcaIGat7GlPztrMx+ro AE76zBxHPHKCCEmpJNd7y2phEpB/RxJdMrrc/UGZAYERB8VR0e9qh2XH6yRSo776P7NC 1Zfg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=uqCOjkEliZN5NO9OnJaX4EgxxGB5yfMXL2thR6HyolM=; b=d6vHHnnH2/NSTLNySwwtt62RrelohOu5rvrRhk0l0Fy7IikjoBlNs1y+54hPSqV3Hj DNegBMZM2A5Gvyg6/s6kYFFNQRTtNpIUTHXLojDKtmYj7yyoLKooWY+tQkrfkBn4KVaA Yv9b8FOPQZ776PxMScd6K5O1d5DWHri2EMRv7ywDa7SVBpyxVR5sQHfpWHuNvx7ruUVK HCxiEvsE2oCf689CabQJxwfmv5OSYHsVYN2OmAJWJGkZ9XHwgEp+m9vYGpnAdFqbDmNa DXvpiE3DpH157+2sGFRv9Cu8FXBL3TxyavZXfwODo8Qveh75mvTnd8o2KJSlTTs2m+As PZ9Q== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m6si632364ilh.122.2021.03.04.16.12.36; Thu, 04 Mar 2021 16:12:50 -0800 (PST) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240897AbhCDMhG (ORCPT + 99 others); Thu, 4 Mar 2021 07:37:06 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38380 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240892AbhCDMgp (ORCPT ); Thu, 4 Mar 2021 07:36:45 -0500 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8C7DEC061760 for ; Thu, 4 Mar 2021 04:36:04 -0800 (PST) Received: from dude02.hi.pengutronix.de ([2001:67c:670:100:1d::28]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lHnD1-0006w2-1Q; Thu, 04 Mar 2021 13:36:03 +0100 Received: from sha by dude02.hi.pengutronix.de with local (Exim 4.92) (envelope-from ) id 1lHnD0-00044V-2W; Thu, 04 Mar 2021 13:36:02 +0100 From: Sascha Hauer To: linux-fsdevel@vger.kernel.org Cc: linux-kernel@vger.kernel.org, linux-api@vger.kernel.org, Christoph Hellwig , kernel@pengutronix.de, Jan Kara , Richard Weinberger , Sascha Hauer Subject: [PATCH] quotactl.2: Add documentation for quotactl_path() Date: Thu, 4 Mar 2021 13:35:41 +0100 Message-Id: <20210304123541.30749-4-s.hauer@pengutronix.de> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20210304123541.30749-1-s.hauer@pengutronix.de> References: <20210304123541.30749-1-s.hauer@pengutronix.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SA-Exim-Connect-IP: 2001:67c:670:100:1d::28 X-SA-Exim-Mail-From: sha@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Expand the quotactl.2 manpage with a description for quotactl_path() that takes a mountpoint path instead of a path to a block device. Signed-off-by: Sascha Hauer --- man2/quotactl.2 | 31 ++++++++++++++++++++++++++++--- man2/quotactl_path.2 | 1 + 2 files changed, 29 insertions(+), 3 deletions(-) create mode 100644 man2/quotactl_path.2 diff --git a/man2/quotactl.2 b/man2/quotactl.2 index 7869c64ea..76505c668 100644 --- a/man2/quotactl.2 +++ b/man2/quotactl.2 @@ -34,6 +34,8 @@ quotactl \- manipulate disk quotas .PP .BI "int quotactl(int " cmd ", const char *" special ", int " id \ ", caddr_t " addr ); +.BI "int quotactl_path(int " cmd ", const char *" mountpoint ", int " id \ +", caddr_t " addr ); .fi .SH DESCRIPTION The quota system can be used to set per-user, per-group, and per-project limits @@ -48,7 +50,11 @@ after this, the soft limit counts as a hard limit. .PP The .BR quotactl () -call manipulates disk quotas. +and +.BR quotactl_path () +calls manipulate disk quotas. The difference between both functions is the way +how the filesystem being manipulated is specified, see description of the arguments +below. The .I cmd argument indicates a command to be applied to the user or @@ -75,10 +81,19 @@ value is described below. .PP The .I special -argument is a pointer to a null-terminated string containing the pathname +argument to +.BR quotactl () +is a pointer to a null-terminated string containing the pathname of the (mounted) block special device for the filesystem being manipulated. .PP The +.I mountpoint +argument to +.BR quotactl_path () +is a pointer to a null-terminated string containing the pathname +of the mountpoint for the filesystem being manipulated. +.PP +The .I addr argument is the address of an optional, command-specific, data structure that is copied in or out of the system. @@ -133,7 +148,17 @@ flag in the .I dqi_flags field returned by the .B Q_GETINFO -operation. +operation. The +.BR quotactl_path () +variant of this syscall generally ignores the +.IR addr +and +.IR id +arguments, so the +.B Q_QUOTAON +operation of +.BR quotactl_path () +is only suitable for work with hidden system inodes. .IP This operation requires privilege .RB ( CAP_SYS_ADMIN ). diff --git a/man2/quotactl_path.2 b/man2/quotactl_path.2 new file mode 100644 index 000000000..5f63187c6 --- /dev/null +++ b/man2/quotactl_path.2 @@ -0,0 +1 @@ +.so man2/quotactl.2 -- 2.20.1