Skip to content

Commit

Permalink
[PATCH] dm: store md name
Browse files Browse the repository at this point in the history
The patch stores a printable device number in struct mapped_device for use in
warning messages and with a proposed netlink interface.

Signed-off-by: Mike Anderson <andmike@us.ibm.com>
Signed-off-by: Alasdair G Kergon <agk@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Mike Anderson authored and Linus Torvalds committed Mar 27, 2006
1 parent 1ecac7f commit 7e51f25
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/md/dm.c
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ struct mapped_device {

request_queue_t *queue;
struct gendisk *disk;
char name[16];

void *interface_ptr;

Expand Down Expand Up @@ -842,6 +843,7 @@ static struct mapped_device *alloc_dev(unsigned int minor, int persistent)
md->disk->private_data = md;
sprintf(md->disk->disk_name, "dm-%d", minor);
add_disk(md->disk);
format_dev_t(md->name, MKDEV(_major, minor));

atomic_set(&md->pending, 0);
init_waitqueue_head(&md->wait);
Expand Down

0 comments on commit 7e51f25

Please sign in to comment.