[PATCH 2/7] block: remove the bio_phys_segments export

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: Christoph Hellwig <hch@xxxxxx>
---
 block/bio.c       | 3 +--
 block/blk-merge.c | 6 +++++-
 2 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/block/bio.c b/block/bio.c
index 036e3f0cc736..fa1ea2ac66a8 100644
--- a/block/bio.c
+++ b/block/bio.c
@@ -571,14 +571,13 @@ void bio_put(struct bio *bio)
 }
 EXPORT_SYMBOL(bio_put);
 
-inline int bio_phys_segments(struct request_queue *q, struct bio *bio)
+int bio_phys_segments(struct request_queue *q, struct bio *bio)
 {
 	if (unlikely(!bio_flagged(bio, BIO_SEG_VALID)))
 		blk_recount_segments(q, bio);
 
 	return bio->bi_phys_segments;
 }
-EXPORT_SYMBOL(bio_phys_segments);
 
 /**
  * 	__bio_clone_fast - clone a bio that shares the original bio's biovec
diff --git a/block/blk-merge.c b/block/blk-merge.c
index 09591daf4993..62e97ec92034 100644
--- a/block/blk-merge.c
+++ b/block/blk-merge.c
@@ -264,7 +264,11 @@ void blk_queue_split(struct request_queue *q, struct bio **bio)
 	}
 
 	/* physical segments can be figured out during splitting */
-	res = split ? split : *bio;
+	if (split) {
+		res = split;
+	} else {
+		res = *bio;
+	}
 	res->bi_phys_segments = nsegs;
 	bio_set_flag(res, BIO_SEG_VALID);
 
-- 
2.19.2




[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux