Lines Matching refs:throtl_grp

44 #define rb_entry_tg(node)	rb_entry((node), struct throtl_grp, rb_node)
92 static inline struct blkcg_gq *tg_to_blkg(struct throtl_grp *tg)
101 * Return the throtl_grp @sq belongs to. If @sq is the top-level one
104 static struct throtl_grp *sq_to_tg(struct throtl_service_queue *sq)
107 return container_of(sq, struct throtl_grp, service_queue);
116 * A service_queue can be embedded in either a throtl_grp or throtl_data.
121 struct throtl_grp *tg = sq_to_tg(sq);
147 static uint64_t tg_bps_limit(struct throtl_grp *tg, int rw)
177 static unsigned int tg_iops_limit(struct throtl_grp *tg, int rw)
219 * throtl_grp; otherwise, just "throtl".
222 struct throtl_grp *__tg = sq_to_tg((sq)); \
244 static void throtl_qnode_init(struct throtl_qnode *qn, struct throtl_grp *tg)
292 * @tg_to_put: optional out argument for throtl_grp to put
298 * When the first qnode is removed, its associated throtl_grp should be put
300 * otherwise, *@tg_to_put is set to the throtl_grp to put and the caller is
304 struct throtl_grp **tg_to_put)
341 struct throtl_grp *tg;
388 struct throtl_grp *tg = pd_to_tg(pd);
395 * behavior where limits on a given throtl_grp are applied to the
418 static void tg_update_has_rules(struct throtl_grp *tg)
420 struct throtl_grp *parent_tg = sq_to_tg(tg->service_queue.parent_sq);
438 struct throtl_grp *tg = pd_to_tg(pd);
455 struct throtl_grp *tg = blkg_to_tg(blkg);
476 struct throtl_grp *tg = pd_to_tg(pd);
491 struct throtl_grp *tg = pd_to_tg(pd);
499 static struct throtl_grp *
520 struct throtl_grp *tg;
529 static void tg_service_queue_add(struct throtl_grp *tg)
534 struct throtl_grp *__tg;
555 static void throtl_enqueue_tg(struct throtl_grp *tg)
564 static void throtl_dequeue_tg(struct throtl_grp *tg)
633 static inline void throtl_start_new_slice_with_credit(struct throtl_grp *tg,
657 static inline void throtl_start_new_slice(struct throtl_grp *tg, bool rw,
675 static inline void throtl_set_slice_end(struct throtl_grp *tg, bool rw,
681 static inline void throtl_extend_slice(struct throtl_grp *tg, bool rw,
692 static bool throtl_slice_used(struct throtl_grp *tg, bool rw)
736 static inline void throtl_trim_slice(struct throtl_grp *tg, bool rw)
796 static void __tg_update_carryover(struct throtl_grp *tg, bool rw)
818 static void tg_update_carryover(struct throtl_grp *tg)
825 /* see comments in struct throtl_grp for meaning of these fields. */
831 static unsigned long tg_within_iops_limit(struct throtl_grp *tg, struct bio *bio,
856 static unsigned long tg_within_bps_limit(struct throtl_grp *tg, struct bio *bio,
901 static bool tg_may_dispatch(struct throtl_grp *tg, struct bio *bio,
961 static void throtl_charge_bio(struct throtl_grp *tg, struct bio *bio)
977 * throtl_add_bio_tg - add a bio to the specified throtl_grp
980 * @tg: the target throtl_grp
986 struct throtl_grp *tg)
1009 static void tg_update_disptime(struct throtl_grp *tg)
1035 static void start_parent_slice_with_credit(struct throtl_grp *child_tg,
1036 struct throtl_grp *parent_tg, bool rw)
1045 static void tg_dispatch_one_bio(struct throtl_grp *tg, bool rw)
1049 struct throtl_grp *parent_tg = sq_to_tg(parent_sq);
1050 struct throtl_grp *tg_to_put = NULL;
1088 static int throtl_dispatch_tg(struct throtl_grp *tg)
1126 struct throtl_grp *tg;
1155 struct throtl_grp *this_tg);
1160 * This timer is armed when a child throtl_grp with active bio's become
1162 * the first child throtl_grp should be dispatched. This function
1166 * If the parent's parent is another throtl_grp, dispatching is propagated
1174 struct throtl_grp *tg = sq_to_tg(sq);
1279 struct throtl_grp *tg = pd_to_tg(pd);
1290 struct throtl_grp *tg = pd_to_tg(pd);
1312 static void tg_conf_updated(struct throtl_grp *tg, bool global)
1333 struct throtl_grp *this_tg = blkg_to_tg(blkg);
1334 struct throtl_grp *parent_tg;
1375 struct throtl_grp *tg;
1447 .private = offsetof(struct throtl_grp, bps[READ][LIMIT_MAX]),
1453 .private = offsetof(struct throtl_grp, bps[WRITE][LIMIT_MAX]),
1459 .private = offsetof(struct throtl_grp, iops[READ][LIMIT_MAX]),
1465 .private = offsetof(struct throtl_grp, iops[WRITE][LIMIT_MAX]),
1471 .private = offsetof(struct throtl_grp, stat_bytes),
1476 .private = offsetof(struct throtl_grp, stat_bytes),
1481 .private = offsetof(struct throtl_grp, stat_ios),
1486 .private = offsetof(struct throtl_grp, stat_ios),
1495 struct throtl_grp *tg = pd_to_tg(pd);
1567 struct throtl_grp *tg;
1733 struct throtl_grp *tg = blkg_to_tg(blkg);
1765 static unsigned long __tg_last_low_overflow_time(struct throtl_grp *tg)
1776 static unsigned long tg_last_low_overflow_time(struct throtl_grp *tg)
1779 struct throtl_grp *parent = tg;
1803 static bool throtl_tg_is_idle(struct throtl_grp *tg)
1829 static bool throtl_low_limit_reached(struct throtl_grp *tg, int rw)
1843 static bool throtl_tg_can_upgrade(struct throtl_grp *tg)
1861 static bool throtl_hierarchy_can_upgrade(struct throtl_grp *tg)
1874 struct throtl_grp *this_tg)
1887 struct throtl_grp *tg = blkg_to_tg(blkg);
1902 static void throtl_upgrade_check(struct throtl_grp *tg)
1933 struct throtl_grp *tg = blkg_to_tg(blkg);
1960 static bool throtl_tg_can_downgrade(struct throtl_grp *tg)
1977 static bool throtl_hierarchy_can_downgrade(struct throtl_grp *tg)
1994 static void throtl_downgrade_check(struct throtl_grp *tg)
2055 static void blk_throtl_update_idletime(struct throtl_grp *tg)
2153 static void blk_throtl_update_idletime(struct throtl_grp *tg)
2157 static void throtl_downgrade_check(struct throtl_grp *tg)
2161 static void throtl_upgrade_check(struct throtl_grp *tg)
2166 struct throtl_grp *this_tg)
2181 struct throtl_grp *tg = blkg_to_tg(blkg);
2316 struct throtl_grp *tg;