mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-05 16:56:40 +07: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;
|
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,
|
static ssize_t write_file_dummy(struct file *file, const char __user *buf,
|
||||||
size_t count, loff_t *ppos)
|
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 = {
|
static const struct file_operations sysconf_fops = {
|
||||||
.read = sysconf_read_file,
|
.read = sysconf_read_file,
|
||||||
.write = write_file_dummy,
|
.write = write_file_dummy,
|
||||||
.open = open_file_generic,
|
.open = simple_open,
|
||||||
.llseek = default_llseek,
|
.llseek = default_llseek,
|
||||||
};
|
};
|
||||||
|
|
||||||
static const struct file_operations clock_fops = {
|
static const struct file_operations clock_fops = {
|
||||||
.read = clock_read_file,
|
.read = clock_read_file,
|
||||||
.write = write_file_dummy,
|
.write = write_file_dummy,
|
||||||
.open = open_file_generic,
|
.open = simple_open,
|
||||||
.llseek = default_llseek,
|
.llseek = default_llseek,
|
||||||
};
|
};
|
||||||
|
|
||||||
static const struct file_operations display_fops = {
|
static const struct file_operations display_fops = {
|
||||||
.read = display_read_file,
|
.read = display_read_file,
|
||||||
.write = write_file_dummy,
|
.write = write_file_dummy,
|
||||||
.open = open_file_generic,
|
.open = simple_open,
|
||||||
.llseek = default_llseek,
|
.llseek = default_llseek,
|
||||||
};
|
};
|
||||||
|
|
||||||
static const struct file_operations gsctl_fops = {
|
static const struct file_operations gsctl_fops = {
|
||||||
.read = gsctl_read_file,
|
.read = gsctl_read_file,
|
||||||
.write = write_file_dummy,
|
.write = write_file_dummy,
|
||||||
.open = open_file_generic,
|
.open = simple_open,
|
||||||
.llseek = default_llseek,
|
.llseek = default_llseek,
|
||||||
};
|
};
|
||||||
|
|
||||||
static const struct file_operations sdram_fops = {
|
static const struct file_operations sdram_fops = {
|
||||||
.read = sdram_read_file,
|
.read = sdram_read_file,
|
||||||
.write = write_file_dummy,
|
.write = write_file_dummy,
|
||||||
.open = open_file_generic,
|
.open = simple_open,
|
||||||
.llseek = default_llseek,
|
.llseek = default_llseek,
|
||||||
};
|
};
|
||||||
|
|
||||||
static const struct file_operations misc_fops = {
|
static const struct file_operations misc_fops = {
|
||||||
.read = misc_read_file,
|
.read = misc_read_file,
|
||||||
.write = write_file_dummy,
|
.write = write_file_dummy,
|
||||||
.open = open_file_generic,
|
.open = simple_open,
|
||||||
.llseek = default_llseek,
|
.llseek = default_llseek,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user