#include <bsched.h>
A bandwidth scheduler (`B-sched' for short) is made of:
It operates in cooperation with the I/O sources:
Periodically, the scheduler runs to compute the amount available for the next period.
A list of stealing schedulers can be added to each scheduler. At the end of the period, any amount of bandwidth that has been unused will be given as "stolem" bandwidth to some of the schedulers stealing from us. Priority is given to schedulers that used up all their bandwidth.
Data Fields | |
tm_t | last_period |
Last time we ran our period. | |
GList * | sources |
List of bio_source_t. | |
GSList * | stealers |
List of bsched_t stealing bw. | |
gchar * | name |
Name, for tracing purposes. | |
gint | count |
Amount of sources. | |
gint | type |
Scheduling type. | |
gint | flags |
Processing flags. | |
gint | period |
Fixed scheduling period, in ms. | |
gint | min_period |
Minimal period without correction. | |
gint | max_period |
Maximal period without correction. | |
gint | period_ema |
EMA of period, in ms. | |
gint | bw_per_second |
Configure bandwidth in bytes/sec. | |
gint | bw_max |
Max bandwidth per period. | |
gint | bw_actual |
Bandwidth used so far in period. | |
gint | bw_last_period |
Bandwidth used last period. | |
gint | bw_last_capped |
Bandwidth capped last period. | |
gint | bw_slot |
Basic per-source bandwidth lot. | |
gint | bw_ema |
EMA of bandwidth really used. | |
gint | bw_stolen |
Amount we stole this period. | |
gint | bw_stolen_ema |
EMA of stolen bandwidth. | |
gint | bw_delta |
Running diff of actual vs. | |
gint | bw_unwritten |
Data that we could not write. | |
gint | bw_capped |
Bandwidth we refused to sources. | |
gint | last_used |
Nb of active sources last period. | |
gint | current_used |
Nb of active sources this period. | |
gboolean | looped |
True when looped once over sources. |
|
Bandwidth used so far in period.
|
|
Bandwidth we refused to sources.
|
|
Running diff of actual vs. theoric |
|
EMA of bandwidth really used.
|
|
Bandwidth capped last period.
|
|
Bandwidth used last period.
|
|
Max bandwidth per period.
|
|
Configure bandwidth in bytes/sec.
|
|
Basic per-source bandwidth lot.
|
|
Amount we stole this period.
|
|
EMA of stolen bandwidth.
|
|
Data that we could not write.
|
|
Amount of sources.
|
|
Nb of active sources this period.
|
|
Processing flags.
|
|
Last time we ran our period.
|
|
Nb of active sources last period.
|
|
True when looped once over sources.
|
|
Maximal period without correction.
|
|
Minimal period without correction.
|
|
Name, for tracing purposes.
|
|
Fixed scheduling period, in ms.
|
|
EMA of period, in ms.
|
|
List of bio_source_t.
|
|
List of bsched_t stealing bw.
|
|
Scheduling type.
|