linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rasmus Villemoes <linux@rasmusvillemoes.dk>
To: David Howells <dhowells@redhat.com>
Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk>,
	linux-cachefs@redhat.com, linux-kernel@vger.kernel.org
Subject: [PATCH] fscache: don't duplicate seq_release_private
Date: Thu, 16 Aug 2018 15:37:31 +0200	[thread overview]
Message-ID: <20180816133731.21830-1-linux@rasmusvillemoes.dk> (raw)

Replace fscache_objlist_release by the completely equivalent
seq_release_private.

Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk>
---
 fs/fscache/object-list.c | 14 +-------------
 1 file changed, 1 insertion(+), 13 deletions(-)

diff --git a/fs/fscache/object-list.c b/fs/fscache/object-list.c
index 43e6e28c164f..3e1c97d34e25 100644
--- a/fs/fscache/object-list.c
+++ b/fs/fscache/object-list.c
@@ -397,21 +397,9 @@ static int fscache_objlist_open(struct inode *inode, struct file *file)
 	return 0;
 }
 
-/*
- * clean up on close
- */
-static int fscache_objlist_release(struct inode *inode, struct file *file)
-{
-	struct seq_file *m = file->private_data;
-
-	kfree(m->private);
-	m->private = NULL;
-	return seq_release(inode, file);
-}
-
 const struct file_operations fscache_objlist_fops = {
 	.open		= fscache_objlist_open,
 	.read		= seq_read,
 	.llseek		= seq_lseek,
-	.release	= fscache_objlist_release,
+	.release	= seq_release_private,
 };
-- 
2.16.4


                 reply	other threads:[~2018-08-16 13:37 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180816133731.21830-1-linux@rasmusvillemoes.dk \
    --to=linux@rasmusvillemoes.dk \
    --cc=dhowells@redhat.com \
    --cc=linux-cachefs@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).