1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00

o use the major number returned from dm_ioctl.

This commit is contained in:
Joe Thornber 2001-11-21 17:57:57 +00:00
parent f2ec0e072e
commit 6f842a9b05
2 changed files with 3 additions and 1 deletions

View File

@ -53,6 +53,7 @@ struct dm_info {
int exists;
int suspended;
unsigned int open_count;
int major;
int minor; /* minor device number */
unsigned int target_count;
};

View File

@ -115,6 +115,7 @@ int dm_task_get_info(struct dm_task *dmt, struct dm_info *info)
info->exists = dmt->dmi->exists;
info->suspended = dmt->dmi->suspend;
info->open_count = dmt->dmi->open_count;
info->major = dmt->dmi->major;
info->minor = dmt->dmi->minor;
info->target_count = dmt->dmi->target_count;
return 1;
@ -367,7 +368,7 @@ int dm_task_run(struct dm_task *dmt)
switch (dmt->type) {
case DM_DEVICE_CREATE:
_add_dev_node(dmt->dev_name, MKDEV(DM_BLK_MAJOR, dmi->minor));
_add_dev_node(dmt->dev_name, MKDEV(dmi->major, dmi->minor));
break;
case DM_DEVICE_REMOVE: