summaryrefslogtreecommitdiff
path: root/drivers/misc/mic/host/mic_fops.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/misc/mic/host/mic_fops.c')
-rw-r--r--drivers/misc/mic/host/mic_fops.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/misc/mic/host/mic_fops.c b/drivers/misc/mic/host/mic_fops.c
index 85776d7327f3..8cc1d90cd949 100644
--- a/drivers/misc/mic/host/mic_fops.c
+++ b/drivers/misc/mic/host/mic_fops.c
@@ -30,8 +30,8 @@
int mic_open(struct inode *inode, struct file *f)
{
struct mic_vdev *mvdev;
- struct mic_device *mdev = container_of(inode->i_cdev,
- struct mic_device, cdev);
+ struct mic_device *mdev = container_of(f->private_data,
+ struct mic_device, miscdev);
mvdev = kzalloc(sizeof(*mvdev), GFP_KERNEL);
if (!mvdev)