linux-ext4.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sean Fu <fxinrong@gmail.com>
To: tytso@mit.edu
Cc: adilger.kernel@dilger.ca, linux-ext4@vger.kernel.org,
	linux-kernel@vger.kernel.org, Sean Fu <fxinrong@gmail.com>
Subject: [PATCH] ext4: Remove repeated test in ext4_file_read_iter.
Date: Wed, 27 Dec 2017 16:19:58 +0800	[thread overview]
Message-ID: <1514362798-5850-1-git-send-email-fxinrong@gmail.com> (raw)

generic_file_read_iter has done the count test.
So ext4_file_read_iter don't need to test the count repeatedly.

Signed-off-by: Sean Fu <fxinrong@gmail.com>
---
 fs/ext4/file.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/fs/ext4/file.c b/fs/ext4/file.c
index a0ae27b..87ca13e 100644
--- a/fs/ext4/file.c
+++ b/fs/ext4/file.c
@@ -67,9 +67,6 @@ static ssize_t ext4_file_read_iter(struct kiocb *iocb, struct iov_iter *to)
 	if (unlikely(ext4_forced_shutdown(EXT4_SB(file_inode(iocb->ki_filp)->i_sb))))
 		return -EIO;
 
-	if (!iov_iter_count(to))
-		return 0; /* skip atime */

             reply	other threads:[~2017-12-27  8:20 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-12-27  8:19 Sean Fu [this message]
2018-01-03  2:08 ` [PATCH] ext4: Remove repeated test in ext4_file_read_iter Al Viro
2018-01-10 14:01   ` Sean Fu
2018-01-10 20:02     ` Theodore Ts'o
2018-01-16  8:10       ` Sean Fu

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=1514362798-5850-1-git-send-email-fxinrong@gmail.com \
    --to=fxinrong@gmail.com \
    --cc=adilger.kernel@dilger.ca \
    --cc=linux-ext4@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tytso@mit.edu \
    /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).