Commit 38067269 authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman

Revert "char: misc: assign file->private_data in all cases"

This reverts commit 585d98e0, as it
breaks the FUSE misc driver.
Reported-by: default avatarSedat Dilek <sedat.dilek@gmail.com>
Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Cc: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent cee4fbd6
...@@ -143,8 +143,8 @@ static int misc_open(struct inode * inode, struct file * file) ...@@ -143,8 +143,8 @@ static int misc_open(struct inode * inode, struct file * file)
err = 0; err = 0;
old_fops = file->f_op; old_fops = file->f_op;
file->f_op = new_fops; file->f_op = new_fops;
file->private_data = c;
if (file->f_op->open) { if (file->f_op->open) {
file->private_data = c;
err=file->f_op->open(inode,file); err=file->f_op->open(inode,file);
if (err) { if (err) {
fops_put(file->f_op); fops_put(file->f_op);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment