Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 346482
b: refs/heads/master
c: 0a41409
h: refs/heads/master
v: v3
  • Loading branch information
Ed Cashin authored and Linus Torvalds committed Dec 18, 2012
1 parent ddbcc2a commit 5aca2a4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 14 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: fe7252bf511d682a977dd096da140accce1b128b
refs/heads/master: 0a41409c518083133e79015092585d68915865be
17 changes: 4 additions & 13 deletions trunk/drivers/block/aoe/aoeblk.c
Original file line number Diff line number Diff line change
Expand Up @@ -278,18 +278,12 @@ aoeblk_gdalloc(void *vp)
if (q == NULL) {
pr_err("aoe: cannot allocate block queue for %ld.%d\n",
d->aoemajor, d->aoeminor);
mempool_destroy(mp);
goto err_disk;
goto err_mempool;
}

d->blkq = blk_alloc_queue(GFP_KERNEL);
if (!d->blkq)
goto err_mempool;
d->blkq->backing_dev_info.name = "aoe";
if (bdi_init(&d->blkq->backing_dev_info))
goto err_blkq;
spin_lock_irqsave(&d->lock, flags);
blk_queue_max_hw_sectors(d->blkq, BLK_DEF_MAX_SECTORS);
blk_queue_max_hw_sectors(q, BLK_DEF_MAX_SECTORS);
q->backing_dev_info.name = "aoe";
q->backing_dev_info.ra_pages = READ_AHEAD / PAGE_CACHE_SIZE;
d->bufpool = mp;
d->blkq = gd->queue = q;
Expand All @@ -314,11 +308,8 @@ aoeblk_gdalloc(void *vp)
aoedisk_add_sysfs(d);
return;

err_blkq:
blk_cleanup_queue(d->blkq);
d->blkq = NULL;
err_mempool:
mempool_destroy(d->bufpool);
mempool_destroy(mp);
err_disk:
put_disk(gd);
err:
Expand Down

0 comments on commit 5aca2a4

Please sign in to comment.