lkml.org 
[lkml]   [2015]   [Jun]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH v2] Staging: lusture: Remove an open coded simple_open() function
Date
From: Abdul Hussain <habdul@visteon.com>

This patch removes an open coded simple_open() function and replace file
operations references to the function with simple_open() instead

Signed-off-by: Abdul Hussain <habdul@visteon.com>
---
drivers/staging/lustre/lustre/fld/lproc_fld.c | 9 +--------
1 file changed, 1 insertion(+), 8 deletions(-)

diff --git a/drivers/staging/lustre/lustre/fld/lproc_fld.c b/drivers/staging/lustre/lustre/fld/lproc_fld.c
index b35ff28..da82210 100644
--- a/drivers/staging/lustre/lustre/fld/lproc_fld.c
+++ b/drivers/staging/lustre/lustre/fld/lproc_fld.c
@@ -143,13 +143,6 @@ fld_debugfs_cache_flush_write(struct file *file, const char __user *buffer,
}

static int
-fld_debugfs_cache_flush_open(struct inode *inode, struct file *file)
-{
- file->private_data = inode->i_private;
- return 0;
-}
-
-static int
fld_debugfs_cache_flush_release(struct inode *inode, struct file *file)
{
file->private_data = NULL;
@@ -158,7 +151,7 @@ fld_debugfs_cache_flush_release(struct inode *inode, struct file *file)

static struct file_operations fld_debugfs_cache_flush_fops = {
.owner = THIS_MODULE,
- .open = fld_debugfs_cache_flush_open,
+ .open = simple_open,
.write = fld_debugfs_cache_flush_write,
.release = fld_debugfs_cache_flush_release,
};
--
1.9.1

\
 
 \ /
  Last update: 2015-06-16 10:01    [W:0.021 / U:2.096 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site