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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0ABB0C4167B for ; Thu, 30 Nov 2023 15:36:42 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1346320AbjK3Pgd (ORCPT ); Thu, 30 Nov 2023 10:36:33 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38818 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232180AbjK3Pgb (ORCPT ); Thu, 30 Nov 2023 10:36:31 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7208E10C2 for ; Thu, 30 Nov 2023 07:36:37 -0800 (PST) Received: by smtp.kernel.org (Postfix) with ESMTPSA id ED53FC433C7; Thu, 30 Nov 2023 15:36:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1701358597; bh=IuyTo/SqtMXTfOfDJB4gGYsTQYZhhJVyRktybDYXRIg=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=u/ylpSyc9vHCYJYK+PI9TH6o4AxCANtjq/SDm3RtWDQZJMymqlXqGtI6x1aMB+nXo WN96cL2pW6gCjBvM5V2Yu39UXl85WEQo4uCLYALsmBBONAdr0uIFrzGRwF7FY/bZYd RqjrYpP7XHCKvQWSOBmZTNIvnWaJrYPCRQwoNNgumOsi4UYuuXlWjfYGeuvdiJO+Lu /Ft+F55LVl7YM+uIRFL/tDCuvDTf9i9etnhDGU7AmnVlqZkPidlAIkCWGqdYacdaAK RO7YwB9+n7gRsChyBLHoRDaxmG3BhCPwiseVd1svwlCmEzsKiCg3LxWrE7Yq0SsHAI huqcdUxGNgbRQ== Date: Thu, 30 Nov 2023 09:36:35 -0600 From: "Seth Forshee (DigitalOcean)" To: Amir Goldstein Cc: Christian Brauner , Serge Hallyn , Paul Moore , Eric Paris , James Morris , Alexander Viro , Miklos Szeredi , linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-security-module@vger.kernel.org, audit@vger.kernel.org, linux-unionfs@vger.kernel.org Subject: Re: [PATCH 07/16] fs: add inode operations to get/set/remove fscaps Message-ID: References: <20231129-idmap-fscap-refactor-v1-0-da5a26058a5b@kernel.org> <20231129-idmap-fscap-refactor-v1-7-da5a26058a5b@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Nov 30, 2023 at 07:32:19AM +0200, Amir Goldstein wrote: > On Wed, Nov 29, 2023 at 11:51 PM Seth Forshee (DigitalOcean) > wrote: > > > > Add inode operations for getting, setting and removing filesystem > > capabilities rather than passing around raw xattr data. This provides > > better type safety for ids contained within xattrs. > > > > Signed-off-by: Seth Forshee (DigitalOcean) > > --- > > include/linux/fs.h | 5 +++++ > > 1 file changed, 5 insertions(+) > > > > diff --git a/include/linux/fs.h b/include/linux/fs.h > > index 98b7a7a8c42e..a0a77f67b999 100644 > > --- a/include/linux/fs.h > > +++ b/include/linux/fs.h > > @@ -2002,6 +2002,11 @@ struct inode_operations { > > int); > > int (*set_acl)(struct mnt_idmap *, struct dentry *, > > struct posix_acl *, int); > > + int (*get_fscaps)(struct mnt_idmap *, struct dentry *, > > + struct vfs_caps *); > > + int (*set_fscaps)(struct mnt_idmap *, struct dentry *, > > + const struct vfs_caps *, int flags); > > + int (*remove_fscaps)(struct mnt_idmap *, struct dentry *); > > int (*fileattr_set)(struct mnt_idmap *idmap, > > struct dentry *dentry, struct fileattr *fa); > > int (*fileattr_get)(struct dentry *dentry, struct fileattr *fa); > > > > Please document in Documentation/filesystems/{vfs,locking}.rst Done for v2.