STRUCT BFQ_DATA(9)
Hey bestie, welcome to the struct bfq_data(9) page from the Kernel API Manual β yes, this is the per-device data structure glow-up, and we're keeping every single field, periodt. π
β¨
π NAME π
struct bfq_data β the per-device data structure. π
β¨ SYNOPSIS β¨
Okay so here's the whole struct exactly as it is, no cap. Every field is invited to the group chat: π«Ά
struct bfq_data {
struct request_queue *queue;
struct list_head dispatch;
struct bfq_group *root_group;
struct rb_root_cached queue_weights_tree;
#ifdef CONFIG_BFQ_GROUP_IOSCHED;
unsigned int num_groups_with_pending_reqs;
#endif;
unsigned int busy_queues[3];
int wr_busy_queues;
int queued;
int tot_rq_in_driver;
int rq_in_driver[BFQ_MAX_ACTUATORS];
bool nonrot_with_queueing;
int max_rq_in_driver;
int hw_tag_samples;
int hw_tag;
int budgets_assigned;
struct hrtimer idle_slice_timer;
struct bfq_queue *in_service_queue;
sector_t last_position;
sector_t in_serv_last_pos;
u64 last_completion;
struct bfq_queue *last_completed_rq_bfqq;
struct bfq_queue *last_bfqq_created;
u64 last_empty_occupied_ns;
bool wait_dispatch;
struct request *waited_rq;
bool rqs_injected;
u64 first_dispatch;
u64 last_dispatch;
ktime_t last_budget_start;
ktime_t last_idling_start;
unsigned long last_idling_start_jiffies;
int peak_rate_samples;
u32 sequential_samples;
u64 tot_sectors_dispatched;
u32 last_rq_max_size;
u64 delta_from_first;
u32 peak_rate;
int bfq_max_budget;
struct list_head active_list[BFQ_MAX_ACTUATORS];
struct list_head idle_list;
u64 bfq_fifo_expire[2];
unsigned int bfq_back_penalty;
unsigned int bfq_back_max;
u32 bfq_slice_idle;
int bfq_user_max_budget;
unsigned int bfq_timeout;
bool strict_guarantees;
unsigned long last_ins_in_burst;
unsigned long bfq_burst_interval;
int burst_size;
struct bfq_entity *burst_parent_entity;
unsigned long bfq_large_burst_thresh;
bool large_burst;
struct hlist_head burst_list;
bool low_latency;
unsigned int bfq_wr_coeff;
unsigned int bfq_wr_rt_max_time;
unsigned int bfq_wr_min_idle_time;
unsigned long bfq_wr_min_inter_arr_async;
unsigned int bfq_wr_max_softrt_rate;
u64 rate_dur_prod;
struct bfq_queue oom_bfqq;
spinlock_t lock;
struct bfq_io_cq *bio_bic;
struct bfq_queue *bio_bfqq;
unsigned int async_depths[2][2];
unsigned int num_actuators;
sector_t sector[BFQ_MAX_ACTUATORS];
sector_t nr_sectors[BFQ_MAX_ACTUATORS];
struct blk_independent_access_range ia_ranges[BFQ_MAX_ACTUATORS];
unsigned int actuator_load_threshold;
};
π«Ά Members π«Ά
Members is literally the whole field list in the struct above, bestie β don't skip a single one, iykyk. πΈ
πΈ Description πΈ
All the fields are protected by lock. That's the safety tea, and it's giving very serious synchronization energy. ππ
π₯ SEE ALSO π₯
Kernel file ./block/bfq-iosched.h β and the whole friend group: struct bfq_service_tree(9), struct bfq_sched_data(9), struct bfq_weight_counter(9), struct bfq_entity(9), struct bfq_ttime(9), struct bfq_queue(9), struct bfq_io_cq(9), struct bfq_group(9). Go read them, they're iconic. π
Signed with sparkles: source/version ./block, date October 2026, page struct bfq_data(9). ππ¦π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms