BUG? Missing dput() in ovl_permissions().

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I apologize for not having tested this on the latest kernel. I hit this bug in SUSE SLES12 and by inspection it still appears to be in Linus's kernel.

Failure to free dentry. Missing dput() using default_permissions in ovl_permission().

# mount overlayfs with default_permissions
mkdir l u m
mount -t tmpfs tmpfs u
mount -t overlayfs -o upperdir=u,lowerdir=l,default_permissions overlayfs m
dd if=/dev/zero of=m/test_dput bs=4096b count=1000
df u l m
rm m/test_dput
df u l m
# tmpfs space is not freed!

umount m u
# BUG. Dentry still in use!

It appears that there may be a missing dput() in the ovl_is_default_permissions(inode) path of ovl_permission().

I hit this in SUSE because default_permissions was getting set by accident due to uninitialized data in ovl_config (kalloc vs. kzalloc). This bug is fixed upstream.


-Eric Jones
--
To unsubscribe from this list: send the line "unsubscribe linux-unionfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Filesystems Devel]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux