Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 143971
b: refs/heads/master
c: 26a2ac0
h: refs/heads/master
i:
  143969: 9a45df2
  143967: a0c1254
v: v3
  • Loading branch information
Jens Axboe committed Apr 24, 2009
1 parent 15f11d5 commit 2b7aaa9
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 17d5c8ca7572124c9623045f24b0c21d4aa2b47f
refs/heads/master: 26a2ac009c2b07e1959c8864ca23486c1c485587
10 changes: 10 additions & 0 deletions trunk/block/cfq-iosched.c
Original file line number Diff line number Diff line change
Expand Up @@ -2446,12 +2446,22 @@ static void cfq_exit_queue(struct elevator_queue *e)
static void *cfq_init_queue(struct request_queue *q)
{
struct cfq_data *cfqd;
int i;

cfqd = kmalloc_node(sizeof(*cfqd), GFP_KERNEL | __GFP_ZERO, q->node);
if (!cfqd)
return NULL;

cfqd->service_tree = CFQ_RB_ROOT;

/*
* Not strictly needed (since RB_ROOT just clears the node and we
* zeroed cfqd on alloc), but better be safe in case someone decides
* to add magic to the rb code
*/
for (i = 0; i < CFQ_PRIO_LISTS; i++)
cfqd->prio_trees[i] = RB_ROOT;

INIT_LIST_HEAD(&cfqd->cic_list);

cfqd->queue = q;
Expand Down

0 comments on commit 2b7aaa9

Please sign in to comment.