Commit d0591485 authored by Gerald Schaefer's avatar Gerald Schaefer Committed by Martin Schwidefsky
Browse files

[S390] dcssblk: revert devt conversion

git commit f331c029

 changed users of
->first_minor to devt. This broke device handling in dcssblk, so that
no additional devices could be added after the first one.

This patch reverts the devt conversion to the previous ->first_minor

Signed-off-by: default avatarGerald Schaefer <>
Signed-off-by: default avatarMartin Schwidefsky <>
parent 6b9d8e80
...@@ -127,7 +127,7 @@ dcssblk_assign_free_minor(struct dcssblk_dev_info *dev_info) ...@@ -127,7 +127,7 @@ dcssblk_assign_free_minor(struct dcssblk_dev_info *dev_info)
found = 0; found = 0;
// test if minor available // test if minor available
list_for_each_entry(entry, &dcssblk_devices, lh) list_for_each_entry(entry, &dcssblk_devices, lh)
if (minor == MINOR(disk_devt(entry->gd))) if (minor == entry->gd->first_minor)
found++; found++;
if (!found) break; // got unused minor if (!found) break; // got unused minor
} }
...@@ -625,7 +625,7 @@ dcssblk_add_store(struct device *dev, struct device_attribute *attr, const char ...@@ -625,7 +625,7 @@ dcssblk_add_store(struct device *dev, struct device_attribute *attr, const char
if (rc) if (rc)
goto release_gd; goto release_gd;
sprintf(dev_info->gd->disk_name, "dcssblk%d", sprintf(dev_info->gd->disk_name, "dcssblk%d",
MINOR(disk_devt(dev_info->gd))); dev_info->gd->first_minor);
list_add_tail(&dev_info->lh, &dcssblk_devices); list_add_tail(&dev_info->lh, &dcssblk_devices);
if (!try_module_get(THIS_MODULE)) { if (!try_module_get(THIS_MODULE)) {
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment