From 90dd78b9416763ec219ef71e221c50024e767651 Mon Sep 17 00:00:00 2001 From: Pascal Rigaux Date: Thu, 1 Mar 2001 16:53:12 +0000 Subject: add handling for cciss (compaq smart array alike) --- perl-install/devices.pm | 6 +++--- perl-install/fs.pm | 2 +- perl-install/fsedit.pm | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) (limited to 'perl-install') diff --git a/perl-install/devices.pm b/perl-install/devices.pm index 89318e1e9..3ea25bc5e 100644 --- a/perl-install/devices.pm +++ b/perl-install/devices.pm @@ -74,11 +74,11 @@ sub entry { $type = c::S_IFBLK(); $major = 48 + $1; $minor = 8 * $2 + $4; - } elsif (m|ida/c(\d+)d(\d+)(p(\d+))?|) { + } elsif (m,(ida|cciss)/c(\d+)d(\d+)(?:p(\d+))?,) { # Compaq Smart Array "ida/c0d0{p1}" $type = c::S_IFBLK(); - $major = 72 + $1; - $minor = 16 * $2 + ($4 || 0); + $major = ($1 eq 'ida' ? 72 : 104) + $2; + $minor = 16 * $3 + ($4 || 0); } elsif (/(.*)(\d+)$/) { ($type, $major, $minor) = @{ ${{"fd" => [ c::S_IFBLK(), 2, 0 ], diff --git a/perl-install/fs.pm b/perl-install/fs.pm index 5f4e1ce95..460631607 100644 --- a/perl-install/fs.pm +++ b/perl-install/fs.pm @@ -82,7 +82,7 @@ sub get_mntpoints_from_fstab { sub format_ext2($@) { my ($dev, @options) = @_; - $dev =~ m,(rd|ida)/, and push @options, qw(-b 4096 -R stride=16); #- For RAID only. + $dev =~ m,(rd|ida|cciss)/, and push @options, qw(-b 4096 -R stride=16); #- For RAID only. push @options, qw(-b 1024 -O none) if arch() =~ /alpha/; run_program::run("mke2fs", @options, devices::make($dev)) or die _("%s formatting of %s failed", "ext2", $dev); diff --git a/perl-install/fsedit.pm b/perl-install/fsedit.pm index 5dd145e78..800ef45a3 100644 --- a/perl-install/fsedit.pm +++ b/perl-install/fsedit.pm @@ -69,7 +69,7 @@ sub hds { $hd->{file} = $file; $hd->{prefix} = $hd->{device}; # for RAID arrays of format c0d0p1 - $hd->{prefix} .= "p" if $hd->{prefix} =~ m,(rd|ida)/,; + $hd->{prefix} .= "p" if $hd->{prefix} =~ m,(rd|ida|cciss)/,; eval { partition_table::read($hd, $flags->{clearall} || member($_->{device}, @{$flags->{clear} || []})) }; if ($@) { -- cgit v1.2.1