diff options
author | Francesc Pinyol Margalef <francesc.pinyol.m@gmail.com> | 2013-12-21 13:37:33 +0100 |
---|---|---|
committer | Francesc Pinyol Margalef <francesc.pinyol.m@gmail.com> | 2013-12-21 13:37:33 +0100 |
commit | 095c6b25885ce3d22eedba8cdb98f1fd7e8708a5 (patch) | |
tree | 5bfc768996b3ddec185abeb02b602b48b14d10db /kernel | |
parent | df60191bdbddfa7c8e5bd11a2578aae6740963c0 (diff) | |
parent | f76dc0931e47338aa9c7db257d28e5015d8a2f47 (diff) | |
download | drakx-095c6b25885ce3d22eedba8cdb98f1fd7e8708a5.tar drakx-095c6b25885ce3d22eedba8cdb98f1fd7e8708a5.tar.gz drakx-095c6b25885ce3d22eedba8cdb98f1fd7e8708a5.tar.bz2 drakx-095c6b25885ce3d22eedba8cdb98f1fd7e8708a5.tar.xz drakx-095c6b25885ce3d22eedba8cdb98f1fd7e8708a5.zip |
Merge branch 'master' of git://git.mageia.org/software/drakx
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/list_modules.pm | 3 | ||||
-rw-r--r-- | kernel/modules.pl | 35 |
2 files changed, 18 insertions, 20 deletions
diff --git a/kernel/list_modules.pm b/kernel/list_modules.pm index c4ee7674d..63a382012 100644 --- a/kernel/list_modules.pm +++ b/kernel/list_modules.pm @@ -332,7 +332,8 @@ our %l = ( other => [ qw(defxx ide-floppy ide-tape loop lp nbd sg st), qw(parport_pc parport_serial), - qw(btaudio mmc_block), + qw(btaudio), + qw(mmc_block sdhci-acpi), # eMMC 'cryptoloop', if_(arch() =~ /sparc/, 'openprom'), diff --git a/kernel/modules.pl b/kernel/modules.pl index b64c92fa2..70d6ed0bd 100644 --- a/kernel/modules.pl +++ b/kernel/modules.pl @@ -41,36 +41,33 @@ sub modules() { @nls_modules, map { category2modules($_) } split(' ', $images_cat); } -sub get_firmwares() { +sub list_needed_modules { my ($kern_ver) = @_; - foreach (all("all.kernels/$kern_ver/modules")) { - foreach(`/sbin/modinfo -Ffirmware "all.kernels/$kern_ver/modules/$_"`) { - mkdir_p(dirname("all.kernels/$kern_ver/firmware/$_")); - eval { cp_af("/lib/firmware/$_", "all.kernels/$kern_ver/firmware/$_"); }; - } - } -} - -sub remove_unneeded_modules { - my ($kern_ver) = @_; - - load_dependencies("all.kernels/$kern_ver/modules.dep"); + load_dependencies("/lib/modules/$kern_ver/modules.dep"); my @all = modules(); my @all_with_deps = map { dependencies_closure($_) } @all; - my %wanted_modules = map { (list_modules::modname2filename($_) . ".ko.xz" => 1) } @all_with_deps; - foreach (all("all.kernels/$kern_ver/modules")) { - $wanted_modules{$_} or unlink "all.kernels/$kern_ver/modules/$_"; + my %wanted_modules = map { (list_modules::modname2filename($_) => 1) } @all_with_deps; + foreach (`find /lib/modules/$kern_ver -name '*.ko.?z'`) { + my $modfile = basename($_); + $modfile =~ s/\.ko\.xz//; + $wanted_modules{$modfile} and print "$modfile\n"; } } -sub make_modules_per_image { +sub list_fake_modules { my ($kern_ver) = @_; - my $dir = "all.kernels/$kern_ver/modules"; + load_dependencies("/lib/modules/$kern_ver/modules.dep"); - system("cd $dir ; tar cf ../all_modules.tar *.ko.*") == 0 or die "tar failed\n"; + my @all = map { category2modules($_) } split(' ', 'multimedia/*'); + my %wanted_modules = map { (list_modules::modname2filename($_) => 1) } @all; + foreach (`find /lib/modules/$kern_ver -name '*.ko.?z'`) { + my $modfile = basename($_); + $modfile =~ s/\.ko\.xz//; + $wanted_modules{$modfile} and print "$modfile\n"; + } } sub get_main_modules() { |