Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1547638

[PATCH v1 26/54] block: blk-merge: remove unnecessary check

From Ming Lei <tom.leiming@gmail.com>
Newsgroups linux.kernel
Subject [PATCH v1 26/54] block: blk-merge: remove unnecessary check
Date 2016-12-27 17:10 +0100
Message-ID <sT2u6-4eA-43@gated-at.bofh.it> (permalink)
References <sT2u5-4eA-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


In this case, 'sectors' can't be zero at all, so remove the check.

Signed-off-by: Ming Lei <tom.leiming@gmail.com>
---
 block/blk-merge.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/block/blk-merge.c b/block/blk-merge.c
index a801f62a104b..05b6a3ef63f6 100644
--- a/block/blk-merge.c
+++ b/block/blk-merge.c
@@ -136,9 +136,7 @@ static struct bio *blk_bio_segment_split(struct request_queue *q,
 				nsegs++;
 				sectors = max_sectors;
 			}
-			if (sectors)
-				goto split;
-			/* Make this single bvec as the 1st segment */
+			goto split;
 		}
 
 		if (bvprvp && blk_queue_cluster(q)) {
-- 
2.7.4

Back to linux.kernel | Previous | Next | Find similar | Unroll thread


Thread

[PATCH v1 26/54] block: blk-merge: remove unnecessary check Ming Lei <tom.leiming@gmail.com> - 2016-12-27 17:10 +0100

csiph-web