From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756177AbbFPHH4 (ORCPT ); Tue, 16 Jun 2015 03:07:56 -0400 Received: from mga11.intel.com ([192.55.52.93]:51980 "EHLO mga11.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751910AbbFPHHr convert rfc822-to-8bit (ORCPT ); Tue, 16 Jun 2015 03:07:47 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.13,624,1427785200"; d="scan'208";a="588614107" From: "Drokin, Oleg" To: "Abdul, Hussain (H.)" CC: "gregkh@linuxfoundation.org" , "Dilger, Andreas" , "HPDD-discuss@lists.01.org" , "devel@driverdev.osuosl.org" , "linux-kernel@vger.kernel.org" , "Ravindran, Madhusudhanan (M.)" , "Dighe, Niranjan (N.)" Subject: Re: [PATCH] Staging: lusture: Remove an open coded simple_open() function Thread-Topic: [PATCH] Staging: lusture: Remove an open coded simple_open() function Thread-Index: AQHQqAJ+pKktxGjzxE6yWSL7PstmZp2vK4sA Date: Tue, 16 Jun 2015 07:07:38 +0000 Message-ID: <14E04FD4-9283-406C-A5D2-68B27DF58F5F@intel.com> References: <1434438105-4648-1-git-send-email-habdul@visteon.com> In-Reply-To: <1434438105-4648-1-git-send-email-habdul@visteon.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.252.3.134] Content-Type: text/plain; charset=US-ASCII Content-ID: Content-Transfer-Encoding: 7BIT MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Jun 16, 2015, at 3:03 AM, Abdul, Hussain (H.) wrote: > From: Abdul Hussain > > 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 > --- > 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..d19b724 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, Could you please save the indenting to match the rest of this structure assignment? > .write = fld_debugfs_cache_flush_write, > .release = fld_debugfs_cache_flush_release, > }; > -- > 1.9.1