On Thu, Jul 24, 2025 at 05:34:04PM -0700, Eric Biggers wrote:
> On Wed, Jul 23, 2025 at 12:57:44PM +0200, Christian Brauner wrote:
> > +#ifdef CONFIG_FS_ENCRYPTION
> > +   .inode_info_offs        = offsetof(struct ceph_inode_info, 
> > i_crypt_info) -
> > +                             offsetof(struct ceph_inode_info, netfs),
> > +#endif
> 
> This should use the offset to the VFS inode:
> 
>     offsetof(struct ceph_inode_info, netfs.inode)
> 
> > +/*
> > + * struct inode must be the first member so we can easily calculate 
> > offsets for
> > + * e.g., fscrypt or fsverity when embedded in filesystem specific inodes.
> > + */
> > +static_assert(__same_type(((struct netfs_inode *)NULL)->inode, struct 
> > inode));
> > +static_assert(offsetof(struct netfs_inode, inode) == 0);
> 
> Then no need for this.

Ok.

Reply via email to