summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>1999-09-04 11:10:31 +0000
committerPascal Rigaux <pixel@mandriva.com>1999-09-04 11:10:31 +0000
commita050b68bbd857de1142394ad9bd23c83dafe52ec (patch)
tree5f097014a7a1aaaca556ce449a02964fcd79188a
parent444e2d59401d792ca01676bd0d6688e47ca4c1a7 (diff)
downloaddrakx-a050b68bbd857de1142394ad9bd23c83dafe52ec.tar
drakx-a050b68bbd857de1142394ad9bd23c83dafe52ec.tar.gz
drakx-a050b68bbd857de1142394ad9bd23c83dafe52ec.tar.bz2
drakx-a050b68bbd857de1142394ad9bd23c83dafe52ec.tar.xz
drakx-a050b68bbd857de1142394ad9bd23c83dafe52ec.zip
no_comment
-rw-r--r--perl-install/devices.pm9
1 files changed, 4 insertions, 5 deletions
diff --git a/perl-install/devices.pm b/perl-install/devices.pm
index 8190096d2..af5dd3ab1 100644
--- a/perl-install/devices.pm
+++ b/perl-install/devices.pm
@@ -51,7 +51,7 @@ sub make($) {
if (/^sd(.)(\d{0,2})/) {
$type = c::S_IFBLK();
$major = 8;
- $minor = ord($1) - ord('a') + ($2 || 0);
+ $minor = 16 * (ord($1) - ord('a')) + ($2 || 0);
} elsif (/^hd(.)(\d{0,2})/) {
$type = c::S_IFBLK();
($major, $minor) =
@@ -61,7 +61,7 @@ sub make($) {
'g' => [34,0], 'h' => [34,64],
}}{$1} or die "unknown device $_" };
$minor += $2 || 0;
- } elsif (/^ram(.)/) {
+ } elsif (/^ram(.*)/) {
$type = c::S_IFBLK();
$major = 1;
$minor = $1 eq '' ? 1 : $1;
@@ -70,11 +70,11 @@ sub make($) {
$type = c::S_IFBLK();
$major = 48 + $1;
$minor = 8 * $2 + $4;
- } elsif (m|ida/c(\d+)d(\d+)(p(\d+))|) {
+ } elsif (m|ida/c(\d+)d(\d+)(p(\d+))?|) {
# Compaq Smart Array "ida/c0d0{p1}"
$type = c::S_IFBLK();
$major = 72 + $1;
- $minor = 16 * $2 + $4;
+ $minor = 16 * $2 + ($4 || 0);
} else {
($type, $major, $minor) =
@{ $ {{"aztcd" => [ c::S_IFBLK(), 29, 0 ],
@@ -107,4 +107,3 @@ sub make($) {
$file;
}
-