On Wed, Dec 06, 2023 at 06:43:47PM -0800, Darrick J. Wong wrote: > + if ((VFS_I(sc->ip)->i_mode & 0777) != 0) > + return false; > + if (!uid_eq(VFS_I(sc->ip)->i_uid, GLOBAL_ROOT_UID)) > + return false; > + if (!gid_eq(VFS_I(sc->ip)->i_gid, GLOBAL_ROOT_GID)) > + return false; Having this in a well-documented helper would be nice to have, but otherwise this looks good: Reviewed-by: Christoph Hellwig <hch@xxxxxx>