Skip to content

Commit

Permalink
i5100_edac: convert to use simple_open()
Browse files Browse the repository at this point in the history
This removes an open coded simple_open() function and
replaces file operations references to the function
with simple_open() instead.

Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
  • Loading branch information
Wei Yongjun authored and Mauro Carvalho Chehab committed Feb 26, 2013
1 parent 5dae92a commit b076989
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions drivers/edac/i5100_edac.c
Original file line number Diff line number Diff line change
Expand Up @@ -961,14 +961,8 @@ static ssize_t inject_enable_write(struct file *file, const char __user *data,
return count;
}

static int inject_enable_open(struct inode *inode, struct file *file)
{
file->private_data = inode->i_private;
return 0;
}

static const struct file_operations i5100_inject_enable_fops = {
.open = inject_enable_open,
.open = simple_open,
.write = inject_enable_write,
.llseek = generic_file_llseek,
};
Expand Down

0 comments on commit b076989

Please sign in to comment.