#ifdef CONFIG_BLK_CGROUP
+/* CFQ specific, out here for blkcg->cfq_weight */
+#define CFQ_WEIGHT_MIN 10
+#define CFQ_WEIGHT_MAX 1000
+#define CFQ_WEIGHT_DEFAULT 500
+
/* cft->private [un]packing for stat printing */
#define BLKCG_STAT_PRIV(pol, off) (((unsigned)(pol) << 16) | (off))
#define BLKCG_STAT_POL(prv) ((unsigned)(prv) >> 16)
struct blkio_cgroup {
struct cgroup_subsys_state css;
- unsigned int weight;
spinlock_t lock;
struct hlist_head blkg_list;
/* for policies to test whether associated blkcg has changed */
uint64_t id;
+
+ /* TODO: per-policy storage in blkio_cgroup */
+ unsigned int cfq_weight; /* belongs to cfq */
};
struct blkg_stat {
};
struct blkio_group_conf {
- unsigned int weight;
u64 iops[2];
u64 bps[2];
};
#endif
-#define BLKIO_WEIGHT_MIN 10
-#define BLKIO_WEIGHT_MAX 1000
-#define BLKIO_WEIGHT_DEFAULT 500
-
#ifdef CONFIG_BLK_CGROUP
extern struct blkio_cgroup blkio_root_cgroup;
extern struct blkio_cgroup *cgroup_to_blkio_cgroup(struct cgroup *cgroup);