summaryrefslogtreecommitdiffstats
path: root/mdk-stage1/pci-resource/update-pci-ids.pl
diff options
context:
space:
mode:
authorGuillaume Cottenceau <gc@mandriva.com>2000-12-19 13:20:05 +0000
committerGuillaume Cottenceau <gc@mandriva.com>2000-12-19 13:20:05 +0000
commiteae69cebb23d70f590a6107ebc9f0558a80a560e (patch)
treeb5a768e0f6fcbbdcc0e632dc0c490ce43956a4b5 /mdk-stage1/pci-resource/update-pci-ids.pl
parent25fe8828fbad057d08ef96c177ac9ac50474bc8e (diff)
downloaddrakx-backup-do-not-use-eae69cebb23d70f590a6107ebc9f0558a80a560e.tar
drakx-backup-do-not-use-eae69cebb23d70f590a6107ebc9f0558a80a560e.tar.gz
drakx-backup-do-not-use-eae69cebb23d70f590a6107ebc9f0558a80a560e.tar.bz2
drakx-backup-do-not-use-eae69cebb23d70f590a6107ebc9f0558a80a560e.tar.xz
drakx-backup-do-not-use-eae69cebb23d70f590a6107ebc9f0558a80a560e.zip
complies to ldetect/pcitable
Diffstat (limited to 'mdk-stage1/pci-resource/update-pci-ids.pl')
-rwxr-xr-xmdk-stage1/pci-resource/update-pci-ids.pl15
1 files changed, 10 insertions, 5 deletions
diff --git a/mdk-stage1/pci-resource/update-pci-ids.pl b/mdk-stage1/pci-resource/update-pci-ids.pl
index 396621faa..154ea8b42 100755
--- a/mdk-stage1/pci-resource/update-pci-ids.pl
+++ b/mdk-stage1/pci-resource/update-pci-ids.pl
@@ -1,8 +1,12 @@
#!/usr/bin/perl
use lib "../../perl-install";
+
use common qw(:common);
-use pci_probing::pcitable;
+require '../../../soft/ldetect-lst/convert/merge2pcitable.pl';
+
+my $drivers = read_pcitable("../../../soft/ldetect-lst/lst/pcitable");
+
print '
#define PCI_REVISION_ID 0x08 /* Revision ID */
@@ -30,10 +34,11 @@ struct pci_module_map ${_}_pci_ids[] = {
m|([^/]*)\.o$|;
$l{$1} = 1;
}
- while (my ($k, $v) = each %pci_probing::pcitable::ids) {
- $l{$v->[1]} or next;
- printf qq|\t{0x%04x , 0x%04x , ( "%s" ), ( "%s" )} ,\n|,
- $k / 0x10000, $k % 0x10000, $v->[0], $v->[1];
+ while (my ($k, $v) = each %$drivers) {
+ $l{$v->[0]} or next;
+ $k =~ /^(....)(....)/;
+ printf qq|\t{0x%s , 0x%s , ( "%s" ), ( "%s" )} ,\n|,
+ $1, $2, $v->[1], $v->[0];
}
print "