]> granicus.if.org Git - zfs/blobdiff - module/zfs/zvol.c
Remove zfs_parse_bootfs() support
[zfs] / module / zfs / zvol.c
index 6e929429252a269179a4eae150f981d3c90371f1..b2a08fb437c62a7e4a8160ca1a4f3b06bf7518c7 100644 (file)
@@ -1002,6 +1002,8 @@ static int
 zvol_ioctl_by_inode(struct inode *inode, struct file *file,
                     unsigned int cmd, unsigned long arg)
 {
+       if (file == NULL || inode == NULL)
+               return -EINVAL;
        return zvol_ioctl(inode->i_bdev, file->f_mode, cmd, arg);
 }
 
@@ -1010,6 +1012,8 @@ static long
 zvol_compat_ioctl_by_inode(struct file *file,
                            unsigned int cmd, unsigned long arg)
 {
+       if (file == NULL)
+               return -EINVAL;
        return zvol_compat_ioctl(file->f_dentry->d_inode->i_bdev,
                                 file->f_mode, cmd, arg);
 }