Skip to content

Commit

Permalink
cfq-iosched: Get rid of nr_groups
Browse files Browse the repository at this point in the history
o Currently code does not seem to be using cfqd->nr_groups. Get rid of it.

Signed-off-by: Vivek Goyal <vgoyal@redhat.com>
Reviewed-by: Gui Jianfeng <guijianfeng@cn.fujitsu.com>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
  • Loading branch information
rhvgoyal authored and Jens Axboe committed Dec 18, 2009
1 parent 1db32c4 commit fb104db
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions block/cfq-iosched.c
Original file line number Diff line number Diff line change
Expand Up @@ -208,8 +208,6 @@ struct cfq_data {
/* Root service tree for cfq_groups */
struct cfq_rb_root grp_service_tree;
struct cfq_group root_group;
/* Number of active cfq groups on group service tree */
int nr_groups;

/*
* The priority currently being served
Expand Down Expand Up @@ -842,7 +840,6 @@ cfq_group_service_tree_add(struct cfq_data *cfqd, struct cfq_group *cfqg)

__cfq_group_service_tree_add(st, cfqg);
cfqg->on_st = true;
cfqd->nr_groups++;
st->total_weight += cfqg->weight;
}

Expand All @@ -863,7 +860,6 @@ cfq_group_service_tree_del(struct cfq_data *cfqd, struct cfq_group *cfqg)

cfq_log_cfqg(cfqd, cfqg, "del_from_rr group");
cfqg->on_st = false;
cfqd->nr_groups--;
st->total_weight -= cfqg->weight;
if (!RB_EMPTY_NODE(&cfqg->rb_node))
cfq_rb_erase(&cfqg->rb_node, st);
Expand Down

0 comments on commit fb104db

Please sign in to comment.