diff options
author | Pascal Terjan <pterjan@mandriva.org> | 2009-06-09 10:03:13 +0000 |
---|---|---|
committer | Pascal Terjan <pterjan@mandriva.org> | 2009-06-09 10:03:13 +0000 |
commit | 9ce591e41651e0cdb7508fb40ca3b0ef886172ca (patch) | |
tree | f63afc3fa011dcce5244b4c888b01a5982d166c3 /perl-install/fs/type.pm | |
parent | eebc50e4b2e3cd7da8947df477aa2b1be56a9dac (diff) | |
download | drakx-backup-do-not-use-9ce591e41651e0cdb7508fb40ca3b0ef886172ca.tar drakx-backup-do-not-use-9ce591e41651e0cdb7508fb40ca3b0ef886172ca.tar.gz drakx-backup-do-not-use-9ce591e41651e0cdb7508fb40ca3b0ef886172ca.tar.bz2 drakx-backup-do-not-use-9ce591e41651e0cdb7508fb40ca3b0ef886172ca.tar.xz drakx-backup-do-not-use-9ce591e41651e0cdb7508fb40ca3b0ef886172ca.zip |
Use Hal list of recovery partitions (#51532)
Diffstat (limited to 'perl-install/fs/type.pm')
-rw-r--r-- | perl-install/fs/type.pm | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/perl-install/fs/type.pm b/perl-install/fs/type.pm index e859b6fc2..f16698e23 100644 --- a/perl-install/fs/type.pm +++ b/perl-install/fs/type.pm @@ -9,7 +9,7 @@ use devices; our @ISA = qw(Exporter); our @EXPORT = qw( - isEmpty isExtended isTrueLocalFS isTrueFS isDos isSwap isOtherAvailableFS isRawLVM isRawRAID isRAID isLVM isMountableRW isNonMountable isPartOfLVM isPartOfRAID isPartOfLoopback isLoopback isMounted isBusy isSpecial isApple isAppleBootstrap isWholedisk isFat_or_NTFS + isEmpty isExtended isTrueLocalFS isTrueFS isDos isSwap isOtherAvailableFS isRawLVM isRawRAID isRAID isLVM isMountableRW isNonMountable isPartOfLVM isPartOfRAID isPartOfLoopback isLoopback isMounted isBusy isSpecial isApple isAppleBootstrap isWholedisk isFat_or_NTFS isRecovery maybeFormatted set_isFormatted ); @@ -323,6 +323,14 @@ sub isDos { arch() !~ /^sparc/ && ${{ 1 => 1, 4 => 1, 6 => 1 }}{$_[0]{pt_type}} sub isFat_or_NTFS { member($_[0]{fs_type}, 'vfat', 'ntfs', 'ntfs-3g') } sub isApple { $_[0]{pt_type} == 0x401 && defined $_[0]{isDriver} } sub isAppleBootstrap { $_[0]{pt_type} == 0x401 && defined $_[0]{isBoot} } +sub isRecovery { + isFat_or_NTFS($_[0]) && ($_[0]{type_name} eq 'Hidden' || + member($_[0]{device_LABEL} , + # Extracted from /usr/share/hal/fdi/policy/10osvendor/20-storage-methods.fdi + # Hopefuly we'll ask to hal/udev someday + 'RECOVERY', 'PQSERVICE', 'HP_RECOVERY', 'Recovery Partition', 'DellUtility', 'DellRestore', 'IBM_SERVICE', 'SERVICEV001', 'SERVICEV002') + ) +} sub isTrueFS { isTrueLocalFS($_[0]) || member($_[0]{fs_type}, qw(nfs)) } sub isTrueLocalFS { member($_[0]{fs_type}, true_local_fs_types()) } |