LSM/SELinux: Interfaces to allow FS to control mount options
[sfrench/cifs-2.6.git] / fs / super.c
index 88811f60c8de517829ce7828c1971bfb4f90d8a1..010446d8c40a03512e4c1a8dc689581a67c5bbf3 100644 (file)
@@ -870,12 +870,12 @@ vfs_kern_mount(struct file_system_type *type, int flags, const char *name, void
        if (!mnt)
                goto out;
 
-       if (data) {
+       if (data && !(type->fs_flags & FS_BINARY_MOUNTDATA)) {
                secdata = alloc_secdata();
                if (!secdata)
                        goto out_mnt;
 
-               error = security_sb_copy_data(type, data, secdata);
+               error = security_sb_copy_data(data, secdata);
                if (error)
                        goto out_free_secdata;
        }