[<prev] [next>] [day] [month] [year] [list]
Message-Id: <1477728600-12938-28-git-send-email-tom.leiming@gmail.com>
Date: Sat, 29 Oct 2016 16:08:26 +0800
From: Ming Lei <tom.leiming@...il.com>
To: Jens Axboe <axboe@...com>, linux-kernel@...r.kernel.org
Cc: linux-block@...r.kernel.org, linux-fsdevel@...r.kernel.org,
Christoph Hellwig <hch@...radead.org>,
"Kirill A . Shutemov" <kirill.shutemov@...ux.intel.com>,
Ming Lei <tom.leiming@...il.com>,
Mike Christie <mchristi@...hat.com>,
Hannes Reinecke <hare@...e.com>,
Keith Busch <keith.busch@...el.com>,
Mike Snitzer <snitzer@...hat.com>
Subject: [PATCH 27/60] block: introduce BIO_SP_MAX_SECTORS
This macro is needed when one multipage bvec based bio is
converted to singlepage bvec based bio, for example, bio bounce
requires singlepage bvec.
Signed-off-by: Ming Lei <tom.leiming@...il.com>
---
include/linux/bio.h | 3 +++
1 file changed, 3 insertions(+)
diff --git a/include/linux/bio.h b/include/linux/bio.h
index 8634bd24984c..fa71f6a57f81 100644
--- a/include/linux/bio.h
+++ b/include/linux/bio.h
@@ -40,6 +40,9 @@
#define BIO_MAX_PAGES 256
+/* Max sectors of bio with singlepage bvec */
+#define BIO_SP_MAX_SECTORS (BIO_MAX_PAGES * (PAGE_SIZE >> 9))
+
#define bio_prio(bio) (bio)->bi_ioprio
#define bio_set_prio(bio, prio) ((bio)->bi_ioprio = prio)
--
2.7.4
Powered by blists - more mailing lists