Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp6666798rwl; Tue, 4 Apr 2023 17:06:55 -0700 (PDT) X-Google-Smtp-Source: AKy350Z6SIFu7b/5gF96zCFt57UrFLIO76BCzA50ZKKMNgXH0mrQsC+dz1k7hblL9NKvh3nheA3T X-Received: by 2002:aa7:d8da:0:b0:4ac:b69a:2f06 with SMTP id k26-20020aa7d8da000000b004acb69a2f06mr430285eds.0.1680653215220; Tue, 04 Apr 2023 17:06:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680653215; cv=none; d=google.com; s=arc-20160816; b=aPKxcj9RR9F8nItOT6s+RJN9YIu6DtG93XSj8dAAQD7sy8xptbsAjqcIxr0bc/u9qe SMPsT/1ZOHdT+zzx4n35BZbTZzmbw9Q84U556VB7zQVh1B0yOOQPoFzyTZiQVm2UjG5g lsPuVqWInsXincaMMXb7cZJUMcYcZintLxKLjlNAzBgm0SrPZuz9X7H1uElNZdV/WRrc dp4lnzAuQNWJiEx4/40C9rw4vfv5d1cuSt5htWHI3MdVl9Ei6KpBvSADF3UizEryH40b mnK12AQwRe0STw6L+6eti8mEHtBdDBZnDHk8z9P9sOP14+xRYPHcebpfqSAK4bpIn/HO CgrQ== 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=CiwVxtHqh7PtMKcIrbTly4vzLJ3BWefIHUj9tJBpUIs=; b=ta83++I7V8XB7ZF0OUAbzEJLgKJfaD5JrqeKoJItTI3o3T+K7NqY2sCIuLp5j9G7lv GuLp+ubj4N0XY/+V7jkyWXq0JdANnKdG2GM9UQUpXQ4dKWrdkmyhMDg/eFfFtjcH8KH4 oO5aGcxt/OXPLKp/a36BN9I3g3i/RkX9LANQGFLzUQ8JxZRJBGBJPGDhl6EY51CGMm8e NXODnmoKbot87il5cCr791C7mxUQQTHy5mxAf+8Jv+dttl3gSdKPJA1M1quogIwIfLXw /YSYj6fXN0HSb/OY3x+PWHxW3bUAurFFjrhUgzu8NZSYa60TMQljyex0tx4FV3EQcSty LDGQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@fromorbit-com.20210112.gappssmtp.com header.s=20210112 header.b=vimaQLlp; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=fromorbit.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id i23-20020aa7dd17000000b005021f0d5751si193665edv.664.2023.04.04.17.06.02; Tue, 04 Apr 2023 17:06:55 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@fromorbit-com.20210112.gappssmtp.com header.s=20210112 header.b=vimaQLlp; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=fromorbit.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231750AbjDDX4j (ORCPT + 99 others); Tue, 4 Apr 2023 19:56:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60746 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236551AbjDDX4i (ORCPT ); Tue, 4 Apr 2023 19:56:38 -0400 Received: from mail-pf1-x435.google.com (mail-pf1-x435.google.com [IPv6:2607:f8b0:4864:20::435]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 569F740C8 for ; Tue, 4 Apr 2023 16:56:37 -0700 (PDT) Received: by mail-pf1-x435.google.com with SMTP id l14so22539043pfc.11 for ; Tue, 04 Apr 2023 16:56:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fromorbit-com.20210112.gappssmtp.com; s=20210112; t=1680652597; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=CiwVxtHqh7PtMKcIrbTly4vzLJ3BWefIHUj9tJBpUIs=; b=vimaQLlpEUMehiQFMsj9zfP0aw8/xBepI6GNmarhCk57b8UQ+tn2pqLKQED8ItRRuU yF8SeMM3vB+68/MfMN+3QVByH6UzFxwNuWFtq5ftE0qjeYhWqPjWaGxRRrCcG7s+Sq2t TZHNB2ng1SQRm73fUpFyK2Zs5RT6hgnCgmO7HkFUdKdL6knY6P5hyJf8HGbX6i8ol+oL LlqjwoN3yKJCKPqRPVUAAs623zJmSloPMxmKQY24W37dtqAQrT3uUIUAAgzZOPO1c5zR spxERhNZLoAfBmHPajMN/L3QcThXSpRgXAusvQ8ERdge4t8cKIJw6oM2DZo36HcqBMPC BQ7A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1680652597; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=CiwVxtHqh7PtMKcIrbTly4vzLJ3BWefIHUj9tJBpUIs=; b=N0OVQUY+wvfDfbw0U0oika63ZTD0VPSfGRUlGvaSixNlSTuDuaz61fUUvr+U7tBCt0 3tLXfskhzAK5VA1e2+HiQmSk2TQxTbfsRGs27ps4epqVIiA+NzG+hBi0wfW/ePBLU6c1 BQL8b7m3nYC2pdzpjhkbHLCgp48ZftsYKUQPnLFzBb8Iakl8ZB32Psall3OB57AK02/z /uH8cp1XGhNX1+Wowx7LZL7p7EHMfdNMMLcF9kFNCU8cosltC6oJFfkDuWZVMPMcUf3O Pv1r32n019/uoCHI99IyNk+srq//c2zrnI8Z9GWcJ8caoEbEpoRodakJy3/aPXEMxsd9 fGCA== X-Gm-Message-State: AAQBX9cqV5kDjVubiMJPpQz2VfP1LEjCIH8ePxFHl/EhBW8D+avuX6TJ APWAEsgB4Rn/VzUC5D+8i9OdOg== X-Received: by 2002:a62:6454:0:b0:626:7c43:7cb8 with SMTP id y81-20020a626454000000b006267c437cb8mr3631280pfb.20.1680652596758; Tue, 04 Apr 2023 16:56:36 -0700 (PDT) Received: from dread.disaster.area (pa49-181-91-157.pa.nsw.optusnet.com.au. [49.181.91.157]) by smtp.gmail.com with ESMTPSA id a18-20020a656412000000b005136b93f8e9sm8146027pgv.14.2023.04.04.16.56.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 04 Apr 2023 16:56:36 -0700 (PDT) Received: from dave by dread.disaster.area with local (Exim 4.92.3) (envelope-from ) id 1pjqVt-00H7ij-6l; Wed, 05 Apr 2023 09:56:33 +1000 Date: Wed, 5 Apr 2023 09:56:33 +1000 From: Dave Chinner To: Eric Biggers Cc: Andrey Albershteyn , djwong@kernel.org, dchinner@redhat.com, hch@infradead.org, linux-xfs@vger.kernel.org, fsverity@lists.linux.dev, rpeterso@redhat.com, agruenba@redhat.com, xiang@kernel.org, chao@kernel.org, damien.lemoal@opensource.wdc.com, jth@kernel.org, linux-erofs@lists.ozlabs.org, linux-btrfs@vger.kernel.org, linux-ext4@vger.kernel.org, linux-f2fs-devel@lists.sourceforge.net, cluster-devel@redhat.com Subject: Re: [PATCH v2 16/23] xfs: add inode on-disk VERITY flag Message-ID: <20230404235633.GN3223426@dread.disaster.area> References: <20230404145319.2057051-1-aalbersh@redhat.com> <20230404145319.2057051-17-aalbersh@redhat.com> <20230404224123.GD1893@sol.localdomain> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230404224123.GD1893@sol.localdomain> X-Spam-Status: No, score=0.0 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Tue, Apr 04, 2023 at 03:41:23PM -0700, Eric Biggers wrote: > Hi Andrey, > > On Tue, Apr 04, 2023 at 04:53:12PM +0200, Andrey Albershteyn wrote: > > Add flag to mark inodes which have fs-verity enabled on them (i.e. > > descriptor exist and tree is built). > > > > Signed-off-by: Andrey Albershteyn > > --- > > fs/ioctl.c | 4 ++++ > > fs/xfs/libxfs/xfs_format.h | 4 +++- > > fs/xfs/xfs_inode.c | 2 ++ > > fs/xfs/xfs_iops.c | 2 ++ > > include/uapi/linux/fs.h | 1 + > > 5 files changed, 12 insertions(+), 1 deletion(-) > [...] > > diff --git a/include/uapi/linux/fs.h b/include/uapi/linux/fs.h > > index b7b56871029c..5172a2eb902c 100644 > > --- a/include/uapi/linux/fs.h > > +++ b/include/uapi/linux/fs.h > > @@ -140,6 +140,7 @@ struct fsxattr { > > #define FS_XFLAG_FILESTREAM 0x00004000 /* use filestream allocator */ > > #define FS_XFLAG_DAX 0x00008000 /* use DAX for IO */ > > #define FS_XFLAG_COWEXTSIZE 0x00010000 /* CoW extent size allocator hint */ > > +#define FS_XFLAG_VERITY 0x00020000 /* fs-verity sealed inode */ > > #define FS_XFLAG_HASATTR 0x80000000 /* no DIFLAG for this */ > > > > I don't think "xfs: add inode on-disk VERITY flag" is an accurate description of > a patch that involves adding something to the UAPI. Well it does that, but it also adds the UAPI for querying the on-disk flag via the FS_IOC_FSGETXATTR interface as well. It probably should be split up into two patches. > Should the other filesystems support this new flag too? I think they should get it automatically now that it has been defined for FS_IOC_FSGETXATTR and added to the generic fileattr flag fill functions in fs/ioctl.c. > I'd also like all ways of getting the verity flag to continue to be mentioned in > Documentation/filesystems/fsverity.rst. The existing methods (FS_IOC_GETFLAGS > and statx) are already mentioned there. *nod* -Dave. -- Dave Chinner david@fromorbit.com