summaryrefslogtreecommitdiffstats
path: root/kernel/list_modules.pm
diff options
context:
space:
mode:
authorOlivier Blin <oblin@mandriva.com>2007-10-03 22:10:36 +0000
committerOlivier Blin <oblin@mandriva.com>2007-10-03 22:10:36 +0000
commitaa5f878d122eb4e0dca6344ae2ffb81f323d0da1 (patch)
treee0b35c1b9ae2145cc741872dbf122365e85a91f9 /kernel/list_modules.pm
parent58fbf08613304038f71cb77c7a2035243f2743b4 (diff)
downloaddrakx-aa5f878d122eb4e0dca6344ae2ffb81f323d0da1.tar
drakx-aa5f878d122eb4e0dca6344ae2ffb81f323d0da1.tar.gz
drakx-aa5f878d122eb4e0dca6344ae2ffb81f323d0da1.tar.bz2
drakx-aa5f878d122eb4e0dca6344ae2ffb81f323d0da1.tar.xz
drakx-aa5f878d122eb4e0dca6344ae2ffb81f323d0da1.zip
move code in load_default_moddeps helper
Diffstat (limited to 'kernel/list_modules.pm')
-rw-r--r--kernel/list_modules.pm7
1 files changed, 5 insertions, 2 deletions
diff --git a/kernel/list_modules.pm b/kernel/list_modules.pm
index f8981c046..b85b92415 100644
--- a/kernel/list_modules.pm
+++ b/kernel/list_modules.pm
@@ -310,9 +310,12 @@ sub filename2modname {
$modname;
}
+sub load_default_moddeps {
+ load_dependencies($::prefix . '/lib/modules/' . c::kernel_version() . '/modules.dep');
+}
+
sub modname2filename {
- load_dependencies($::prefix . '/lib/modules/' . c::kernel_version() . '/modules.dep')
- if !%filenames;
+ load_default_moddeps() if !%filenames;
$filenames{$_[0]};
}