mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-16 08:44:21 +08:00
video/mbx: use simple_open()
Drop open_file_generic(), use simple_open() instead of it. Signed-off-by: Geliang Tang <geliangtang@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
This commit is contained in:
parent
74a2b96e61
commit
0a9aae40a6
@ -15,12 +15,6 @@ struct mbxfb_debugfs_data {
|
||||
struct dentry *misc;
|
||||
};
|
||||
|
||||
static int open_file_generic(struct inode *inode, struct file *file)
|
||||
{
|
||||
file->private_data = inode->i_private;
|
||||
return 0;
|
||||
}
|
||||
|
||||
static ssize_t write_file_dummy(struct file *file, const char __user *buf,
|
||||
size_t count, loff_t *ppos)
|
||||
{
|
||||
@ -174,42 +168,42 @@ static ssize_t misc_read_file(struct file *file, char __user *userbuf,
|
||||
static const struct file_operations sysconf_fops = {
|
||||
.read = sysconf_read_file,
|
||||
.write = write_file_dummy,
|
||||
.open = open_file_generic,
|
||||
.open = simple_open,
|
||||
.llseek = default_llseek,
|
||||
};
|
||||
|
||||
static const struct file_operations clock_fops = {
|
||||
.read = clock_read_file,
|
||||
.write = write_file_dummy,
|
||||
.open = open_file_generic,
|
||||
.open = simple_open,
|
||||
.llseek = default_llseek,
|
||||
};
|
||||
|
||||
static const struct file_operations display_fops = {
|
||||
.read = display_read_file,
|
||||
.write = write_file_dummy,
|
||||
.open = open_file_generic,
|
||||
.open = simple_open,
|
||||
.llseek = default_llseek,
|
||||
};
|
||||
|
||||
static const struct file_operations gsctl_fops = {
|
||||
.read = gsctl_read_file,
|
||||
.write = write_file_dummy,
|
||||
.open = open_file_generic,
|
||||
.open = simple_open,
|
||||
.llseek = default_llseek,
|
||||
};
|
||||
|
||||
static const struct file_operations sdram_fops = {
|
||||
.read = sdram_read_file,
|
||||
.write = write_file_dummy,
|
||||
.open = open_file_generic,
|
||||
.open = simple_open,
|
||||
.llseek = default_llseek,
|
||||
};
|
||||
|
||||
static const struct file_operations misc_fops = {
|
||||
.read = misc_read_file,
|
||||
.write = write_file_dummy,
|
||||
.open = open_file_generic,
|
||||
.open = simple_open,
|
||||
.llseek = default_llseek,
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user