Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
[sfrench/cifs-2.6.git] / include / linux / blk_types.h
index 1dcf652ba0aa3e989a7b93e78e4303aa920a1dab..5c7e7f859a2493f58ac65a6f10aee7e611b01458 100644 (file)
@@ -174,11 +174,11 @@ struct bio {
        void                    *bi_private;
 #ifdef CONFIG_BLK_CGROUP
        /*
-        * Optional ioc and css associated with this bio.  Put on bio
-        * release.  Read comment on top of bio_associate_current().
+        * Represents the association of the css and request_queue for the bio.
+        * If a bio goes direct to device, it will not have a blkg as it will
+        * not have a request_queue associated with it.  The reference is put
+        * on release of the bio.
         */
-       struct io_context       *bi_ioc;
-       struct cgroup_subsys_state *bi_css;
        struct blkcg_gq         *bi_blkg;
        struct bio_issue        bi_issue;
 #endif
@@ -228,6 +228,7 @@ struct bio {
 #define BIO_TRACE_COMPLETION 10        /* bio_endio() should trace the final completion
                                 * of this bio. */
 #define BIO_QUEUE_ENTERED 11   /* can use blk_queue_enter_live() */
+#define BIO_TRACKED 12         /* set if bio goes through the rq_qos path */
 
 /* See BVEC_POOL_OFFSET below before adding new flags */
 
@@ -323,6 +324,8 @@ enum req_flag_bits {
        /* command specific flags for REQ_OP_WRITE_ZEROES: */
        __REQ_NOUNMAP,          /* do not free blocks when zeroing */
 
+       __REQ_HIPRI,
+
        /* for driver use */
        __REQ_DRV,
        __REQ_SWAP,             /* swapping request. */
@@ -343,8 +346,8 @@ enum req_flag_bits {
 #define REQ_RAHEAD             (1ULL << __REQ_RAHEAD)
 #define REQ_BACKGROUND         (1ULL << __REQ_BACKGROUND)
 #define REQ_NOWAIT             (1ULL << __REQ_NOWAIT)
-
 #define REQ_NOUNMAP            (1ULL << __REQ_NOUNMAP)
+#define REQ_HIPRI              (1ULL << __REQ_HIPRI)
 
 #define REQ_DRV                        (1ULL << __REQ_DRV)
 #define REQ_SWAP               (1ULL << __REQ_SWAP)
@@ -422,17 +425,6 @@ static inline bool blk_qc_t_valid(blk_qc_t cookie)
        return cookie != BLK_QC_T_NONE;
 }
 
-static inline blk_qc_t blk_tag_to_qc_t(unsigned int tag, unsigned int queue_num,
-                                      bool internal)
-{
-       blk_qc_t ret = tag | (queue_num << BLK_QC_T_SHIFT);
-
-       if (internal)
-               ret |= BLK_QC_T_INTERNAL;
-
-       return ret;
-}
-
 static inline unsigned int blk_qc_t_to_queue_num(blk_qc_t cookie)
 {
        return (cookie & ~BLK_QC_T_INTERNAL) >> BLK_QC_T_SHIFT;