Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 86226
b: refs/heads/master
c: 48f15b9
h: refs/heads/master
v: v3
  • Loading branch information
Paul Clements authored and Linus Torvalds committed Feb 24, 2008
1 parent a2a014c commit 1edac70
Show file tree
Hide file tree
Showing 2 changed files with 7 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: 2f56debd77a8f52f1ac1d3c3d89cc7ce5e083230
refs/heads/master: 48f15b93b2c9f4ec9b8af08ab78f7a27db7c8378
6 changes: 6 additions & 0 deletions trunk/drivers/block/nbd.c
Original file line number Diff line number Diff line change
Expand Up @@ -655,6 +655,7 @@ static int __init nbd_init(void)

for (i = 0; i < nbds_max; i++) {
struct gendisk *disk = alloc_disk(1);
elevator_t *old_e;
if (!disk)
goto out;
nbd_dev[i].disk = disk;
Expand All @@ -668,6 +669,11 @@ static int __init nbd_init(void)
put_disk(disk);
goto out;
}
old_e = disk->queue->elevator;
if (elevator_init(disk->queue, "deadline") == 0 ||
elevator_init(disk->queue, "noop") == 0) {
elevator_exit(old_e);
}
}

if (register_blkdev(NBD_MAJOR, "nbd")) {
Expand Down

0 comments on commit 1edac70

Please sign in to comment.